images/.forgejo/workflows/ente.yaml
Peter Kurfer 4e37f44d18
All checks were successful
Image builds / build-ente-images (cast) (push) Successful in 18s
Image builds / build-ente-images (photos) (push) Successful in 16s
Renovate / renovate (push) Successful in 15s
Image builds / build_images (renovate) (push) Successful in 55s
refactor: don't use photos- prefix for ente images anymore
2024-06-09 10:59:08 +02:00

48 lines
No EOL
1.3 KiB
YAML

---
name: Image builds
on:
schedule:
- cron: "21 2 * * *"
push:
branches:
- main
paths:
- ".forgejo/workflows/ente.yaml"
- "ente/**"
jobs:
build-ente-images:
runs-on: ubuntu-latest
strategy:
matrix:
app:
- photos
- cast
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
registry: code.icb4dc0.de
username: prskr
password: ${{ secrets.CONTAINER_REGISTRY_TOKEN }}
- name: Fetch latest ente photos tag
run: |
echo "ENTE_PHOTOS_VERSION=$(gh release list -R ente-io/ente --exclude-pre-releases --exclude-drafts --jq '.[] | select(.tagName | startswith("photos")) | .tagName | sub("photos-";"")' --json 'tagName' --limit 10 | head -n 1)" >> "$GITHUB_ENV"
env:
GH_TOKEN: ${{ secrets.RENOVATE_GITHUB_TOKEN }}
- name: Build and push ente web
uses: docker/build-push-action@v5
with:
context: "./ente/web"
push: true
tags: code.icb4dc0.de/infrastructure/images/ente/${{ matrix.app }}:${{ env.ENTE_PHOTOS_VERSION }}
build-args: |
ENTE_BRANCH=photos-${{ env.ENTE_PHOTOS_VERSION }}
ENTE_APP=${{ matrix.app }}