-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Add JOB_ env vars #4053
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
jenseng
wants to merge
1
commit into
actions:main
Choose a base branch
from
jenseng:add-job-env-vars
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+58
−3
Open
Add JOB_ env vars #4053
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @jenseng! I want to collect some more thoughts internally.
I'm thinking about namespace conflict (if customers already use JOB_ variables). I'm waiting on one of the individuals to get back from vacation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah that's a fair point and definitely worth considering. Another possibility could be to have a
GITHUB_JOB_prefix, though that has some downsides of its own (i.e. inconsistent with howrunner/githubvariables are named, and it could conflict with futuregithub.job_...variables)Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good callout on RUNNER_ variables 👍. That naming precedent helps.
We can likely add JOB_ but may need some advance announcement before it rolls out. I will discuss more with folks internally.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👋 hey @ericsciple, any updates here?
thinking more about potential conflicts with (existing)
JOB_variables people might set, perhaps this could be done slightly more gradually with a feature flag...before the feature is enabled, these new variables wouldn't get set. but if someone tries to set one of these reserved variable names (via
envor$GITHUB_ENV), actions/runner would emit a warning that this will stop working (e.g.JOB_CHECK_RUN_ID is a reserved variable name, and you will no longer be able to set it as of $DATE. Please switch to a different variable name)then once the feature flag is enabled, the new variables would get set automatically. then if someone tries to set one of them explicitly, the warning text would be slightly different (e.g.
JOB_CHECK_RUN_ID is a reserved variable name, so the value you've set has no effect. Please switch to a different variable name)that could be more trouble than it's worth though, so perhaps an advance announcement would suffice? 🤷♂️
it could also be good to add telemetry around the env variable names people are setting in their workflows/actions, which would give you better insights into how disruptive these kinds of changes might be