Files
mnemosyne/.gitea/workflows/build-and-publish.yaml
Workflow config file is invalid. Please check your config file: yaml: line 28: did not find expected key

34 lines
1.1 KiB
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}}
- uses: actions-hub/kubectl@master
env:
KUBE_CONFIG: ${{ secrets.KUBE_CONFIG }}
with:
args: patch statefulset -p '{"spec":{"template":{"spec":{"containers":[{"name":"mnemosyne","image":"git.gractwo.pl/gractwo/mnemosyne::${{env.short_sha}}"}]}}}}'