migrate to forgejo
All checks were successful
Build images / build-images-amd64 (push) Successful in 11m36s
Build images / build-images-arm64 (push) Successful in 14m13s
Build images / update-images-manifests (push) Successful in 26s

This commit is contained in:
Maciej Lebiest 2024-02-08 21:21:53 +01:00
parent b77b9fac05
commit a551468585

View file

@ -8,7 +8,7 @@ on:
jobs: jobs:
build-images-arm64: build-images-arm64:
runs-on: [ linux_arm64 ] runs-on: [ arm64 ]
steps: steps:
- name: install actions deps - name: install actions deps
run: | run: |
@ -16,19 +16,19 @@ jobs:
- name: Check out repository code - name: Check out repository code
uses: actions/checkout@v3 uses: actions/checkout@v3
- name: login to registry - name: login to registry
run: podman login -u "${{ secrets.PACKAGES_USERNAME }}" -p "${{ secrets.PACKAGES_PASSWD }}" gitea.maciej.cloud run: podman login -u "${{ secrets.PACKAGES_USERNAME }}" -p "${{ secrets.PACKAGES_PASSWD }}" forgejo.maciej.cloud
- name: Build selected images - name: Build selected images
run: | run: |
IMAGES=(system-toolbox cloud-toolbox tor zabbix-agent snowflake gitea-runner); IMAGES=(system-toolbox cloud-toolbox tor zabbix-agent snowflake);
for image in "${IMAGES[@]}"; for image in "${IMAGES[@]}";
do do
echo "building image $image"; echo "building image $image";
podman build ./$image --tag gitea.maciej.cloud/packages/$image:arm64; podman build ./$image --tag forgejo.maciej.cloud/pkg/$image:arm64;
echo "pushing image $image"; echo "pushing image $image";
podman push gitea.maciej.cloud/packages/$image:arm64; podman push forgejo.maciej.cloud/pkg/$image:arm64;
done done
build-images-amd64: build-images-amd64:
runs-on: [ linux_amd64 ] runs-on: [ amd64 ]
steps: steps:
- name: install actions deps - name: install actions deps
run: | run: |
@ -36,31 +36,31 @@ jobs:
- name: Check out repository code - name: Check out repository code
uses: actions/checkout@v3 uses: actions/checkout@v3
- name: login to registry - name: login to registry
run: podman login -u "${{ secrets.PACKAGES_USERNAME }}" -p "${{ secrets.PACKAGES_PASSWD }}" gitea.maciej.cloud run: podman login -u "${{ secrets.PACKAGES_USERNAME }}" -p "${{ secrets.PACKAGES_PASSWD }}" forgejo.maciej.cloud
- name: Build selected images - name: Build selected images
run: | run: |
IMAGES=(system-toolbox cloud-toolbox tor zabbix-agent snowflake gitea-runner); IMAGES=(system-toolbox cloud-toolbox tor zabbix-agent snowflake);
for image in "${IMAGES[@]}"; for image in "${IMAGES[@]}";
do do
echo "building image $image"; echo "building image $image";
podman build ./$image --tag gitea.maciej.cloud/packages/$image:amd64; podman build ./$image --tag forgejo.maciej.cloud/pkg/$image:amd64;
echo "pushing image $image"; echo "pushing image $image";
podman push gitea.maciej.cloud/packages/$image:amd64; podman push forgejo.maciej.cloud/pkg/$image:amd64;
done done
update-images-manifests: update-images-manifests:
runs-on: [ linux_amd64 ] runs-on: [ amd64 ]
needs: needs:
- build-images-amd64 - build-images-amd64
- build-images-arm64 - build-images-arm64
steps: steps:
- name: login to registry - name: login to registry
run: podman login -u "${{ secrets.PACKAGES_USERNAME }}" -p "${{ secrets.PACKAGES_PASSWD }}" gitea.maciej.cloud run: podman login -u "${{ secrets.PACKAGES_USERNAME }}" -p "${{ secrets.PACKAGES_PASSWD }}" forgejo.maciej.cloud
- name: Create manifests and push - name: Create manifests and push
run: | run: |
IMAGES=(system-toolbox cloud-toolbox tor zabbix-agent snowflake gitea-runner); IMAGES=(system-toolbox cloud-toolbox tor zabbix-agent snowflake);
for image in "${IMAGES[@]}"; for image in "${IMAGES[@]}";
do do
echo "Updating manifest for $image"; echo "Updating manifest for $image";
podman manifest create gitea.maciej.cloud/packages/$image:latest gitea.maciej.cloud/packages/$image:amd64 gitea.maciej.cloud/packages/$image:arm64; podman manifest create forgejo.maciej.cloud/pkg/$image:latest forgejo.maciej.cloud/pkg/$image:amd64 forgejo.maciej.cloud/pkg/$image:arm64;
podman manifest push gitea.maciej.cloud/packages/$image:latest gitea.maciej.cloud/packages/$image:latest; podman manifest push forgejo.maciej.cloud/pkg/$image:latest forgejo.maciej.cloud/pkg/$image:latest;
done done