You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the nebari config file, there are some values which should only be set for the initial deployment, and there are some values that can be changed even after the initial deployment without ill effect.
Examples of values which should probably only be set once are "project_name", "provider", "terraform_state", and some of the "storage" section settings on some of the cloud providers.
Those values can be changed, but will usually result in an undesired and unexpected change during the next deployment. For example, if you change the project name, your entire cluster will be destroyed and a new cluster will be created. If provider is changed, then a similar destruction and recreation occurs. If you change terraform_state from remote to local, I believe you get an error message that we haven't documented how we users should resolve it. As for storage, I believe on some of the cloud providers, if the storage sizes are changed, the disk is deleted and a new one is created. Anyway, you get the idea.
It would improve user experience if we disallow changes to certain values and display a helpful error message. This is not possible currently b/c we can't detect when a value changes b/c we don't track changes to the nebari-config file in nebari. I propose we start doing so. For the examples I've listed above we would only need to store the values from the prior applied nebari-config.
The way I propose we do this is by storing the prior applied nebari config file in the terraform state (e.g. via a terraform_data resource). We can then read it, note the changes and raise warnings or errors as desired if there were any disallowed changes in a new stage between the current stage 1 and stage 2. There may be some edge cases to think through, but that is the general idea.
Ideally, the checks for disallowed changes should be stored in the code for each stage so extensions can also specify what is allowed/disallowed. Then we run all those checks on this new stage 1.5 (for lack of a better name atm).
Value and/or benefit
Better User Experience
Anything else?
No response
The text was updated successfully, but these errors were encountered:
Adam-D-Lewis
changed the title
[ENH] - Create a way to prevent certain changes to the nebari-config file
[ENH] - Prevent unsupported changes to the nebari-config file
Aug 1, 2024
Might be worth as context, but we already save the config file as a secret as part of the helm extension stage (if I am not mistaken), also it's kept in a /temp location when render is called.
Feature description
In the nebari config file, there are some values which should only be set for the initial deployment, and there are some values that can be changed even after the initial deployment without ill effect.
Examples of values which should probably only be set once are "project_name", "provider", "terraform_state", and some of the "storage" section settings on some of the cloud providers.
Those values can be changed, but will usually result in an undesired and unexpected change during the next deployment. For example, if you change the project name, your entire cluster will be destroyed and a new cluster will be created. If provider is changed, then a similar destruction and recreation occurs. If you change terraform_state from remote to local, I believe you get an error message that we haven't documented how we users should resolve it. As for storage, I believe on some of the cloud providers, if the storage sizes are changed, the disk is deleted and a new one is created. Anyway, you get the idea.
It would improve user experience if we disallow changes to certain values and display a helpful error message. This is not possible currently b/c we can't detect when a value changes b/c we don't track changes to the nebari-config file in nebari. I propose we start doing so. For the examples I've listed above we would only need to store the values from the prior applied nebari-config.
The way I propose we do this is by storing the prior applied nebari config file in the terraform state (e.g. via a terraform_data resource). We can then read it, note the changes and raise warnings or errors as desired if there were any disallowed changes in a new stage between the current stage 1 and stage 2. There may be some edge cases to think through, but that is the general idea.
Ideally, the checks for disallowed changes should be stored in the code for each stage so extensions can also specify what is allowed/disallowed. Then we run all those checks on this new stage 1.5 (for lack of a better name atm).
Value and/or benefit
Better User Experience
Anything else?
No response
The text was updated successfully, but these errors were encountered: