diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index 2c1b372..a36dee2 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -13,21 +13,29 @@ jobs: - name: Copy Repo Files uses: actions/checkout@master - - name: Publish Docker Image to GPR - uses: machine-learning-apps/gpr-docker-publish@master - id: docker + - + name: Login to GitHub Container Registry + uses: docker/login-action@v1 with: - IMAGE_NAME: 'user-management-server' - DOCKERFILE_PATH: 'Dockerfile' - BUILD_CONTEXT: '.' - CACHE: true - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + registry: ghcr.io + username: ${{ github.repository_owner }} + password: ${{ secrets.CR_PAT }} - - name: Show outputs of previous step - run: | - echo "The name:tag of the Docker Image is: $VAR1" - echo "The docker image is hosted at $VAR2" - env: - VAR1: ${{ steps.docker.outputs.IMAGE_SHA_NAME }} - VAR2: ${{ steps.docker.outputs.IMAGE_URL }} \ No newline at end of file + - name: Login to Portus + uses: docker/login-action@v1 + with: + registry: ghcr.io + username: ${{ github.PORTUS_USERNAME }} + password: ${{ secrets.PORTUS_PASSWORD }} + + - + name: Build and push + uses: docker/build-push-action@v2 + with: + context: . + file: ./Dockerfile + platforms: linux/amd64 + push: true + tags: | + flotte-docker-registry.spdns.org/flotte-user-managment:latest + ghcr.io/flotte-meets-hwr-db/flotte-user-management/user-management-server \ No newline at end of file