Skip to content

fix: remove_old_admin_gui #135

fix: remove_old_admin_gui

fix: remove_old_admin_gui #135

name: Generate documentation
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
collectInputs:
name: Collect workflow inputs
runs-on: ubuntu-latest
outputs:
directories: ${{ steps.search.outputs.directories }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Get root directories
id: dirs
uses: clowdhaus/terraform-composite-actions/directories@v1.8.3
- name: Get list of directories separated with comma
id: search
run: |
DIRS=$(echo '${{ steps.dirs.outputs.directories }}' | jq -r '. | join(",")')
echo "directories=$DIRS" >> $GITHUB_OUTPUT
terraformDocs:
name: Generate Terraform documentation
runs-on: ubuntu-latest
needs: collectInputs
steps:
- uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.ref }}
- name: Render terraform docs and push changes back to PR
uses: terraform-docs/gh-actions@v1.0.0
with:
working-dir: ${{ needs.collectInputs.outputs.directories }}
output-file: README.md
template: |-
<!-- BEGIN_TF_DOCS -->
{{ .Content }}
<!-- END_TF_DOCS -->
output-method: inject
indention: 2
git-push: true
git-commit-message: "terraform-docs: automated action"