-
Notifications
You must be signed in to change notification settings - Fork 2
48 lines (43 loc) · 1.37 KB
/
update_version.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Create PRs for new CoreDNS versions
on:
workflow_dispatch:
schedule:
- cron: "0 10 * * *"
pull_request:
branches:
- main
jobs:
generator:
name: Generate Step for new CoreDNS versions
runs-on: ubuntu-24.04
steps:
- name: Checkout rock repository
uses: actions/checkout@v4
with:
path: coredns-rock
ref: ${{ github.head_ref || 'main' }}
- name: Checkout coredns repository
uses: actions/checkout@v4
with:
repository: coredns/coredns
path: coredns
fetch-tags: true
fetch-depth: 0
- name: Craft using Make target
id: emit-rockcraft
run: |
pushd coredns-rock
make COREDNS_GIT_DIR=../coredns update-component
popd
- name: Commit and push new rockcraft.yaml
id: commit-rockcraft
if: ${{ steps.emit-rockcraft.outputs.tags != '[]' }}
uses: peter-evans/create-pull-request@v7
with:
commit-message: Update CoreDNS versions with ${{ join(fromJSON(steps.emit-rockcraft.outputs.tags), ', ') }}
title: "Update CoreDNS versions"
body: Update CoreDNS versions with ${{ join(fromJSON(steps.emit-rockcraft.outputs.tags), ', ') }}
path: coredns-rock
branch: autoupdate/sync/coredns
delete-branch: true
base: main