Skip to content

oci: fix skill entrypoint #15

oci: fix skill entrypoint

oci: fix skill entrypoint #15

Workflow file for this run

---
name: Build and Push Docker Image
on:
push:
branches:
- dev
jobs:
build-and-push:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Setup variables
id: vars
run: |
build_date=$(date +%Y%m%d%H%M)
echo "build-date=${build_date}" >> "$GITHUB_OUTPUT"
echo "tag-name=${build_date}" >> "$GITHUB_OUTPUT"
- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
images: ghcr.io/${{ github.repository }}
tags: |
type=ref,event=pr
type=ref,event=branch
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
- name: Debug
run: |
echo "${{ steps.vars.outputs.build-date }}"
- name: Build and push
uses: docker/build-push-action@v4
with:
push: true
context: .
file: docker/Dockerfile
cache-from: type=gha
cache-to: type=gha,mode=max
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
platforms: linux/amd64,linux/arm64
build-args: |
BUILD_DATE=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.created'] }}
VERSION=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.version'] }}