opt-in to automatically sourcing accessing `nomad/jobs` prefix variables
- Dominant language
- Go
- Stars
- 17k
- Forks
- 2.1k
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 105
Description
Many workloads will want to access all the variables available to them under the `nomad/jobs/` prefix as environment variables. We can expect there to be a fairly common template block that gets copied over and over again by users to do that. Rather than forcing them to write out a template block, could we have a flag that opts-in the task to get _all_ its accessible `nomad/jobs` variables sourced-in as environment variables? If so, what would this look like in implementation?
Suggested in https://github.com/hashicorp/nomad/issues/14996#issuecomment-1290103480 and opening for discussion here. cc @angrycub and @mikenomitch who might have some thoughts.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reviewing Nomad's existing template-block behavior and how task environment variables are sourced from the `nomad/jobs/` prefix. Define the proposed opt-in flag, its scope, and expected behavior for all accessible variables. Done means the implementation approach and acceptance behavior are agreed upon, with suitable tests identified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- devops, infrastructure
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100