I am currently trying to represent a new google cloud project in terraform. To complete this I still need to create the domain mapping of my cloudrun instance in terraform.
The domain mapping has already been created in the UI and Terraform cannot overwrite it. When I run terraform apply I get an error message that the domain mapping already exists.
I first tried to import the domain mapping with terraform import. This command returns a success message, as soon as I run terraform apply I get an error message that the domain mapping already exists but is flagged for deletion, I should try the command again after the complete deletion. A few hours later, the resource is still not deleted.
Next I tried to delete the domain mapping in the UI. This does not work, I get the message:
Delete domain mapping failed. Deletion in progress. Resource readiness deadline exceeded.
I have also tried it via the command line interface:
gcloud beta run domain-mappings delete --domain=\<domain\> --namespace=\<namespace\>
But I get the same error message as before.
Does anybody know another way of deleting / importing / fixing /workaround this problem, I'd appreciate any help!