Skip to content

omnipkg v2.0.0 - The Python Hypervisor Release #58

omnipkg v2.0.0 - The Python Hypervisor Release

omnipkg v2.0.0 - The Python Hypervisor Release #58

Workflow file for this run

name: Build and Push to Docker Hub
on:
release:
types: [published]
workflow_dispatch:
inputs:
tag:
description: 'Docker tag to build (e.g., v1.6.2, latest)'
required: true
type: string
jobs:
build-and-push:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: 1minds3t
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Extract version from release
id: get_version
run: |
if [ "${{ github.event_name }}" = "release" ]; then
VERSION=${GITHUB_REF#refs/tags/}
echo "tag=${VERSION}" >> $GITHUB_OUTPUT
else
echo "tag=${{ inputs.tag }}" >> $GITHUB_OUTPUT
fi
- name: Build and push
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/amd64,linux/arm64,linux/arm/v7,linux/arm64/v8,linux/ppc64le,linux/s390x
push: true
tags: 1minds3t/omnipkg:${{ steps.get_version.outputs.tag }}
cache-from: type=gha
cache-to: type=gha,mode=max