From 64a88f0269527d581ffcdde001491c1786e56145 Mon Sep 17 00:00:00 2001 From: amartingarcia Date: Wed, 7 Aug 2024 08:36:17 +0200 Subject: [PATCH 1/7] feat: Update repository --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index f6d2a39..681c6c0 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ provider "nexus" { ```hcl module "nexus_routing" { - source = "terraform-nexus-modules/routing/nexus" + source = "devops-ia/routing/nexus" version = "1.0.0" nexus_routing_rule = [ @@ -42,7 +42,7 @@ module "nexus_routing" { ```hcl module "nexus_routing_rule" { - source = "terraform-nexus-modules/routing/nexus//modules/nexus-routing-rule" + source = "devops-ia/routing/nexus//modules/nexus-routing-rule" version = "1.0.0" name = "stop-leaks" From 27331fabecaea4c2e22621b6aead2975ad037d20 Mon Sep 17 00:00:00 2001 From: amartingarcia Date: Wed, 7 Aug 2024 08:38:50 +0200 Subject: [PATCH 2/7] feat: Update repository --- .github/dependabot.yml | 18 ++++++++++++++++++ .github/workflows/auto-assign.yaml | 20 ++++++++++++++++++++ .github/workflows/lock.yml | 10 +++++----- .github/workflows/pr-tittle.yml | 4 ++-- .github/workflows/release.yml | 13 ++++++------- .github/workflows/stale-actions.yaml | 6 +++--- 6 files changed, 54 insertions(+), 17 deletions(-) create mode 100644 .github/dependabot.yml create mode 100644 .github/workflows/auto-assign.yaml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..845062f --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,18 @@ +version: 2 +updates: + - package-ecosystem: github-actions + directory: "/" + schedule: + interval: monthly + open-pull-requests-limit: 10 + labels: + - enhancement + - dependency-management + - package-ecosystem: terraform + directory: "/" + schedule: + interval: monthly + open-pull-requests-limit: 10 + labels: + - enhancement + - dependency-management diff --git a/.github/workflows/auto-assign.yaml b/.github/workflows/auto-assign.yaml new file mode 100644 index 0000000..36d7025 --- /dev/null +++ b/.github/workflows/auto-assign.yaml @@ -0,0 +1,20 @@ +name: Auto-assign Issue +on: + issues: + types: [opened] + pull_request: + types: [opened, edited, synchronize, reopened] +jobs: + run: + runs-on: ubuntu-latest + permissions: + issues: write + pull-requests: write + + steps: + - name: "auto-assign issue" + uses: pozil/auto-assign-issue@v2 + with: + repo-token: ${{ secrets.PAT_GITHUB }} + teams: devops-ia + removePreviousAssignees: true diff --git a/.github/workflows/lock.yml b/.github/workflows/lock.yml index 12953b9..81fc8d3 100644 --- a/.github/workflows/lock.yml +++ b/.github/workflows/lock.yml @@ -1,8 +1,8 @@ -name: 'Lock Threads' +name: "Lock Threads" on: schedule: - - cron: '50 1 * * *' + - cron: "50 1 * * *" jobs: lock: @@ -10,12 +10,12 @@ jobs: steps: - uses: dessant/lock-threads@v4 with: - github-token: ${{ secrets.GH_TOKEN }} + github-token: ${{ secrets.PAT_GITHUB }} issue-comment: > I'm going to lock this issue because it has been closed for _30 days_ ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. - issue-inactive-days: '30' + issue-inactive-days: "30" pr-comment: > I'm going to lock this pull request because it has been closed for _30 days_ ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. - pr-inactive-days: '30' + pr-inactive-days: "30" diff --git a/.github/workflows/pr-tittle.yml b/.github/workflows/pr-tittle.yml index 4abbbce..23d93c9 100644 --- a/.github/workflows/pr-tittle.yml +++ b/.github/workflows/pr-tittle.yml @@ -1,4 +1,4 @@ -name: 'Validate PR title' +name: "Validate PR title" on: pull_request_target: @@ -16,7 +16,7 @@ jobs: # https://github.com/amannn/action-semantic-pull-request/releases - uses: amannn/action-semantic-pull-request@v5.0.2 env: - GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} + GITHUB_TOKEN: ${{ secrets.PAT_GITHUB }} with: # Configure which types are allowed. # Default: https://github.com/commitizen/conventional-commit-types diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e93709b..62b558d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -5,19 +5,18 @@ on: push: branches: - main - - master paths: - - '**/*.tpl' - - '**/*.py' - - '**/*.tf' - - '.github/workflows/release.yml' + - "**/*.tpl" + - "**/*.py" + - "**/*.tf" + - ".github/workflows/release.yml" jobs: release: name: Release runs-on: ubuntu-latest # Skip running release workflow on forks - if: github.repository_owner == 'terraform-nexus-modules' + if: github.repository_owner == 'devops-ia' steps: - name: Checkout uses: actions/checkout@v4 @@ -34,4 +33,4 @@ jobs: @semantic-release/git@10.0.0 conventional-changelog-conventionalcommits@4.6.3 env: - GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} + GITHUB_TOKEN: ${{ secrets.PAT_GITHUB }} diff --git a/.github/workflows/stale-actions.yaml b/.github/workflows/stale-actions.yaml index 5d1e246..4d806c3 100644 --- a/.github/workflows/stale-actions.yaml +++ b/.github/workflows/stale-actions.yaml @@ -1,7 +1,7 @@ -name: 'Mark or close stale issues and PRs' +name: "Mark or close stale issues and PRs" on: schedule: - - cron: '0 0 * * *' + - cron: "0 0 * * *" jobs: stale: @@ -9,7 +9,7 @@ jobs: steps: - uses: actions/stale@v6 with: - repo-token: ${{ secrets.GH_TOKEN }} + repo-token: ${{ secrets.PAT_GITHUB }} # Staling issues and PR's days-before-stale: 30 stale-issue-label: stale From 2e73a35079e8050f912d76a639e75f8cf21521b5 Mon Sep 17 00:00:00 2001 From: amartingarcia Date: Wed, 7 Aug 2024 08:46:29 +0200 Subject: [PATCH 3/7] feat: Update repository --- .github/workflows/lock.yml | 4 ++-- .github/workflows/pre-commit.yml | 35 ++++++++++++++++++++-------- .github/workflows/release.yml | 10 ++++---- .github/workflows/stale-actions.yaml | 4 ++-- 4 files changed, 34 insertions(+), 19 deletions(-) diff --git a/.github/workflows/lock.yml b/.github/workflows/lock.yml index 81fc8d3..220ee0d 100644 --- a/.github/workflows/lock.yml +++ b/.github/workflows/lock.yml @@ -8,9 +8,9 @@ jobs: lock: runs-on: ubuntu-latest steps: - - uses: dessant/lock-threads@v4 + - uses: dessant/lock-threads@v5 with: - github-token: ${{ secrets.PAT_GITHUB }} + github-token: ${{ secrets.GITHUB_TOKEN }} issue-comment: > I'm going to lock this issue because it has been closed for _30 days_ ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. diff --git a/.github/workflows/pre-commit.yml b/.github/workflows/pre-commit.yml index 17d8244..7386126 100644 --- a/.github/workflows/pre-commit.yml +++ b/.github/workflows/pre-commit.yml @@ -4,11 +4,10 @@ on: pull_request: branches: - main - - master env: TERRAFORM_DOCS_VERSION: v0.16.0 - TFLINT_VERSION: v0.44.1 + TFLINT_VERSION: v0.50.3 jobs: collectInputs: @@ -22,7 +21,7 @@ jobs: - name: Get root directories id: dirs - uses: clowdhaus/terraform-composite-actions/directories@v1.8.3 + uses: clowdhaus/terraform-composite-actions/directories@v1.9.0 preCommitMinVersions: name: Min TF pre-commit @@ -32,38 +31,54 @@ jobs: matrix: directory: ${{ fromJson(needs.collectInputs.outputs.directories) }} steps: + # https://github.com/orgs/community/discussions/25678#discussioncomment-5242449 + - name: Delete huge unnecessary tools folder + run: | + rm -rf /opt/hostedtoolcache/CodeQL + rm -rf /opt/hostedtoolcache/Java_Temurin-Hotspot_jdk + rm -rf /opt/hostedtoolcache/Ruby + rm -rf /opt/hostedtoolcache/go + - name: Checkout uses: actions/checkout@v4 - name: Terraform min/max versions id: minMax - uses: clowdhaus/terraform-min-max@v1.2.7 + uses: clowdhaus/terraform-min-max@v1.3.0 with: directory: ${{ matrix.directory }} - name: Pre-commit Terraform ${{ steps.minMax.outputs.minVersion }} # Run only validate pre-commit check on min version supported if: ${{ matrix.directory != '.' }} - uses: clowdhaus/terraform-composite-actions/pre-commit@v1.8.3 + uses: clowdhaus/terraform-composite-actions/pre-commit@v1.9.0 with: terraform-version: ${{ steps.minMax.outputs.minVersion }} tflint-version: ${{ env.TFLINT_VERSION }} - args: 'terraform_validate --color=always --show-diff-on-failure --files ${{ matrix.directory }}/*' + args: "terraform_validate --color=always --show-diff-on-failure --files ${{ matrix.directory }}/*" - name: Pre-commit Terraform ${{ steps.minMax.outputs.minVersion }} # Run only validate pre-commit check on min version supported if: ${{ matrix.directory == '.' }} - uses: clowdhaus/terraform-composite-actions/pre-commit@v1.8.3 + uses: clowdhaus/terraform-composite-actions/pre-commit@v1.9.0 with: terraform-version: ${{ steps.minMax.outputs.minVersion }} tflint-version: ${{ env.TFLINT_VERSION }} - args: 'terraform_validate --color=always --show-diff-on-failure --files $(ls *.tf)' + args: "terraform_validate --color=always --show-diff-on-failure --files $(ls *.tf)" preCommitMaxVersion: name: Max TF pre-commit runs-on: ubuntu-latest needs: collectInputs steps: + # https://github.com/orgs/community/discussions/25678#discussioncomment-5242449 + - name: Delete huge unnecessary tools folder + run: | + rm -rf /opt/hostedtoolcache/CodeQL + rm -rf /opt/hostedtoolcache/Java_Temurin-Hotspot_jdk + rm -rf /opt/hostedtoolcache/Ruby + rm -rf /opt/hostedtoolcache/go + - name: Checkout uses: actions/checkout@v4 with: @@ -72,10 +87,10 @@ jobs: - name: Terraform min/max versions id: minMax - uses: clowdhaus/terraform-min-max@v1.2.7 + uses: clowdhaus/terraform-min-max@v1.3.0 - name: Pre-commit Terraform ${{ steps.minMax.outputs.maxVersion }} - uses: clowdhaus/terraform-composite-actions/pre-commit@v1.8.3 + uses: clowdhaus/terraform-composite-actions/pre-commit@v1.9.0 with: terraform-version: ${{ steps.minMax.outputs.maxVersion }} tflint-version: ${{ env.TFLINT_VERSION }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 62b558d..8f6ee4a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -25,12 +25,12 @@ jobs: fetch-depth: 0 - name: Release - uses: cycjimmy/semantic-release-action@v3 + uses: cycjimmy/semantic-release-action@v4 with: - semantic_version: 18.0.0 + semantic_version: 23.0.2 extra_plugins: | - @semantic-release/changelog@6.0.0 - @semantic-release/git@10.0.0 - conventional-changelog-conventionalcommits@4.6.3 + @semantic-release/changelog@6.0.3 + @semantic-release/git@10.0.1 + conventional-changelog-conventionalcommits@7.0.2 env: GITHUB_TOKEN: ${{ secrets.PAT_GITHUB }} diff --git a/.github/workflows/stale-actions.yaml b/.github/workflows/stale-actions.yaml index 4d806c3..b940ba0 100644 --- a/.github/workflows/stale-actions.yaml +++ b/.github/workflows/stale-actions.yaml @@ -7,9 +7,9 @@ jobs: stale: runs-on: ubuntu-latest steps: - - uses: actions/stale@v6 + - uses: actions/stale@v9 with: - repo-token: ${{ secrets.PAT_GITHUB }} + repo-token: ${{ secrets.GITHUB_TOKEN }} # Staling issues and PR's days-before-stale: 30 stale-issue-label: stale From 02f41dd4ec16babaeed3a97a1e9df280965c4d1b Mon Sep 17 00:00:00 2001 From: amartingarcia Date: Wed, 7 Aug 2024 08:51:31 +0200 Subject: [PATCH 4/7] feat: Update repository --- .github/workflows/pr-tittle.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pr-tittle.yml b/.github/workflows/pr-tittle.yml index 23d93c9..25be321 100644 --- a/.github/workflows/pr-tittle.yml +++ b/.github/workflows/pr-tittle.yml @@ -14,9 +14,9 @@ jobs: steps: # Please look up the latest version from # https://github.com/amannn/action-semantic-pull-request/releases - - uses: amannn/action-semantic-pull-request@v5.0.2 + - uses: amannn/action-semantic-pull-request@v5 env: - GITHUB_TOKEN: ${{ secrets.PAT_GITHUB }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: # Configure which types are allowed. # Default: https://github.com/commitizen/conventional-commit-types From d9e9bcc9715fc698352f0265e60a6117044bd7fd Mon Sep 17 00:00:00 2001 From: amartingarcia Date: Wed, 7 Aug 2024 08:53:48 +0200 Subject: [PATCH 5/7] feat: Update repository --- .github/workflows/pr-tittle.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pr-tittle.yml b/.github/workflows/pr-tittle.yml index 25be321..fe665dc 100644 --- a/.github/workflows/pr-tittle.yml +++ b/.github/workflows/pr-tittle.yml @@ -14,9 +14,9 @@ jobs: steps: # Please look up the latest version from # https://github.com/amannn/action-semantic-pull-request/releases - - uses: amannn/action-semantic-pull-request@v5 + - uses: amannn/action-semantic-pull-request@v5.0.2 env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_TOKEN: ${{ secrets.GITHB_PERSONAL_TOKEN }} with: # Configure which types are allowed. # Default: https://github.com/commitizen/conventional-commit-types From 39814b6121b76007ed8a882412cde37d82448147 Mon Sep 17 00:00:00 2001 From: amartingarcia Date: Wed, 7 Aug 2024 08:55:41 +0200 Subject: [PATCH 6/7] feat: Update repository --- .github/workflows/pr-tittle.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pr-tittle.yml b/.github/workflows/pr-tittle.yml index fe665dc..23d93c9 100644 --- a/.github/workflows/pr-tittle.yml +++ b/.github/workflows/pr-tittle.yml @@ -16,7 +16,7 @@ jobs: # https://github.com/amannn/action-semantic-pull-request/releases - uses: amannn/action-semantic-pull-request@v5.0.2 env: - GITHUB_TOKEN: ${{ secrets.GITHB_PERSONAL_TOKEN }} + GITHUB_TOKEN: ${{ secrets.PAT_GITHUB }} with: # Configure which types are allowed. # Default: https://github.com/commitizen/conventional-commit-types From 8d33e2e5c5f499ef81aef7a25f76228b9669984d Mon Sep 17 00:00:00 2001 From: amartingarcia Date: Wed, 7 Aug 2024 08:59:58 +0200 Subject: [PATCH 7/7] feat: Update repository --- .github/workflows/pr-tittle.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pr-tittle.yml b/.github/workflows/pr-tittle.yml index 23d93c9..34581ec 100644 --- a/.github/workflows/pr-tittle.yml +++ b/.github/workflows/pr-tittle.yml @@ -1,7 +1,7 @@ name: "Validate PR title" on: - pull_request_target: + pull_request: types: - opened - edited