-
Notifications
You must be signed in to change notification settings - Fork 948
[BUG]: 403 failure results in mismatched state #3142
Description
Expected Behavior
Expected GitHub pages to be appropriately applied per the terraform plan.
Actual Behavior
On an initial deployment for a GitHub Page, the terraform apply failed due to our GitHub app not having the appropriate permissions.
After fixing the permissions and rerunning the same workflow, the terraform plan no longer found any changes that needed to be applied. The screenshot above shows the original plan, and the second there were no changes for the github_repository.module. It's as if the first run somehow modified the state to show that a page was actually created, even though it failed. Visiting the GitHub repo settings showed that a page had not been created.
Even after manually creating the page, the terraform plan was still not picking up any changes.
It seems like there's some motivation to refactor pages into its own resource on #3133, #2087, and #1913.
Terraform Version
= 1.7
Affected Resource(s)
- github_repository.module.pages
Terraform Configuration Files
Steps to Reproduce
No response
Debug Output
Panic Output
Code of Conduct
- I agree to follow this project's Code of Conduct