mirror of
https://git.flexiblyrigid.au/actions/bake-action.git
synced 2025-12-06 07:48:05 +08:00
ci: allow arbitrary buildx/buildkit version on workflow dispatch event
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
This commit is contained in:
23
.github/workflows/ci.yml
vendored
23
.github/workflows/ci.yml
vendored
@@ -1,6 +1,16 @@
|
||||
name: ci
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
buildx-version:
|
||||
description: 'Buildx version or Git context'
|
||||
default: 'latest'
|
||||
required: false
|
||||
buildkit-image:
|
||||
description: 'BuildKit image'
|
||||
default: 'moby/buildkit:buildx-stable-1'
|
||||
required: false
|
||||
schedule:
|
||||
- cron: '0 10 * * *'
|
||||
push:
|
||||
@@ -11,6 +21,10 @@ on:
|
||||
- 'v*'
|
||||
pull_request:
|
||||
|
||||
env:
|
||||
BUILDX_VERSION: latest
|
||||
BUILDKIT_IMAGE: moby/buildkit:buildx-stable-1
|
||||
|
||||
jobs:
|
||||
bake:
|
||||
runs-on: ubuntu-latest
|
||||
@@ -37,7 +51,10 @@ jobs:
|
||||
id: buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
with:
|
||||
driver-opts: network=host
|
||||
version: ${{ inputs.buildx-version || env.BUILDX_VERSION }}
|
||||
driver-opts: |
|
||||
image=${{ inputs.buildkit-image || env.BUILDKIT_IMAGE }}
|
||||
network=host
|
||||
-
|
||||
name: Build and push
|
||||
uses: ./
|
||||
@@ -105,6 +122,10 @@ jobs:
|
||||
-
|
||||
name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
with:
|
||||
version: ${{ inputs.buildx-version || env.BUILDX_VERSION }}
|
||||
driver-opts: |
|
||||
image=${{ inputs.buildkit-image || env.BUILDKIT_IMAGE }}
|
||||
-
|
||||
name: Build
|
||||
uses: ./
|
||||
|
||||
Reference in New Issue
Block a user