-
Notifications
You must be signed in to change notification settings - Fork 41
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
inf-terraform-aws - preserve errored.tfstate file in case of write failure in make deploy #665
Comments
Error message:
|
I assume this error occurs because the policy for the shared S3 bucket has not been updated for the given account. I also assume this error will not occur when we switch to dedicated S3 buckets to store the TF state for each account -am I right ? |
The error was raised as the bucket policy wasn't set properly. I cannot tell all error conditions which could come up nevertheless if terraform errors out and leaves a file |
https://www.jenkins.io/doc/pipeline/steps/core/ ==>
|
I would like to see this feature into the new InfrastructureService provided by the Jenkins Shared Library #740 - draft should be available by early next week. |
In case terraform cannot upload the state file to the configured bucket it writes it to a file
errored.tfstate
.It is important to preserve this file so that manual error handling can be done (e.g. upload file manually).
In addition it might be beneficial to check before that permissions and infrastructure setup is properly configured for running the terraform deploy command.
ods-quickstarters/inf-terraform-aws/Jenkinsfile.template
Lines 227 to 233 in 35ca70f
FYI: @nichtraunzer
The text was updated successfully, but these errors were encountered: