Skip to content

updated as casing and workflow on push #1

updated as casing and workflow on push

updated as casing and workflow on push #1

name: Provide needed docker images in ghcr.io
on:
workflow_dispatch:
push:
env:
REGISTRY_IMAGE: ghcr.io/novatecconsulting/opentelemetry-training
jobs:
retag_and_push:
name: Provide docker image ${{ matrix.image }} on ghcr.io
runs-on: [ubuntu-latest]
strategy:
matrix:
image:
- maeddes/todobackend-springboot:v2404
- maeddes/todoui-thymeleaf:v2404
- maeddes/todoui-flask:v2404
- maeddes/simple-generator:v2404
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Pull image from Docker Hub
run: |
docker pull docker.io/${{ matrix.image }}
- name: Retag the image for GitHub Container Registry
run: |
docker tag ${{ matrix.image }} ${{ env.REGISTRY_IMAGE }}-${{ matrix.image }}
- name: Push image to GitHub Container Registry
run: |
docker push ${{ env.REGISTRY_IMAGE }}-${{ matrix.image }}