Skip to content

Commit 4623a42

Browse files
Merge pull request #1910 from metal3-io-bot/cherry-pick-1861-to-release-0.6
🌱 Move container build to gh runner
2 parents 15025fd + 94b5f55 commit 4623a42

File tree

1 file changed

+24
-45
lines changed

1 file changed

+24
-45
lines changed
+24-45
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
name: build-images-action
22

3+
permissions:
4+
contents: read
5+
36
on:
47
push:
58
branches:
@@ -8,49 +11,25 @@ on:
811
tags:
912
- 'v*'
1013

11-
permissions: {}
12-
1314
jobs:
14-
build:
15-
name: Build container images
16-
runs-on: ubuntu-latest
17-
18-
permissions:
19-
contents: read
20-
21-
if: github.repository == 'metal3-io/baremetal-operator'
22-
steps:
23-
- name: build bmo image
24-
uses: toptal/jenkins-job-trigger-action@137fff703dd260b52b53d3ba1960396415abc568 # 1.0.2
25-
with:
26-
jenkins_url: "https://jenkins.nordix.org/"
27-
jenkins_user: "[email protected]"
28-
jenkins_token: ${{ secrets.JENKINS_TOKEN }}
29-
job_name: "metal3_baremetal-operator_container_image_building"
30-
job_params: |
31-
{
32-
"BUILD_CONTAINER_IMAGE_GIT_REFERENCE": "${{ github.ref }}"
33-
}
34-
job_timeout: "1000"
35-
- name: build keepalived image
36-
uses: toptal/jenkins-job-trigger-action@137fff703dd260b52b53d3ba1960396415abc568 # 1.0.2
37-
with:
38-
jenkins_url: "https://jenkins.nordix.org/"
39-
jenkins_user: "[email protected]"
40-
jenkins_token: ${{ secrets.JENKINS_TOKEN }}
41-
job_name: "metal3_keepalived_container_image_building"
42-
job_params: |
43-
{
44-
"BUILD_CONTAINER_IMAGE_GIT_REFERENCE": "${{ github.ref }}"
45-
}
46-
job_timeout: "1000"
47-
- name: Slack Notification on Failure
48-
if: ${{ failure() }}
49-
uses: rtCamp/action-slack-notify@4e5fb42d249be6a45a298f3c9543b111b02f7907 # 2.3.0
50-
env:
51-
SLACK_TITLE: 'GitHub Action Failed in ${{ github.repository }}'
52-
SLACK_COLOR: '#FF0000'
53-
SLACK_MESSAGE: 'The GitHub Action workflow failed for baremetal operator image build.'
54-
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
55-
SLACK_CHANNEL: metal3-github-actions-notify
56-
SLACK_USERNAME: metal3-github-actions-notify
15+
build_bmo:
16+
name: Build BMO container image
17+
uses: metal3-io/project-infra/.github/workflows/container-image-build.yml@main
18+
with:
19+
image-name: "baremetal-operator"
20+
pushImage: true
21+
secrets:
22+
QUAY_USERNAME: ${{ secrets.QUAY_USERNAME }}
23+
QUAY_PASSWORD: ${{ secrets.QUAY_PASSWORD }}
24+
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
25+
build_keepalived:
26+
name: Build keepalived container image
27+
uses: metal3-io/project-infra/.github/workflows/container-image-build.yml@main
28+
with:
29+
image-name: "keepalived"
30+
dockerfile-directory: resources/keepalived-docker
31+
pushImage: true
32+
secrets:
33+
QUAY_USERNAME: ${{ secrets.QUAY_USERNAME }}
34+
QUAY_PASSWORD: ${{ secrets.QUAY_PASSWORD }}
35+
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}

0 commit comments

Comments
 (0)