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
The Terraform Crash File (errored.tfstate) file is lost when Terraform Pipeline finishes with a failure. Save the (errored.tfstate) when the errors occur to persist state to backend.
Example Fix
post {
always {
script {
if (fileExists("errored.tfstate")) {
archiveArtifacts artifacts: "errored.tfstate", fingerprint: true
}
}
}
}
Error Message
╷
│ Error: Failed to save state
│
│ Error saving state: failed to upload state: AccessDenied: Access Denied
│ status code: 403, request id: FFFFFFFFFFFFFFFF, host id:
│ V2h5IGFyZSB5b3UgcmVhZGluZyB0aGlzIHNvbHV0aW9uPw==
╵
╷
│ Error: Failed to persist state to backend
│
│ The error shown above has prevented Terraform from writing the updated
│ state to the configured backend. To allow for recovery, the state has been
│ written to the file "errored.tfstate" in the current working directory.
│
│ Running "terraform apply" again at this point will create a forked state,
│ making it harder to recover.
│
│ To retry writing this state, use the following command:
│ terraform state push errored.tfstate
│
╵
The text was updated successfully, but these errors were encountered:
The Terraform Crash File (errored.tfstate) file is lost when Terraform Pipeline finishes with a failure. Save the (errored.tfstate) when the errors occur to persist state to backend.
Example Fix
Error Message
The text was updated successfully, but these errors were encountered: