42 lines
1.1 KiB
YAML
42 lines
1.1 KiB
YAML
name: release-tag
|
|
|
|
on: push
|
|
|
|
jobs:
|
|
release-image:
|
|
runs-on: ubuntu-latest
|
|
env:
|
|
DOCKER_ORG: eising
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Set up Docker BuildX
|
|
uses: docker/setup-buildx-action@v2
|
|
|
|
- name: Login to Registry
|
|
uses: docker/login-action@v2
|
|
with:
|
|
registry: git.eising.cloud # replace it with your local IP
|
|
username: ${{ gitea.actor }}
|
|
password: ${{ gitea.token }}
|
|
|
|
- name: Get Meta
|
|
id: meta
|
|
run: |
|
|
echo REPO_NAME=$(echo ${GITHUB_REPOSITORY} | awk -F"/" '{print $2}') >> $GITHUB_OUTPUT
|
|
echo ${{ gitea.actor }}
|
|
echo ${{ gitea.token }}
|
|
|
|
- name: Build and push
|
|
uses: docker/build-push-action@v4
|
|
with:
|
|
context: .
|
|
file: ./Dockerfile
|
|
platforms: |
|
|
linux/amd64
|
|
push: true
|
|
tags: |
|
|
git.eising.cloud/${{ env.DOCKER_ORG }}/${{ steps.meta.outputs.REPO_NAME }}:${{ gitea.ref == 'refs/heads/main' && 'latest' || gitea.sha }}
|