Skip to content

Commit

Permalink
Publish Docker image on Docker Hub
Browse files Browse the repository at this point in the history
  • Loading branch information
ggrossetie committed Sep 3, 2022
1 parent e439935 commit dab6a63
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,3 +90,28 @@ jobs:
asset_path: build/asciidoctor-web-pdf-linux.zip
asset_name: asciidoctor-web-pdf-linux-${{ env.RELEASE_VERSION }}.zip
asset_content_type: application/zip
publish_dockerhub:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3.0.2
- uses: actions/setup-node@v3
with:
node-version: 16
- name: Install dependencies
run: |
npm ci
- name: Setup Docker
# taken from https://github.com/docker/github-actions/blob/0f18e2abad9a4ac2963d2516246787375b5ec917/Dockerfile#L32
run: curl -fL https://download.docker.com/linux/static/stable/x86_64/docker-20.10.4.tgz | tar xzO docker/docker > docker && sudo mv -f docker /usr/bin/docker && sudo chmod +x /usr/bin/docker
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Docker Hub
run: |
echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
env:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
- name: Publish Docker images
run: RELEASE_VERSION=${GITHUB_REF#refs/*/v*} make publishDocker

0 comments on commit dab6a63

Please sign in to comment.