runner-images/.forgejo/workflows/build.yml

94 lines
2.8 KiB
YAML
Raw Normal View History

2025-01-29 21:15:46 +01:00
name: "Build Runner Images"
2025-01-29 20:52:20 +01:00
on:
schedule:
- cron: "0 0 * * *"
push:
branches:
- "master"
jobs:
base:
runs-on: "docker"
steps:
- name: Login to Registry
uses: "https://git.euph.dev/actions/docker-login@v3"
with:
registry: git.euph.dev
username: ${{ secrets.DEPLOY_USER }}
password: ${{ secrets.DEPLOY_SECRET }}
2025-01-29 21:15:46 +01:00
- name: Build and push base image
id: build_base
2025-01-29 20:52:20 +01:00
uses: "https://git.euph.dev/actions/docker-build-push@v5"
with:
context: "{{defaultContext}}:images/actions/act"
push: true
tags: |
git.euph.dev/actions/runner-basic:latest
git.euph.dev/actions/runner-basic:${{ github.run_number }}
2025-01-29 21:15:46 +01:00
extended-latest:
2025-01-29 20:52:20 +01:00
runs-on: "docker"
needs:
- base
strategy:
matrix:
2025-01-29 21:15:46 +01:00
language: ["go", "js"]
2025-01-29 20:52:20 +01:00
steps:
- name: Login to Registry
uses: "https://git.euph.dev/actions/docker-login@v3"
with:
registry: git.euph.dev
username: ${{ secrets.DEPLOY_USER }}
password: ${{ secrets.DEPLOY_SECRET }}
2025-01-29 21:15:46 +01:00
- name: Build and push ${{ matrix.language }} image
2025-01-29 20:52:20 +01:00
uses: "https://git.euph.dev/actions/docker-build-push@v5"
with:
2025-01-29 21:15:46 +01:00
context: "{{defaultContext}}:images/actions/${{ matrix.language }}"
2025-01-29 20:52:20 +01:00
push: true
tags: |
2025-01-29 21:15:46 +01:00
git.euph.dev/actions/runner-${{ matrix.language }}:latest
git.euph.dev/actions/runner-${{ matrix.language }}:${{ github.run_number }}
2025-01-29 20:52:20 +01:00
2025-01-29 21:15:46 +01:00
extended-versioned:
2025-01-29 20:52:20 +01:00
runs-on: "docker"
needs:
- base
strategy:
matrix:
2025-01-29 21:15:46 +01:00
include:
- language: php
2025-01-29 21:25:18 +01:00
version: 8.2
- language: php
version: 8.3
2025-01-29 21:15:46 +01:00
- language: lua
version: 5.3
- language: lua
version: 5.4
- language: java
version: 8
- language: java
version: 17
- language: java
version: 21
- language: redot
version: 4.3
2025-01-29 20:52:20 +01:00
steps:
- name: Login to Registry
uses: "https://git.euph.dev/actions/docker-login@v3"
with:
registry: git.euph.dev
username: ${{ secrets.DEPLOY_USER }}
password: ${{ secrets.DEPLOY_SECRET }}
2025-01-29 21:15:46 +01:00
- name: Build and push ${{ matrix.language }} {{ matrix.version }} image
2025-01-29 20:52:20 +01:00
uses: "https://git.euph.dev/actions/docker-build-push@v5"
with:
2025-01-29 21:15:46 +01:00
context: "{{defaultContext}}:images/actions/${{ matrix.language }}"
2025-01-29 20:52:20 +01:00
push: true
build-args: PACKAGE_VERSION=${{ matrix.version }}
tags: |
2025-01-29 21:15:46 +01:00
git.euph.dev/actions/runner-${{ matrix.language }}-${{ matrix.version }}:latest
git.euph.dev/actions/runner-${{ matrix.language }}-${{ matrix.version }}:${{ github.run_number }}