-
Notifications
You must be signed in to change notification settings - Fork 12
105 lines (92 loc) · 3.58 KB
/
trigger-fdo-container.yml
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
---
name: FDO container test trigger
on:
workflow_dispatch:
schedule:
# run 8:05 every Sunday
- cron: '5 8 * * 0'
# run 8:05 every Thursday
- cron: '5 8 * * 4'
# run every day
- cron: '0 3 * * *'
jobs:
fdo-container-community:
if: github.repository == 'virt-s1/rhel-edge' && github.event.schedule == '5 8 * * 0'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Make change for PR creating
run: |
echo "fdo-container" > fdo-container.run
- name: Get current date
id: date
run: echo "date=$(date +'%Y-%m-%d')" >> $GITHUB_OUTPUT
- name: Create Pull Request
id: cpr
uses: peter-evans/create-pull-request@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: "FDO community container test - ${{ steps.date.outputs.date }}"
committer: cloudkitebot <[email protected]>
author: ${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>
branch: cpr
branch-suffix: random
delete-branch: true
title: "FDO community container test - ${{ steps.date.outputs.date }}"
labels: DO_NOT_MERGE,fdo-container
body: |
FDO community container test
- Date: ${{ steps.date.outputs.date }}
- name: Add a comment to trigger test workflow
uses: peter-evans/create-or-update-comment@v2
with:
token: ${{ secrets.PAT }}
issue-number: ${{ steps.cpr.outputs.pull-request-number }}
body: /test-fdo-container-community
- name: Create a project card to track compose test result
uses: peter-evans/create-or-update-project-card@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
project-name: Packages
column-name: fdo-container
issue-number: ${{ steps.cpr.outputs.pull-request-number }}
fdo-container-official:
if: github.repository == 'virt-s1/rhel-edge' && github.event.schedule == '5 8 * * 4'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Make change for PR creating
run: |
echo "fdo-container" > fdo-container.run
- name: Get current date
id: date
run: echo "date=$(date +'%Y-%m-%d')" >> $GITHUB_OUTPUT
- name: Create Pull Request
id: cpr
uses: peter-evans/create-pull-request@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: "FDO official container test - ${{ steps.date.outputs.date }}"
committer: cloudkitebot <[email protected]>
author: ${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>
branch: cpr
branch-suffix: random
delete-branch: true
title: "FDO official container test - ${{ steps.date.outputs.date }}"
labels: DO_NOT_MERGE,fdo-container
body: |
FDO official container test
- Date: ${{ steps.date.outputs.date }}
- name: Add a comment to trigger test workflow
uses: peter-evans/create-or-update-comment@v2
with:
token: ${{ secrets.PAT }}
issue-number: ${{ steps.cpr.outputs.pull-request-number }}
body: /test-fdo-container-official
- name: Create a project card to track compose test result
uses: peter-evans/create-or-update-project-card@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
project-name: Packages
column-name: fdo-container
issue-number: ${{ steps.cpr.outputs.pull-request-number }}