-
Type: Task
-
Resolution: Duplicate
-
Priority: Unknown
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
Backport NODE-5485 to v5.x.
Parent Ticket Description:
Use Case
As a Node engineer,
I want to load environment info into evergreen expansions,
So that the evergreen team can fix the bug outlined in <ticket>.
From slack:
Okay, so what happened. We’re relying on a bug in evergreen that was fixed and then reverted, but they still want to fix it. The bug: expected: if a func defines vars , then the vars should only be present for that function’s execution actual: if a func defines vars , then the vars are present for the functions execution and subsequent functionsWe seem to rely on this when calling bootstrap mongo-orchestration. We pass configuration values in as vars (i.e., AUTH), which get passed into mongo orchestration, but we then rely on these values being present when we call run tests. When evergreen fixed the bug, they were no longer present.
We need to identify any locations where we rely on values set in `vars` and instead load them into expansions.
User Impact
n/a (CI change)
Dependencies
- tbd - evergreen wants to update the evergreen agent soon, we'll need to finish this first.
Unknowns
- How can we determine all places where we were relying on the buggy behavior?
- Remove all defaulting from all of our evergreen scripts, both in the config and outside of it and throw if any required environment variable is not provided. We can then safely assume that we aren't falling back to a default value in the case where a `var` is no longer accessible in subsequent functions.
Acceptance Criteria
Implementation Requirements
- add functionality to our evergreen config to load all necessary environment variables into evergreen expansions. the list can be found here: https://github.com/mongodb/node-mongodb-native/blob/52cd649caf2e64aef6d3984c5f2d24af03db4c51/.evergreen/config.yml#L42
- ensure that the above functionality runs before bootstrap mongo-orchestration wherever bootstrap mongo-orchestration is called.
- audit `generate_evergreen_tasks`
Testing Requirements
- n/a
Documentation Requirements
- DOCSP ticket, API docs, etc
Follow Up Requirements
- additional tickets to file, required releases, etc