Closed psyreactor closed 2 years ago
From the stack trace. It looks like it’s erroring trying to create the storage account. When you get a chance, can you change the logger level to debug and run again.
Docs: https://terraspace.cloud/docs/config/app/
Wondering if there’s more info in the http response from the Azure API. Increasing the log level should show more info.
Hi, the terraspace debug does not provide any important information. But the armrest can be debugged with the following environment variable ARMREST_LOG_LEVEL
export ARMREST_LOG_LEVEL=debug
In the logs you can clearly see the error
D, [2022-03-04T07:57:31.499945 #1077405] DEBUG -- : PUT https://management.azure.com/subscriptions/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx/resourceGroups/production-eastus/providers/Microsoft.Storage/storageAccounts/tsxxxdeastusproduction?api-version=2021-04-01
D, [2022-03-04T07:57:32.822620 #1077405] DEBUG -- : resp #<Net::HTTPConflict:0x0000560f22ef4d18>
D, [2022-03-04T07:57:32.822705 #1077405] DEBUG -- : resp.code 409
D, [2022-03-04T07:57:32.822729 #1077405] DEBUG -- : resp.body {"error":{"code":"MissingSubscriptionRegistration","message":"The subscription is not registered to use namespace 'Microsoft.Storage'. See https://aka.ms/rps-not-found for how to register subscriptions.","details":[{"code":"MissingSubscriptionRegistration","target":"Microsoft.Storage","message":"The subscription is not registered to use namespace 'Microsoft.Storage'. See https://aka.ms/rps-not-found for how to register subscriptions."}]}}
To fix the issue run the following command from the azure cli
az provider register --namespace Microsoft.Storage
now it works perfect
Thanks for the help
Checklist
My Environment
Expected Behaviour
Current Behavior
I create the application account in azure, validate the configuration with azure_check.rb without errors. But when I run terraspace plan kuberntes getting the error # (Armrest::Error).
Sorry for my English, I speak Spanish
Step-by-step reproduction instructions
terraspace plan logs
Code Sample
It fails before executing my terraform code, it fails when trying to create the storage of the tf_state
Solution Suggestion