mirror of
https://github.com/complexcaresolutions/cms.c2sgmbh.git
synced 2026-03-17 20:54:11 +00:00
- Daily npm dependency checks at 04:00 Europe/Berlin - Grouped updates: payload-core, react-nextjs, fullcalendar, dev-deps - Weekly GitHub Actions updates - Auto-merge workflow for patch updates after CI passes - Minor dev-dependency updates also auto-merged - Critical after CVE-2025-55182 incident on 2025-12-09
45 lines
1.4 KiB
YAML
45 lines
1.4 KiB
YAML
name: Dependabot Auto-Merge
|
|
|
|
on:
|
|
pull_request:
|
|
|
|
permissions:
|
|
contents: write
|
|
pull-requests: write
|
|
|
|
jobs:
|
|
auto-merge:
|
|
name: Auto-merge patch updates
|
|
runs-on: ubuntu-latest
|
|
if: github.actor == 'dependabot[bot]'
|
|
steps:
|
|
- name: Fetch Dependabot metadata
|
|
id: metadata
|
|
uses: dependabot/fetch-metadata@v2
|
|
with:
|
|
github-token: "${{ secrets.GITHUB_TOKEN }}"
|
|
|
|
- name: Wait for CI to pass
|
|
uses: lewagon/wait-on-check-action@v1.3.4
|
|
with:
|
|
ref: ${{ github.event.pull_request.head.sha }}
|
|
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
|
check-name: "CI Success"
|
|
wait-interval: 30
|
|
allowed-conclusions: success
|
|
|
|
- name: Auto-merge patch updates
|
|
if: steps.metadata.outputs.update-type == 'version-update:semver-patch'
|
|
run: gh pr merge --auto --squash "$PR_URL"
|
|
env:
|
|
PR_URL: ${{ github.event.pull_request.html_url }}
|
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- name: Auto-merge minor updates (dev dependencies only)
|
|
if: >-
|
|
steps.metadata.outputs.update-type == 'version-update:semver-minor' &&
|
|
steps.metadata.outputs.dependency-type == 'direct:development'
|
|
run: gh pr merge --auto --squash "$PR_URL"
|
|
env:
|
|
PR_URL: ${{ github.event.pull_request.html_url }}
|
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|