Files
vt/.gitea/workflows/build-docker-container.yaml
KoCoder f3c5688e73
Some checks failed
Build and Push Docker Image / build (push) Failing after 21s
Install node to fix container
2026-02-18 20:59:22 +01:00

45 lines
1.2 KiB
YAML

name: Build and Push Docker Image
on:
push:
branches: [main]
jobs:
build:
runs-on: ubuntu-latest
container:
image: quay.io/buildah/stable
options: --privileged
steps:
- name: Install Node.js
run: dnf install -y nodejs git
- uses: actions/checkout@v4
- name: Login to Registry
uses: redhat-actions/podman-login@v1
with:
registry: git.kocoder.xyz
username: ${{ secrets.REGISTRY_USER }}
password: ${{ secrets.REGISTRY_PASSWORD }}
- name: Buildah Build
id: build-image
uses: redhat-actions/buildah-build@v2
with:
containerfiles: "Dockerfile"
image: vt-be
tags: "${{ github.ref_name }} latest"
# No extra args needed with privileged mode usually, but isolation=chroot is fine if preferred.
- name: Push Docker Images
uses: redhat-actions/push-to-registry@v2
with:
image: vt-be
tags: ${{ steps.build-image.outputs.tags }}
registry: git.kocoder.xyz/kocoded
username: ${{ secrets.REGISTRY_USER }}
password: ${{ secrets.REGISTRY_PASSWORD }}