Skip to content

Commit a4dfa5a

Browse files
authored
feat(ci): add driver input to setup-buildx action (#941)
Signed-off-by: Jonas Toelke <jtoelke@nvidia.com>
1 parent ef2d993 commit a4dfa5a

1 file changed

Lines changed: 22 additions & 6 deletions

File tree

Lines changed: 22 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,22 @@
11
name: Setup Docker Buildx
22
description: >
3-
Create a multi-arch Docker Buildx builder using remote BuildKit nodes.
4-
The builder is automatically removed when the job finishes (cleanup is
5-
enabled by default in docker/setup-buildx-action).
3+
Create a Docker Buildx builder. Two modes:
4+
* driver=remote (default) — multi-arch builder against in-cluster BuildKit
5+
pods. Requires EKS connectivity. Behaviour unchanged from prior versions.
6+
* driver=local — single-node buildx on the local docker-container driver.
7+
Pair with cache-to/cache-from=type=gha on build steps for persistence.
8+
Works on nv-gha-runners; no EKS needed.
9+
Cleanup is automatic when the job finishes (docker/setup-buildx-action default).
610
711
inputs:
12+
driver:
13+
description: "buildx driver: 'remote' or 'local'"
14+
default: remote
815
amd64-endpoint:
9-
description: BuildKit endpoint for linux/amd64
16+
description: BuildKit endpoint for linux/amd64 (remote driver only)
1017
default: tcp://buildkit-amd64.buildkit:1234
1118
arm64-endpoint:
12-
description: BuildKit endpoint for linux/arm64
19+
description: BuildKit endpoint for linux/arm64 (remote driver only)
1320
default: tcp://buildkit-arm64.buildkit:1234
1421
name:
1522
description: Builder instance name
@@ -18,7 +25,8 @@ inputs:
1825
runs:
1926
using: composite
2027
steps:
21-
- name: Set up Docker Buildx
28+
- name: Set up Docker Buildx (remote)
29+
if: inputs.driver == 'remote'
2230
uses: docker/setup-buildx-action@v3
2331
with:
2432
name: ${{ inputs.name }}
@@ -28,3 +36,11 @@ runs:
2836
append: |
2937
- endpoint: ${{ inputs.arm64-endpoint }}
3038
platforms: linux/arm64
39+
40+
- name: Set up Docker Buildx (local)
41+
if: inputs.driver == 'local'
42+
uses: docker/setup-buildx-action@v3
43+
with:
44+
name: ${{ inputs.name }}
45+
driver: docker-container
46+
platforms: linux/amd64,linux/arm64

0 commit comments

Comments
 (0)