Skip to content

Commit

Permalink
Combined old and new GH actions for docker
Browse files Browse the repository at this point in the history
  • Loading branch information
kieraneglin committed Mar 28, 2024
1 parent 2affcd8 commit 2b34860
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 64 deletions.
54 changes: 0 additions & 54 deletions .github/workflows/build_and_push_docker.yml

This file was deleted.

14 changes: 4 additions & 10 deletions .github/workflows/docker_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ jobs:
images: |
docker.io/keglin/pinchflat
ghcr.io/${{ github.repository }}
# All non-release actions will be tagged as `dev` (ie: push, workflow_dispatch)
tags: |
type=semver,pattern={{version}},prefix=v
type=semver,pattern={{major}}.{{minor}},prefix=v
Expand Down Expand Up @@ -65,21 +66,14 @@ jobs:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Echo outputs
run: |
echo "${{ github.event_name }}"
echo "${{ steps.meta.outputs.tags }}"
echo "${{ steps.meta.outputs.labels }}"
echo "${{ github.event.inputs.platforms }}"
echo "${{ github.event.inputs.platforms || env.release_arch }}"
echo "${{ github.event_name == 'release' && env.release_arch || (github.event.inputs.platforms || env.dev_arch) }}"
- name: Build and Push
uses: docker/build-push-action@v5
with:
context: .
file: ./selfhosted.Dockerfile
# If the event is a release, use the release_arch, otherwise use the
# platforms input if present, falling back to dev_arch
platforms: ${{ github.event_name == 'release' && env.release_arch || (github.event.inputs.platforms || env.dev_arch) }}
push: false # TODO: Set to true once everything is proven to work
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

0 comments on commit 2b34860

Please sign in to comment.