Arindy f39df79306
All checks were successful
CI / deploy (push) Successful in 1m33s
add branch build
2025-09-21 13:28:03 +02:00

40 lines
1.0 KiB
YAML

name: CI
on:
push:
branches:
- '*'
tags:
- '*'
pull_request:
jobs:
deploy:
env:
REPO: ${{ github.event.repository.name }}
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- id: version
name: Version
run: |
if [ "${{ github.ref_type }}" = 'tag' ]; then
newVersion="${{ github.ref_name }}"
else
newVersion=$(git describe --tags --abbrev=0 2>/dev/null || echo 0.0.0).dev
fi
echo "version=$newVersion" >> "$GITHUB_OUTPUT"
- name: Build
run: |
docker build -t git.arindy.de/arindy/latex-runner:${{ steps.version.outputs.version }} .
- name: Push
if: ${{ github.ref_type == 'tag' }}
run: |
echo ${{secrets.PACKAGES_TOKEN}} | docker login --username ${{ secrets.PACKAGES_USER }} --password-stdin git.arindy.de
docker push git.arindy.de/arindy/latex-runner:${{ steps.version.outputs.version }}