Skip to content

Commit

Permalink
tag currently used image with "previous" before pushing the built one…
Browse files Browse the repository at this point in the history
… to enable easy rollback
  • Loading branch information
aaalexlit committed Mar 3, 2024
1 parent 6bf048f commit eff118b
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,15 @@ jobs:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN }}

- name: Pull currently used Docker image
run: docker pull aaalexlit/faq-slack-bot:main

- name: Tag currently used Docker image as "previous" to enable easy rollback
run: docker tag aaalexlit/faq-slack-bot:main aaalexlit/faq-slack-bot:previous

- name: Push tagged image to Docker Hub
run: docker push aaalexlit/faq-slack-bot:previous

- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v5
Expand Down

0 comments on commit eff118b

Please sign in to comment.