-
Notifications
You must be signed in to change notification settings - Fork 113
[deps] Replace Dependabot with Renovate #7526
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,59 @@ | ||
| --- | ||
| name: update-renovate-branches | ||
|
|
||
| on: | ||
| workflow_dispatch: | ||
| schedule: | ||
| - cron: "0 6 * * 1" | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| env: | ||
| JOB_URL: "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" | ||
|
|
||
| jobs: | ||
| update: | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| contents: write | ||
| pull-requests: write | ||
| steps: | ||
| - id: generator | ||
| uses: elastic/oblt-actions/elastic/active-branches@v1 | ||
| with: | ||
| filter-branches: true | ||
|
|
||
| - uses: actions/checkout@v7 | ||
|
|
||
| - name: Update baseBranchPatterns in renovate.json | ||
| env: | ||
| MATRIX: ${{ steps.generator.outputs.matrix }} | ||
| run: | | ||
| branches=$(printf '%s' "$MATRIX" | jq -c '[.include[].branch]') | ||
| jq --argjson branches "$branches" '.baseBranchPatterns = $branches' \ | ||
| renovate.json > renovate.json.new | ||
| mv renovate.json.new renovate.json | ||
|
|
||
| - uses: peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8.1.1 | ||
| with: | ||
| token: ${{ secrets.GITHUB_TOKEN }} | ||
| commit-message: "[Automation] Update Renovate base branches to current active branches" | ||
| title: "[Automation] Update Renovate base branches to current active branches" | ||
| body: | | ||
| Updates `baseBranchPatterns` in `renovate.json` to match the current set of active release branches queried from the Elastic release schedule. | ||
| branch: update-renovate-branches | ||
| base: main | ||
| delete-branch: true | ||
| labels: | | ||
| automation | ||
| skip-changelog | ||
| backport-skip | ||
| Team:Elastic-Agent-Control-Plane | ||
|
|
||
| - if: ${{ failure() }} | ||
| uses: elastic/oblt-actions/slack/send@v1 | ||
| with: | ||
| bot-token: ${{ secrets.SLACK_BOT_TOKEN }} | ||
| channel-id: "#fleet-notifications" | ||
| message: ":traffic_cone: Renovate branches update failed for `${{ github.repository }}`, @fleet_team please look what's going on <${{ env.JOB_URL }}|here>" |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,73 @@ | ||
| { | ||
| "$schema": "https://docs.renovatebot.com/renovate-schema.json", | ||
| "extends": ["config:recommended"], | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd drop this for now, or we'll get a bunch of updates to unrelated things. We can reenable it later.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Removed in 61f3958. |
||
| "dependencyDashboard": true, | ||
| "enabledManagers": ["gomod", "github-actions", "pre-commit"], | ||
| "baseBranchPatterns": ["main", "9.5", "9.4", "9.3", "8.19"], | ||
| "labels": [ | ||
| "automation", | ||
| "dependency", | ||
| "skip-changelog", | ||
| "backport-skip", | ||
| "Team:Elastic-Agent-Control-Plane" | ||
| ], | ||
| "pre-commit": { | ||
| "enabled": true | ||
| }, | ||
| "packageRules": [ | ||
| { | ||
| "description": "Go modules: schedule, PR limit, and branch prefix", | ||
| "matchManagers": ["gomod"], | ||
| "additionalBranchPrefix": "golang/", | ||
| "schedule": ["on monday"], | ||
| "prConcurrentLimit": 10 | ||
| }, | ||
| { | ||
| "description": "go-dependencies: catch-all group for Go modules not claimed by a more specific group", | ||
| "matchManagers": ["gomod"], | ||
| "groupName": "go-dependencies" | ||
| }, | ||
| { | ||
| "description": "elastic: all Elastic org packages", | ||
| "matchManagers": ["gomod"], | ||
| "matchPackageNames": [ | ||
| "/^github\\.com/elastic//", | ||
| "/^go\\.elastic\\.co//" | ||
| ], | ||
| "groupName": "elastic" | ||
| }, | ||
| { | ||
| "description": "test-tooling: dependencies used for tests and test infrastructure", | ||
| "matchManagers": ["gomod"], | ||
| "matchPackageNames": [ | ||
| "/^github\\.com/testcontainers//", | ||
| "/^github\\.com/Shopify//", | ||
| "/^github\\.com/moby//", | ||
| "/^github\\.com/magefile/mage$/", | ||
| "/^github\\.com/stretchr//" | ||
| ], | ||
| "groupName": "test-tooling" | ||
| }, | ||
| { | ||
| "description": "GitHub Actions: grouped weekly Sunday updates", | ||
| "matchManagers": ["github-actions"], | ||
| "groupName": "github-actions", | ||
| "schedule": ["on sunday"], | ||
| "prConcurrentLimit": 10 | ||
| }, | ||
| { | ||
| "description": "GitHub Actions: keep macOS runner updates manual", | ||
| "matchManagers": ["github-actions"], | ||
| "matchDepTypes": ["github-runner"], | ||
| "matchPackageNames": ["macos"], | ||
| "enabled": false | ||
| }, | ||
| { | ||
| "description": "pre-commit: weekly Sunday updates", | ||
| "matchManagers": ["pre-commit"], | ||
| "schedule": ["on sunday"], | ||
| "addLabels": ["changelog:dependencies"], | ||
| "prConcurrentLimit": 5 | ||
| } | ||
| ] | ||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The branches are named 'renovate/{base}-golang/...' so you need a different wildcard here. See what agent currently has.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in d0beffe.