-
-
Notifications
You must be signed in to change notification settings - Fork 14
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
Automate running terraform docs 66 #67
Automate running terraform docs 66 #67
Conversation
…66' into automate-running-terraform-docs-66 update branch
…66' into automate-running-terraform-docs-66 update branch
@chelseybeck @freaky4wrld This is my first draft. Please take a look at it and give feedback for revision. Thank you. |
@awlFCCamp I'm not that much experienced with terraform, but I can definitely review it if you provide me details what changes you've made. Or if @chelseybeck tells me where to start from :) |
Hey @awlFCCamp I think the idea is to make changes to the terraform-plan.yml , and add the new GHA triggers to it... the file Though I'm not sure how you made changes to |
@freaky4wrld Thank you! Chelsey suggested I put changes into a separate file for testing. I will ask her if I need to revert. I made all the changes through the terraform-docs.yml file. I set up testing in my branch, can you elaborate more on "when you have your test-environment ready for it!!" Sorry, My first GitHub action, I am excited but also a bit unsure. |
I was asking if you have tested the GHA in your local repo, if it works fine in the local repo.... it will work here as well, this is the link to the guide in case you need it https://github.com/hackforla/website/wiki/Hack-for-LA's-GitHub-Actions |
@freaky4wrld Thank you. It worked last week https://github.com/awlFCCamp/incubator/actions/runs/8725012627, but it failed here. I will look into it later today. |
@@ -9,7 +9,7 @@ terraform { | |||
} | |||
|
|||
provider "aws" { | |||
region = "us-west-2" | |||
region = "us-east-2" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
curious about this change. this is to a main.tf file, not a readme...and the region should prob be us-west-2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I changed it to trigger the workflow. I probably should have noted that in the PR.
- name: Generate Terraform docs terraform-modules | ||
uses: terraform-docs/[email protected] | ||
with: | ||
working-dir: terraform-modules |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we don't want to run terraform docs in directories that don't have a tf file. this is one of those instances, but we do want to run it inside of the other directories in terraform-modules. i wonder if there's a way to refactor this a little where we get a list of the directories and then loop through it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, Chelsey! Great idea, will look into it.
will make another one from a different branch |
Fixes #66
We need to automate running Terraform Docs whenever a .tf file is changed inside of a Terraform directory. I have changed the region in terraform-incubator/people-depot/dev/main.tf to trigger. I will change back later.