LIVE - Tag and Deploy #26
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: LIVE - Tag and Deploy | |
on: | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out the repo | |
uses: actions/checkout@v4 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Log in to Github Container Registry | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKER_HUB_USERNAME }} | |
password: ${{ secrets.DOCKER_HUB_PASSWORD }} | |
- name: Tag latest | |
run: | | |
docker pull ${{ secrets.DOCKER_HUB_USERNAME }}/sbws-scanner:latest-stage | |
docker tag ${{ secrets.DOCKER_HUB_USERNAME }}/sbws-scanner:latest-stage ${{ secrets.DOCKER_HUB_USERNAME }}/sbws-scanner:latest | |
docker push ${{ secrets.DOCKER_HUB_USERNAME }}/sbws-scanner:latest | |
docker pull ${{ secrets.DOCKER_HUB_USERNAME }}/sbws-destination:latest-stage | |
docker tag ${{ secrets.DOCKER_HUB_USERNAME }}/sbws-destination:latest-stage ${{ secrets.DOCKER_HUB_USERNAME }}/sbws-destination:latest | |
docker push ${{ secrets.DOCKER_HUB_USERNAME }}/sbws-destination:latest | |
- name: Deploy | |
uses: ./.github/actions/deploy | |
with: | |
environment: live | |
nomad-cacert: operations/admin-ui-ca.crt | |
nomad-token: ${{ secrets.NOMAD_TOKEN_SBWS_DEPLOY }} | |
nomad-addr: ${{ secrets.NOMAD_DEPLOY_ADDR }} |