Skip to content

Docker nightly

Docker nightly #946

Workflow file for this run

name: Docker nightly
on:
push:
branches:
- master
tags-ignore:
- '*'
workflow_dispatch:
# set docker tag for all steps
env:
DOCKERTAG: nightly
jobs:
docker_build:
runs-on: ${{ matrix.target.runs }}
permissions:
packages: write
contents: read
strategy:
fail-fast: false
matrix:
os:
- rocky
- debian
target:
- runs: ubuntu-24.04
platform: amd64
- runs: ubuntu-24.04-arm
platform: arm64
steps:
- name: Check out the repo
uses: actions/checkout@v4
- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Log in to GitHub Docker Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ secrets.REGISTRY_USER }}
password: ${{ secrets.PTA }}
- name: Build and Push
uses: docker/build-push-action@v6
with:
push: true
file: Dockerfile.omd-labs-${{ matrix.os }}
build-args: OMD_VERSION=${{ github.ref }}
tags: |
consol/omd-labs-${{ matrix.os }}:${{ env.DOCKERTAG }}-${{ matrix.target.platform }}
ghcr.io/consol/omd-labs-docker/omd-labs-${{ matrix.os }}:${{ env.DOCKERTAG }}-${{ matrix.target.platform }}
platforms: linux/${{ matrix.target.platform }}
manifest:
runs-on: ubuntu-24.04
needs: docker_build
permissions:
packages: write
contents: read
strategy:
fail-fast: false
matrix:
os:
- rocky
- debian
steps:
- uses: actions/checkout@v4
- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Log in to GitHub Docker Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ secrets.REGISTRY_USER }}
password: ${{ secrets.PTA }}
- name: push manifest to dockerhub
run: |
docker manifest create consol/omd-labs-${{ matrix.os }}:${{ env.DOCKERTAG }} \
consol/omd-labs-${{ matrix.os }}:${{ env.DOCKERTAG }}-amd64 \
consol/omd-labs-${{ matrix.os }}:${{ env.DOCKERTAG }}-arm64
docker manifest push consol/omd-labs-${{ matrix.os }}:${{ env.DOCKERTAG }}
- name: push manifest to github
run: |
docker manifest create ghcr.io/consol/omd-labs-docker/omd-labs-${{ matrix.os }}:${{ env.DOCKERTAG }} \
ghcr.io/consol/omd-labs-docker/omd-labs-${{ matrix.os }}:${{ env.DOCKERTAG }}-amd64 \
ghcr.io/consol/omd-labs-docker/omd-labs-${{ matrix.os }}:${{ env.DOCKERTAG }}-arm64
docker manifest push ghcr.io/consol/omd-labs-docker/omd-labs-${{ matrix.os }}:${{ env.DOCKERTAG }}