Skip to content

Commit 7c6edd0

Browse files
Add workflow to push image
This is so far some copy&paste work from OpenProject. Might need further cleanup of duplication.
1 parent f0f27a3 commit 7c6edd0

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Release image
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- image-release # TODO: testing only
8+
9+
permissions:
10+
contents: read # to fetch code (actions/checkout)
11+
12+
env:
13+
REGISTRY_IMAGE: openproject/openproject-id
14+
KEYCLOAK_VERSION: 26.3.3
15+
16+
jobs:
17+
build:
18+
if: github.repository == 'opf/openproject-id'
19+
runs-on: ubuntu-latest
20+
steps:
21+
- name: Checkout
22+
uses: actions/checkout@v5
23+
- name: Set up QEMU
24+
uses: docker/setup-qemu-action@v3
25+
- name: Set up Docker Buildx
26+
id: buildx
27+
uses: docker/setup-buildx-action@v3
28+
- name: Login to Docker Hub
29+
uses: docker/login-action@v3
30+
with:
31+
username: ${{ secrets.DOCKER_USERNAME }}
32+
password: ${{ secrets.DOCKER_PASSWORD }}
33+
- name: Build & push image
34+
id: build
35+
uses: docker/build-push-action@v6
36+
with:
37+
context: image
38+
file: image/Containerfile
39+
platforms: linux/amd64,linux/arm64
40+
build-args: |
41+
BUILDKIT_PROGRESS=plain
42+
push: true
43+
tags: "${{ env.REGISTRY_IMAGE }}:${{ env.KEYCLOAK_VERSION }}"

0 commit comments

Comments
 (0)