Skip to content

Commit

Permalink
Merge pull request #1 from blackbird-cloud/bb-repo-manager-updates
Browse files Browse the repository at this point in the history
Merge pull request 1 from bb-repo-manager-updates
  • Loading branch information
blackbirdcloudrepomanager[bot] authored Sep 13, 2024
2 parents bf5fac9 + 2583eaf commit a4ec046
Show file tree
Hide file tree
Showing 6 changed files with 35 additions and 23 deletions.
4 changes: 2 additions & 2 deletions .config/.terraform-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ sections:
- modules

content: |-
# AWS GuardDuty Organization configuration Terraform module
A Terraform module which configures your AWS GuardDuty. https://docs.aws.amazon.com/guardduty/latest/ug/what-is-guardduty.html
{{ include "./.config/title.md"}}
{{ .Header }}
## Example
Expand Down
2 changes: 1 addition & 1 deletion .config/footer.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ Checkout our other :point_right: [terraform modules](https://registry.terraform.

## Copyright

Copyright © 2017-2023 [Blackbird Cloud](https://www.blackbird.cloud)
Copyright © 2017-2024 [Blackbird Cloud](https://blackbird.cloud)
2 changes: 1 addition & 1 deletion .config/header.md
Original file line number Diff line number Diff line change
@@ -1 +1 @@
[![blackbird-logo](https://raw.githubusercontent.com/blackbird-cloud/terraform-module-template/main/.config/logo_simple.png)](https://www.blackbird.cloud)
[![blackbird-logo](https://raw.githubusercontent.com/blackbird-cloud/terraform-module-template/main/.config/logo_simple.png)](https://blackbird.cloud)
2 changes: 2 additions & 0 deletions .config/title.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Terraform Aws Guardduty Organization Module
Terraform module to setup AWS GuardDuty in an organization
11 changes: 6 additions & 5 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
name: Validate and Format
# on: push

on:
pull_request_target:
types: [opened, synchronize]
workflow_dispatch:
# pull_request_target:
# types: [opened, synchronize]

jobs:
format:
Expand All @@ -11,7 +12,7 @@ jobs:
container: blackbirdcloud/terraform-toolkit:latest
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.ref }}
Expand All @@ -30,4 +31,4 @@ jobs:
- name: Commit and push
uses: EndBug/add-and-commit@v9
with:
default_author: github_actions
default_author: github_actions
37 changes: 23 additions & 14 deletions .github/workflows/readme.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,28 @@
name: Generate terraform docs
name: Generate Readme

on:
- pull_request
push:
branches:
- main
workflow_dispatch:

jobs:
docs:
generate-readme:
runs-on: ubuntu-latest
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@main
with:
working-dir: .
output-file: README.md
output-method: inject
git-push: "true"
- uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ vars.BB_REPO_MANAGER_APP_ID }}
private-key: ${{ secrets.BB_REPO_MANAGER_SECRET }}
- uses: actions/checkout@v4
with:
token: ${{ steps.app-token.outputs.token }}
- name: Render terraform docs and push changes back to PR
uses: terraform-docs/gh-actions@main
with:
working-dir: .
config-file: .config/.terraform-docs.yml
git-push: "true"
output-method: replace

0 comments on commit a4ec046

Please sign in to comment.