Skip to content

Commit

Permalink
DockerHub artifact automation
Browse files Browse the repository at this point in the history
  • Loading branch information
slominskir committed Jan 3, 2023
1 parent f068f16 commit 9f1c0fe
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Publish to DockerHub

on:
release:
types: [published]
workflow_dispatch:

jobs:
push_to_registry:
name: Push Docker image to Docker Hub
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/checkout@v3
-
name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
images: |
jeffersonlab/${{ github.event.repository.name }}
tags: |
type=semver,pattern={{version}}
-
name: Login to DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Push to Docker Hub
uses: docker/build-push-action@v3
with:
push: true
build-args: |
CUSTOM_CRT_URL=http://pki.jlab.org/JLabCA.crt
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

0 comments on commit 9f1c0fe

Please sign in to comment.