Skip to content

Commit 307fe37

Browse files
authored
fix: use Containerfile and Containerfile.builder to build release and latest versions (#1041)
Signed-off-by: Denis Golovin <dgolovin@redhat.com>
1 parent bb98e87 commit 307fe37

File tree

3 files changed

+12
-33
lines changed

3 files changed

+12
-33
lines changed

.github/workflows/build.yaml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,7 @@ jobs:
1919
name: Build
2020
runs-on: ${{ inputs.runs-on }}
2121
timeout-minutes: 60
22-
env:
23-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
22+
2423
steps:
2524
- uses: actions/checkout@v6
2625

@@ -50,16 +49,19 @@ jobs:
5049
if: ${{ inputs.registry == 'ghcr' }}
5150
run: podman login --username ${{ github.repository_owner }} --password ${{ secrets.GITHUB_TOKEN }} ghcr.io
5251

52+
- name: Build builder-image
53+
run: podman build -t ghcr.io/redhat-developer/podman-desktop-redhat-account-ext-builder:next . -f ./build/Containerfile.builder
54+
5355
- name: Build and Push Image (quay.io)
5456
if: ${{ inputs.registry == 'quay' }}
5557
id: build-image-quay
5658
run: |
57-
podman build -t quay.io/redhat-developer/podman-desktop-redhat-account-ext:${{ inputs.ext-version }} .
59+
podman build -t quay.io/redhat-developer/podman-desktop-redhat-account-ext:${{ inputs.ext-version }} . -f ./build/Containerfile
5860
podman push quay.io/redhat-developer/podman-desktop-redhat-account-ext:${{ inputs.ext-version }}
5961
6062
- name: Build and Push Image (ghcr.io)
6163
if: ${{ inputs.registry == 'ghcr' }}
6264
id: build-image-ghcr
6365
run: |
64-
podman build -t ghcr.io/redhat-developer/podman-desktop-redhat-account-ext:latest .
65-
podman push ghcr.io/redhat-developer/podman-desktop-redhat-account-ext:latest
66+
podman build -t ghcr.io/redhat-developer/podman-desktop-redhat-account-ext:next . -f ./build/Containerfile
67+
podman push ghcr.io/redhat-developer/podman-desktop-redhat-account-ext:next

.github/workflows/pr-check.yaml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,8 @@ jobs:
142142
working-directory: ./podman-desktop-redhat-account-ext
143143
run: |
144144
pnpm build
145-
podman build -t local_sso_image ./
145+
podman build -t ghcr.io/redhat-developer/podman-desktop-redhat-account-ext-builder:next . -f ./build/Containerfile.builder
146+
podman build -t local_sso_image ./ -f ./build/Containerfile
146147
CONTAINER_ID=$(podman create localhost/local_sso_image --entrypoint "")
147148
podman export $CONTAINER_ID > /tmp/local_sso_image.tar
148149
mkdir -p tests/output/sso-tests-pd/plugins
@@ -236,12 +237,13 @@ jobs:
236237
- name: Execute pnpm in SSO Extension
237238
working-directory: ./podman-desktop-redhat-account-ext
238239
run: pnpm install --no-frozen-lockfile
239-
240+
240241
- name: Build SSO extension from container file
241242
working-directory: ./podman-desktop-redhat-account-ext
242243
run: |
243244
pnpm build
244-
podman build -t local_sso_image ./
245+
podman build -t ghcr.io/redhat-developer/podman-desktop-redhat-account-ext-builder:next . -f ./build/Containerfile.builder
246+
podman build -t local_sso_image ./ -f ./build/Containerfile
245247
CONTAINER_ID=$(podman create localhost/local_sso_image --entrypoint "")
246248
podman export $CONTAINER_ID > /tmp/local_sso_image.tar
247249
mkdir -p tests/output/sso-tests-pd/plugins

Containerfile

Lines changed: 0 additions & 25 deletions
This file was deleted.

0 commit comments

Comments
 (0)