This commit is contained in:
2023-09-22 11:26:33 +02:00
committed by T.v.Dein
parent 68e1d1eefe
commit 87103c7925

View File

@@ -1,18 +1,29 @@
name: publish name: build-push-image
on: [push]
on:
push:
branches:
- 'development'
jobs: jobs:
publish-ephemeruo-image: build-and-push-image:
runs-on: ubuntu-latest runs-on: ubuntu-latest
permissions:
packages: write
steps: steps:
- uses: actions/checkout@v2 - name: Checkout repository
- name: Login to GitHub Container Registry uses: actions/checkout@v3
uses: docker/login-action@v1
with: - name: Log in to the Container registry
registry: ghcr.io uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
username: ${{ github.actor }} with:
password: ${{ secrets.GITHUB_TOKEN }} registry: https://ghcr.io
- name: build-push-image username: ${{ github.actor }}
run: | password: ${{ secrets.GITHUB_TOKEN }}
docker build . --tag ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest
docker run ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest - name: Build and push Docker image
docker push ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: image/
push: true
tags: ghcr.io/tlinden/ephemerup:latest