Skip to content

Commit

Permalink
Custom Renovate Manager for Terraform (#600)
Browse files Browse the repository at this point in the history
* Include custom manager for Terraform GitHub workflow

* Refactor Renovate configuration and workflows

Refactored the Renovate configuration and workflows to improve the system's overall efficiency and maintainability. Made the following changes:
- Replaced custom managers with regex managers in ".github/renovate.json"
- Modified the match strings in the regex manager to target specific files and extract version information
- Updated the dependencies and added the necessary environment variables in ".github/workflows/renovate.yml"
- Removed explicit names of actions in the workflow steps and simplified the checkout and token generation steps
  • Loading branch information
ashdavies authored Oct 21, 2023
1 parent a095a91 commit 008541c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
3 changes: 1 addition & 2 deletions .github/renovate.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"customManagers": [
"regexManagers": [
{
"datasourceTemplate": "github-releases",
"depNameTemplate": "hashicorp/terraform",
"extractVersionTemplate": "v(?<version>.*)",
"fileMatch": "^\\.github/workflows/.*\\.yaml",
"matchStrings": ["terraform_version: (?<currentValue>.*)"]
}
Expand Down
9 changes: 3 additions & 6 deletions .github/workflows/renovate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,18 +26,15 @@ jobs:
# - name: Permissions Monitor
# uses: GitHubSecurityLab/actions-permissions/monitor@v1

- name: Checkout
uses: actions/[email protected]
- uses: actions/[email protected]

- name: Generate Token
id: generate_token
- id: generate_token
uses: tibdex/github-app-token@v2
with:
private_key: ${{ secrets.PRIVATE_KEY }}
app_id: ${{ secrets.APP_ID }}

- name: Self-hosted Renovate
uses: renovatebot/[email protected]
- uses: renovatebot/[email protected]
env:
LOG_LEVEL: ${{ inputs.logLevel || 'INFO' }}
with:
Expand Down

0 comments on commit 008541c

Please sign in to comment.