Skip to content

feat: get latest if not specific #10

feat: get latest if not specific

feat: get latest if not specific #10

Workflow file for this run

name: Build & Push Docker Image
on:
push:
branches:
- 'main'
workflow_dispatch:
inputs:
version:
description: 'Caddy specific version (default to get latest)'
required: true
jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v5
with:
build-args: |
"CADDY_VERSION=${{ github.event.inputs.version != '' && format('{0}{1}', github.event.inputs.version, '-') || '' }}"
push: true
tags: korewalidesu/caddy:latest