Skip to content

Commit

Permalink
Merge pull request #55 from equinix-labs/fix_github_actions_documenta…
Browse files Browse the repository at this point in the history
…tion

fix insufficient permission error and revert changes in #51
  • Loading branch information
ocobles authored Feb 8, 2023
2 parents 73bf908 + ebeeb73 commit d31f141
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/documentation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ jobs:
id: actions-checkout
with:
ref: main
set-safe-directory: "false"

- name: Render terraform docs inside the main and the modules README.md files and push changes back to PR branch
id: terraform-docs
Expand All @@ -27,6 +26,12 @@ jobs:
indention: 3
git-push: "false"

# terraform-docs/[email protected] modifies .git files with owner root:root, and the following steps fail with
# insufficient permission for adding an object to repository database .git/objects
# since the expected user is runner:docker. See https://github.com/terraform-docs/gh-actions/issues/90
- name: Fix .git owner
run: sudo chown runner:docker -R .git

- name: Create Pull Request
if: steps.terraform-docs.outputs.num_changed != '0'
uses: peter-evans/create-pull-request@v4
Expand Down

0 comments on commit d31f141

Please sign in to comment.