forked from kubernetes/website
-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (51 loc) · 1.75 KB
/
Copy pathupdate-schedule.yml
File metadata and controls
57 lines (51 loc) · 1.75 KB
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
49
50
51
52
53
54
55
56
57
name: Update schedule.yaml
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * *' # daily
jobs:
create-pull-request:
name: Create PR (if required)
permissions:
contents: write
pull-requests: write
if: github.repository == 'kubernetes/website'
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
fetch-depth: 0
- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
with:
go-version: '1.22'
check-latest: true
- name: Install schedule-builder
run: go install k8s.io/release/cmd/[email protected]
- name: Update schedule.yaml
run: |
for i in 1 2 3; do
schedule-builder -uc data/releases/schedule.yaml -e data/releases/eol.yaml && break
echo "schedule-builder failed, retrying ($i/3)..." >&2
sleep 20
done
- name: Check workspace
id: create_pr
run: |
if [[ $(git diff --stat) != '' ]]; then
echo "create_pr=true" >> "$GITHUB_OUTPUT"
fi
- name: Create Pull Request
uses: peter-evans/create-pull-request@5f6978faf089d4d20b00c7766989d076bb2fc7f1 # v8.1.1
if: ${{ steps.create_pr.outputs.create_pr == 'true' }}
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: Update schedule.yaml
title: Update release schedule.yaml
body: |
Update release schedule.yaml
/cc @kubernetes/release-managers
labels: area/release-eng, sig/release, sig/docs
branch: update-schedule
delete-branch: true
signoff: true