diff options
Diffstat (limited to '')
-rw-r--r-- | .github/workflows/on-demand.yml | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/.github/workflows/on-demand.yml b/.github/workflows/on-demand.yml new file mode 100644 index 0000000..85e7c41 --- /dev/null +++ b/.github/workflows/on-demand.yml @@ -0,0 +1,49 @@ +name: 'Build docker on-demand' +on: + workflow_dispatch: + inputs: + tag: + description: 'docker container tag' + required: true + type: string + default: 'dev' + +jobs: + docker: + name: Docker Image Build + runs-on: ubuntu-latest + strategy: + matrix: + platform: + - linux/amd64 + - linux/arm64 + - linux/arm/v7 + - linux/arm/v8 + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Docker meta for TAG + id: meta + uses: docker/metadata-action@v5 + with: + images: ghcr.io/${{ github.repository }} + tags: | + type=raw,value=${{ inputs.tag }} + + - name: Login to GitHub Container Registry + uses: docker/login-action@v3 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + + - name: Build and push + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile + push: true + platforms: linux/amd64 + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} |