Files
actions/docker-push/action.yaml
Hugo Nijhuis 17b45c7753 Update URLs from code.flowmade.one to git.flowmade.one
Migrate all action files to use the new Gitea server URL.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-31 00:30:07 +01:00

42 lines
1.1 KiB
YAML

name: Docker Push
description: Push Docker image to Forgejo Packages registry
inputs:
image:
description: Full image name (registry/org/name)
required: true
tags:
description: Comma-separated list of tags to push
default: 'latest'
registry:
description: Registry URL
default: 'git.flowmade.one'
username:
description: Registry username
default: ${{ github.repository_owner }}
password:
description: Registry password/token
required: true
runs:
using: composite
steps:
- shell: bash
run: |
IMAGE="${{ inputs.image }}"
TAGS="${{ inputs.tags }}"
REGISTRY="${{ inputs.registry }}"
USERNAME="${{ inputs.username }}"
PASSWORD="${{ inputs.password }}"
# Login to registry
echo "$PASSWORD" | docker login "$REGISTRY" -u "$USERNAME" --password-stdin
# Push each tag
IFS=',' read -ra TAG_ARRAY <<< "$TAGS"
for tag in "${TAG_ARRAY[@]}"; do
tag=$(echo "$tag" | xargs) # trim whitespace
echo "Pushing $IMAGE:$tag"
docker push "$IMAGE:$tag"
done