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
When using bash scripts inside VM user data, those scripts are usually only run at VM startup, and on a clean system, to make run-time tunings to the OS. When updating the user_data field, today the provider tells the user that an in-place update will take place, and implements this via a stop/update/start cycle.
This has the inconvenient of:
Not triggering any change in the existing VMs (unless specific provision is made) - but still having them powered off/on.
Not allowing automatic VM replacements when clean-state provisioning scripts are written.
Attempted Solutions
Work-around is manually using terraform apply -replace, and lifecycle ignores.
It seems that TF lifecycle .replace_triggered_by is not applicable to resource own attributes.
Proposal
Provide an optional setting in the resource that would alter the behavior of the user_data triggered change, letting the user choose between in-place updating (stop, start) and VM replacement.
The text was updated successfully, but these errors were encountered:
Current Terraform Version
Use-cases
When using bash scripts inside VM user data, those scripts are usually only run at VM startup, and on a clean system, to make run-time tunings to the OS. When updating the user_data field, today the provider tells the user that an in-place update will take place, and implements this via a stop/update/start cycle.
This has the inconvenient of:
Attempted Solutions
Work-around is manually using
terraform apply -replace
, and lifecycle ignores.It seems that TF
lifecycle
.replace_triggered_by
is not applicable to resource own attributes.Proposal
Provide an optional setting in the resource that would alter the behavior of the
user_data
triggered change, letting the user choose between in-place updating (stop, start) and VM replacement.The text was updated successfully, but these errors were encountered: