namesny-com/.gitea/workflows/release.yaml

29 lines
767 B
YAML

name: Build website container
on:
push:
branches:
- main
jobs:
build:
name: Build image
runs-on: ubuntu-latest
container: ghcr.io/catthehacker/ubuntu:act-latest
env:
IMAGE_NAME: namesny-com
REGISTRY: git.namesny.com
REPO_OWNER: mathis
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
registry: git.namesny.com
username: ${{ gitea.actor }}
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Build and push
run: |
docker build -t ${REGISTRY}/${REPO_OWNER}/${IMAGE_NAME}:${{ gitea.sha }} -t ${REGISTRY}/${REPO_OWNER}/${IMAGE_NAME}:latest .
docker push