initial commit

This commit is contained in:
2025-11-01 21:01:59 -04:00
parent 3af247079f
commit 31bfc56f3c
2 changed files with 46 additions and 1 deletions

46
build.yaml Normal file
View File

@@ -0,0 +1,46 @@
name: "Bob the Builder"
description: "automatic preconfigured docker image builder for gitea"
inputs:
registry:
description: "container registry link"
default: ""
username:
description: "username for registry authentication"
required: false
token:
description: "token for registry authentication"
required: false
tag:
description: "image tag to push"
required: true
dockerfile:
description: "path to dockerfile"
required: false
default: "Dockerfile"
build-args:
description: "passed as build-args to docker build"
required: false
runs:
using: "composite"
steps:
- name: "login to docker"
uses: docker/login-action@v3
with:
registry: ${{ inputs.registry }}
username: ${{ inputs.username }}
password: ${{ inputs.token }}
- name: "build image"
uses: docker/build-push-action@v6
with:
push: true
tags: ${{ inputs.tag }}
file: ${{ inputs.dockerfile }}
build-args: ${{ inputs.build-args }}
no-cache: true
- name: "cleanup image"
shell: bash
run: |
docker rmi ${{ inputs.tag }}
docker system prune