getporter/porter

porter build fails & switch context message is wrong

Opened this issue · 2 comments

Following the "getting started" guide to create a bundle and porter build fails.

The suggested fix is also wrong. It should be:

docker context use default

Logs

% porter build
Copying porter runtime ===> 
Copying mixins ===> 
Copying mixin exec ===> 
Building invocation image
use `docker --context=default buildx` to switch to context "default"
unable to build CNAB invocation image: use `docker --context=default buildx` to switch to context "default"
unable to build CNAB invocation image: use `docker --context=default buildx` to switch to context "default"

Porter Version

% porter version
porter v1.0.14 (0e739d88)

Fix

Running this works:

docker context use default
porter build

Error is originating from buildx lib: buildx/builder/builder.go
I agree that it might not make sense in a Porter context, and the suggested fix will not do anything.

This should be fixed in versions 1.0.16+ - could you try in the newer versions and let me know if you're still seeing it?