Hi Jeremy,
Thanks for getting back to me.
We’re using Octopus 2019.13.7
Sorry about my poor explanation, I realize it’s a bit confusing.
I’ll try to summarize as best I can:
Our project situation:
Let’s call it ‘MyGame’.
This project has a variable template, called Service01.InstallationDirectory
The previous Default Value for that variable template was ‘E:\SomeFolder…’
The old Tenant/Project/Environment situation then: (Ill use fake names / fake projects)
MyOldTenant / MyGame / Production
So that old tenant had received the value ‘E:\SomeFolder…’
All was working correctly.
Then recently, I realized that default value, in our variable template (inside the ‘MyGame’ project) ‘E:\SomeFolder…’ was very problematic for all our new tenants, new servers etc.
The default value should be ‘C:\SomeFolder…’ for all future tenants.
I decided to modify this default value.
And then all hell broke lose, and some workmates were angry
The old tenant variable was overwritten with the new default value ‘C:\SomeFolder…’. We didn’t expect it.
I really didn’t expect a Default Value to be able to overwrite some previously configured tenants.
I confirmed it again with another project:
Changing a Default Value in a variable template will overwrite ALL previously configured tenant values.
Step to reproduce: (At least on our server):
-Add a tenant/project/env.
-Observe tenant variables. For instance: InstallationDirectory. It should have a value already. (E.g. 'E:\SomeFolder…)
-Modify the default value for InstallationDirectory in a project variable template.(With ‘C:\SomeFolder’)
-Observe the tenant InstallationDirectory variable again: It’s been overwritten with the new value. (Sadface)
Is that working as intended?
Ideally, we would like to do something similar to this: (Please forgive my pseudo code):
function update_project_variable_template()
for each tenant / env:
if (tenant variable IS NOT NULL)
do nothing
elseif (tenant variable is NULL)
update with default value
Regards,
Damien