Change docker build to push to portus too

Signed-off-by: trivernis <trivernis@protonmail.com>
actions
trivernis 4 years ago
parent 82a8c968c4
commit 5961361e9b
Signed by: Trivernis
GPG Key ID: DFFFCC2C7A02DB45

@ -13,21 +13,29 @@ jobs:
- name: Copy Repo Files - name: Copy Repo Files
uses: actions/checkout@master uses: actions/checkout@master
- name: Publish Docker Image to GPR -
uses: machine-learning-apps/gpr-docker-publish@master name: Login to GitHub Container Registry
id: docker uses: docker/login-action@v1
with: with:
IMAGE_NAME: 'user-management-server' registry: ghcr.io
DOCKERFILE_PATH: 'Dockerfile' username: ${{ github.repository_owner }}
BUILD_CONTEXT: '.' password: ${{ secrets.CR_PAT }}
CACHE: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Show outputs of previous step - name: Login to Portus
run: | uses: docker/login-action@v1
echo "The name:tag of the Docker Image is: $VAR1" with:
echo "The docker image is hosted at $VAR2" registry: ghcr.io
env: username: ${{ github.PORTUS_USERNAME }}
VAR1: ${{ steps.docker.outputs.IMAGE_SHA_NAME }} password: ${{ secrets.PORTUS_PASSWORD }}
VAR2: ${{ steps.docker.outputs.IMAGE_URL }}
-
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
Loading…
Cancel
Save