push to oci registry

This commit is contained in:
Fritz Grimpen 2024-11-09 01:16:59 +01:00
parent 7f215b4b3e
commit b7c741dadc
2 changed files with 26 additions and 10 deletions

26
.woodpecker/keycloak.yaml Normal file
View file

@ -0,0 +1,26 @@
when:
- event: push
branch: main
path:
- "keycloak/**"
- ".woodpecker/keycloak.yaml"
- event: tag
ref: "refs/tags/keycloak/*"
steps:
- name: build
image: quay.io/buildah/stable
commands:
- buildah build --manifest dev.ccchb.de/ccchb/oci-images/keycloak --platform=linux/amd64,linux/arm64 keycloak/
- buildah manifest --push all dev.ccchb.de/ccchb/oci-images/keycloak oci-archive:keycloak.tar
privileged: true
- name: push
image: quay.io/skopeo/stable
commands:
- skopeo login dev.ccchb.de -u ccchb -p ${FORGEJO_API_TOKEN}
- skopeo copy oci-archive:keycloak.tar dev.ccchb.de/ccchb/oci-images/keycloak:${CI_COMMIT_TAG##keycloak/}
- skopeo copy oci-archive:keycloak.tar dev.ccchb.de/ccchb/oci-images/keycloak:latest
secrets:
- FORGEJO_API_TOKEN
when:
event: tag

View file

@ -1,10 +0,0 @@
when:
- event: push
branch: main
steps:
- name: build
image: quay.io/buildah/stable
commands:
- buildah build keycloak/
privileged: true