action-env/.forgejo/workflows/build.yml
Vitaliy Potyarkin 976af216c6 Add images for Python
Signed-off-by: Vitaliy Potyarkin <v.potyarkin@yadro.com>
2024-10-24 17:23:11 +03:00

43 lines
1.1 KiB
YAML

on:
push:
pull_request:
workflow_dispatch:
jobs:
build:
name: build-${{matrix.tag}}
runs-on: docker
container: node:22-bullseye
strategy:
matrix:
tag:
- openjdk-11-maven-3.8.6
- python-3.11
- python-3.13
steps:
- name: Clone git repo
uses: actions/checkout@v3
- name: List modified files
uses: tj-actions/changed-files@v45
with:
files: |
${{matrix.tag}}/**
id: changed
- name: Install Buildah
run: apt update; apt install -y buildah
if: steps.changed.outputs.any_changed == 'true'
- name: Build OCI image
run: make ${{matrix.tag}}
if: steps.changed.outputs.any_changed == 'true'
- name: Push image to OCI registry
run: make ${{matrix.tag}} PUSH=y
if: >-
steps.changed.outputs.any_changed == 'true'
&& github.ref == 'refs/heads/master'
&& github.event_name == 'push'
env:
REGISTRY_PASSWORD: ${secrets.REGISTRY_PASSWORD}