Skip to content

Commit 0ad77f4

Browse files
committed
chore(tests): added pr-check workflow
Signed-off-by: Rostislav Lán <[email protected]>
1 parent f9df5b8 commit 0ad77f4

File tree

1 file changed

+57
-0
lines changed

1 file changed

+57
-0
lines changed

.github/workflows/pr-check.yaml

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
#
2+
# Copyright (C) 2023 Red Hat, Inc.
3+
#
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
#
16+
# SPDX-License-Identifier: Apache-2.0
17+
18+
name: pr-check
19+
20+
on:
21+
workflow_run:
22+
workflows:
23+
- build-extension
24+
types:
25+
- completed
26+
27+
jobs:
28+
push-extension:
29+
name: Push OCI image to ghcr
30+
runs-on: ubuntu-24.04
31+
if: |
32+
github.event.workflow_run.conclusion == 'success'
33+
steps:
34+
- name: Download extension oci flatten images
35+
uses: actions/download-artifact@v4
36+
with:
37+
name: podman-desktop-image-checker-openshift-ext
38+
github-token: ${{ secrets.GITHUB_TOKEN }}
39+
run-id: ${{ github.event.workflow_run.id }}
40+
41+
- name: Read image name
42+
id: read-image
43+
run: |
44+
echo "IMAGE=$(cat podman-desktop-image-checker-openshift-ext.image)" >> "$GITHUB_ENV"
45+
46+
- name: Log in to ghcr.io
47+
uses: redhat-actions/[email protected]
48+
with:
49+
registry: ghcr.io
50+
username: ${{ github.actor }}
51+
password: ${{ secrets.GITHUB_TOKEN }}
52+
53+
- name: Push image for release
54+
shell: bash
55+
run: |
56+
podman load -i podman-desktop-image-checker-openshift-ext.tar
57+
podman push "$IMAGE"

0 commit comments

Comments
 (0)