Update with correct versioning #12
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: Build Docker Image | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: azure/docker-login@v1 | |
with: | |
login-server: wmcontainers.azurecr.io | |
username: ${{ secrets.CONTAINER_USERNAME }} | |
password: ${{ secrets.CONTAINER_PASSWORD }} | |
- uses: actions/checkout@v3 | |
- name: Build the Docker image | |
working-directory: ./src | |
run: docker build . --file Dockerfile --tag restdesign:latest | |
- name: Tag the image | |
working-directory: ./src | |
run: docker tag restdesign:latest wmcontainers.azurecr.io/restdesign:latest | |
- name: Push the Image | |
working-directory: ./src | |
run: docker push wmcontainers.azurecr.io/restdesign:latest | |