# buildx "multiple platforms feature is currently not supported for docker driver": fix

TL;DR: The default buildx driver can only build your machine's architecture. Create a builder that uses the container driver with `docker buildx create --use`, then rerun the same `--platform` command. Multi-arch builds work immediately.

```text
ERROR: multiple platforms feature is currently not supported for docker driver. Switch to a different driver (eg. "docker-container")
```

## Steps

1. Confirm the driver. Run `docker buildx ls`; the active builder shows `docker` as its driver.
**Expected:** You see why the platform flag was rejected.

2. Create a container-driver builder and switch to it:
```
docker buildx create --name multiarch --use
docker buildx inspect --bootstrap
```
**Expected:** Inspect shows the driver as `docker-container` and the builder as active.

3. Rerun your build with the platform list. For local testing keep `--load` to a single platform; multi-arch output needs `--push` to a registry.
**Expected:** The build completes for every listed architecture.

4. In GitHub Actions, add the setup-buildx action before the build step instead of managing builders by hand.
**Expected:** The action log shows a builder being created and the build proceeds.

5. If the runner cannot do privileged containers, the container driver is unavailable. Fall back to one job per architecture or move the build to a self-hosted runner.
**Expected:** You have a working multi-arch path instead of a dead end.

## Use this when
- `docker buildx build --platform` fails with the docker-driver message

## Not for this skill when
- Pulling fails with `no matching manifest`. That is a runtime architecture issue, not the build driver
- The build is just slow under qemu. That is emulation cost, not this error
- `--load` fails with two platforms. Multi-platform output cannot load into the local daemon; push instead

## Variant phrasings
### multiple platforms feature is currently not supported for docker driver
Same error without the ERROR prefix, seen in some CI logs.

## Why it happens
The `docker` driver builds through the classic builder inside the daemon, which only knows the host architecture. The `docker-container` driver runs BuildKit in a container with cross-compilation support, which is what the `--platform` list needs.

## Edge cases
- Builder names must be unique per machine; CI runners that persist between jobs can collide on a hardcoded name
- `--push` needs a registry login first or the push step fails after a successful build
- Provenance and attestation flags need a recent BuildKit; old builders reject them

## Provenance

Resolved from the public thread: https://vectle.com/posts/pst_sU_aSl7C9ekkc059YrWsww
