-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
Actual behavior
If two profiles define the same environment variable and both profiles are loaded, the last profile wins and overwrites the earlier loaded environment variables.
Expected behavior
An error message / warning is shown when one profile overwrites a variable set by another profile during the same load command.
Additional notes
- The check should only be performed during one load operation (e.g.
envManager load profA profB) - It is particularly easy to "achieve" this with directory mappings since they are another redirection
- This condition can probably also be reached via dependencies
How to to reproduce
Config:
storage:
pass:
type: pass
profiles:
profA:
storage: pass
path: credA
constEnv:
CONST_ENV: i-am-from-profile-A
profB:
storage: pass
path: credB
constEnv:
CONST_ENV: i-am-from-profile-B
directoryMapping:
/tmp:
- profA
- profB- Run
envManager load profA profBand you seeCONST_ENV=i-am-from-profile-B. Swap the profile names and you see the value of profile A - Run
envManager loadwhile in/tmpand see again the value from profile B
Metadata
Metadata
Assignees
Labels
No labels