docker-images/.gitea/workflows/workflow-docker.yaml

32 lines
736 B
YAML
Raw Permalink Normal View History

2024-08-02 19:40:28 +00:00
name: Docker build test
2024-08-02 15:54:58 +00:00
on:
workflow_call:
inputs:
2024-08-02 19:43:22 +00:00
password:
required: true
type: string
2024-08-02 15:54:58 +00:00
image:
required: true
type: string
dockerfile:
required: true
type: string
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: docker/login-action@v3
with:
registry: ${{ vars.CONTAINER_REGISTRY }}
username: ${{ vars.CONTAINER_REGISTRY_USERNAME }}
2024-08-02 19:53:34 +00:00
password: ${{ inputs.password }}
2024-08-02 15:54:58 +00:00
- uses: docker/build-push-action@v6
with:
context: .
file: ${{ inputs.dockerfile }}
push: true
tags: ${{ vars.CONTAINER_REGISTRY }}/${{ inputs.image }}