-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
JSON parse error on beta version of inline extension block for azure_linux_virtual_machine_scale_set resource. #8422
Comments
@brentonoloughlin did you try to add "protected_settings" field to extension block? Cuz I've had the same issue and resolved it just by add empty "protected_settings" field in my extension block. |
Thanks @pakhom for the workaround. adding an empty protected_settings field worked. Since this field is optional in the azurerm_virtual_machine_scale_set_extension resource, it should be similarly optional in the inline extension resource. |
Ran into the same issue. Thanks for the work around! |
Any other updates on this? Adding: protected_settings = "" To my extension block didn't resolve this error for me. |
protected_settings = jsonencode({}) worked for me. |
Thanks for responding. I was able to use the separate resource for creating an extension and set the VMSS to upgrade automatically and it resolved my issue. |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks! |
Community Note
Terraform (and AzureRM Provider) Version
Terraform v0.12.25
Affected Resource(s)
azurerm_linux_virtual_machine_scale_set
Terraform Configuration Files
Debug Output
https://gist.github.com/brentonoloughlin/189c312e321baaa22d2c1e64c727e1fc
Expected Behavior
The Virtual Machine Scale Set resource should have been provisioned with the Azure Disk Encryption extension enabled.
the excerpt from terraform plan shows:
The same inline extension block code works successfully for the
azurerm_virtual_machine_scale_set
resource (with the same terraform version and azurerm provider version). For the 'azurerm_virtual_machine_scale_set' resource, the settings parameter from the terraform plan is slightly different (not sure if this is relevant):Actual Behavior
ARM_PROVIDER_VMSS_EXTENSIONS_BETA=true terraform apply
results in:Steps to Reproduce
ARM_PROVIDER_VMSS_EXTENSIONS_BETA=true terraform apply
The text was updated successfully, but these errors were encountered: