.gitea/workflows/buildDocker.yaml hinzugefügt
Some checks failed
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 3s
Build and Push Docker Image / build (push) Failing after 13s

This commit is contained in:
2025-10-07 10:14:37 +00:00
parent 5046af551c
commit dccffc757e

View File

@@ -0,0 +1,31 @@
name: Build and Push Docker Image
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout source
uses: actions/checkout@v4
- name: Setup Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Gitea Registry
uses: docker/login-action@v3
with:
registry: gitea.example.com
username: ${{ gitea.actor }}
password: ${{ secrets.REGISTRY_TOKEN }} # Der Token für das eigene Repo, ggf. als PAT erzeugen
- name: Build and Push Docker Image
uses: docker/build-push-action@v5
with:
context: .
file: ./Dockerfile
push: true
tags: gitea.example.com/${{ gitea.owner }}/${{ gitea.repo }}:${{ gitea.sha }},gitea.example.com/${{ gitea.owner }}/${{ gitea.repo }}:latest