Skip to content

Commit

Permalink
Update Docker GitHub actions to current
Browse files Browse the repository at this point in the history
  • Loading branch information
Nuru committed Jul 23, 2023
1 parent 596479d commit 27fa001
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: "Checkout source code at current commit"
uses: actions/checkout@v2
uses: actions/checkout@v3
- name: Prepare tags for Docker image
if: (github.event_name == 'release' && github.event.action == 'published') || github.event.pull_request.head.repo.full_name == github.repository || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
id: prepare
Expand Down Expand Up @@ -59,22 +59,22 @@ jobs:
echo "slim-tags=${SLIM_TAGS}" >> "$GITHUB_OUTPUT"
printf "SLIM_TAGS are %s\n" "${SLIM_TAGS}"
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v2
- name: Login to DockerHub
if: (github.event_name == 'release' && github.event.action == 'published') || github.event.pull_request.head.repo.full_name == github.repository || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
uses: docker/login-action@v1
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
- name: "Build and push full docker image to DockerHub"
id: docker_full_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v3
with:
push: ${{ (github.event_name == 'release' && github.event.action == 'published') || github.event.pull_request.head.repo.full_name == github.repository || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}
tags: ${{ steps.prepare.outputs.tags }}
- name: "Build and push slim docker image to DockerHub"
id: docker_slim_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v3
with:
file: ./Dockerfile.slim
push: ${{ (github.event_name == 'release' && github.event.action == 'published') || github.event.pull_request.head.repo.full_name == github.repository || github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}
Expand Down

0 comments on commit 27fa001

Please sign in to comment.