Expose the taskcluster job name as an environment variable

RESOLVED WONTFIX

Status

RESOLVED WONTFIX
a year ago
a year ago

People

(Reporter: glandium, Assigned: glandium)

Tracking

Details

Attachments

(1 attachment)

(Assignee)

Description

a year ago
See the large comment in bug 1356529. Long story short, I want to use a script in most build jobs that will do things based on information about the job in the taskcluster configuration, and for that, obviously, the job name is necessary.

AFAICT, it's currently not exposed, so let's do that.
Comment hidden (mozreview-request)
(Assignee)

Updated

a year ago
Assignee: nobody → mh+mozilla
(Assignee)

Updated

a year ago
Blocks: 1356974

Comment 2

a year ago
mozreview-review
Comment on attachment 8858714 [details]
Bug 1356955 - Expose the taskcluster job name as an environment variable.

https://reviewboard.mozilla.org/r/130740/#review133426

::: taskcluster/taskgraph/transforms/task.py:975
(Diff revision 1)
>          ):
>              payload = task_def.get('payload')
>              if payload:
>                  env = payload.setdefault('env', {})
>                  env['MOZ_AUTOMATION'] = '1'
> +                env['MOZ_JOB_NAME'] = task['label']

"job name" and "label" are two different words.  Let's not invent a new name for something that already has a name.
Attachment #8858714 - Flags: review?(dustin) → review-

Comment 3

a year ago
mozreview-review
Comment on attachment 8858714 [details]
Bug 1356955 - Expose the taskcluster job name as an environment variable.

https://reviewboard.mozilla.org/r/130740/#review133428

Whoops, clicked "publish" instead of "Edit Review"

I don't think this is necessary in light of my comments on bug 1356529, but I'm not opposed to it in general -- as long as the environment variable calls a label a LABEL.  How about MOZ_TASK_LABEL?
(Assignee)

Comment 4

a year ago
cf. the discussion around bug 1356529, we're not going to need this.
Status: NEW → RESOLVED
Last Resolved: a year ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.