29 lines
863 B
YAML
29 lines
863 B
YAML
name: mnemo-build-and-publish
|
|
run-name: Mnemosyne Build&Publish by ${{gitea.actor}} on ${{gitea.ref_name}}
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
|
|
jobs:
|
|
gractwo-mnemo-build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: checkout repo
|
|
uses: actions/checkout@v4
|
|
- name: set short sha
|
|
run: echo "short_sha=$(echo ${{gitea.sha}} | cut -c1-12)" >> $GITEA_ENV
|
|
- name: build image
|
|
run: |
|
|
docker buildx build --platform linux/amd64 \
|
|
-t git.gractwo.pl/gractwo/mnemosyne:${{env.short_sha}} \
|
|
.
|
|
- name: log into package registry
|
|
uses: docker/login-action@v3
|
|
with:
|
|
registry: git.gractwo.pl
|
|
username: ${{gitea.actor}}
|
|
password: ${{secrets.TOKEN2}}
|
|
- name: publish
|
|
run: docker push git.gractwo.pl/gractwo/mnemosyne:${{env.short_sha}}
|