Stephan Erb commented on AURORA-1971:

What you are observing is the behaviour described here 

You cannot see the name of the job as it is shadowed by the name of the process 
(see [https://github.com/wickman/pystachio#object-scopes] for details on 
scoping). A possible workaround could be to define a custom pystachio variable 
and use it in both places:
hello = Process(
    while true; do
      echo {{job_name}}
      sleep 10

task = SequentialTask(
  resources=Resources(cpu = 1.0, ram = 128*MB, disk = 128*MB))

jobs = [
      role = 'www-data',
      environment = 'prod',
      name = '{{job_name}}'

> Access to the job name in aurora configuration?
> -----------------------------------------------
>                 Key: AURORA-1971
>                 URL: https://issues.apache.org/jira/browse/AURORA-1971
>             Project: Aurora
>          Issue Type: Story
>            Reporter: Allan Feid
>            Priority: Minor
> I see there's a few different variables exposed in the pystachio 
> configurations (environment, role, task.name, mesos), however I have not been 
> able to figure out how to extract the job name. It seems a job's name 
> defaults to task.name but in my case these are not the same. The use case for 
> this is to simply export environment variables that give running processes 
> access to their environment, role, and job names.

This message was sent by Atlassian JIRA

Reply via email to