skaffold: Skaffold crashes when building Docker image using Minikube Docker daemon with buildkit

When building (using skaffold dev) the following image with Buildkit enabled, Skaffold crashes:

FROM alpine
ENTRYPOINT /bin/sh

Expected behavior

The image is built successfully.

Actual behavior

Skaffold crashes with the following error:

FATA[0004] exiting dev mode because first run failed: build failed: building [foo]: Error parsing reference: "" is not a valid repository/tag: invalid reference format

Information

  • Skaffold version: v0.24.0
  • Operating system: macOS 10.14.3
  • Contents of skaffold.yaml:
apiVersion: skaffold/v1beta6
kind: Config

build:
  local:
    useBuildkit: true
  artifacts:
    - image: foo
      context: .

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Reactions: 4
  • Comments: 34 (13 by maintainers)

Commits related to this issue

Most upvoted comments

That seems to be it:

$ minikube start
$ skaffold build
<crash>
$ minikube stop
$ skaffold build
<success!>

Should be all good now

@demisx You don’t need to use the docker CLI for passing env vars: https://github.com/haf/skaffold-dockerignore/blob/master/skaffold.yaml#L6-L10 works for me using docker on desktop.

I accidentally reproduced this with @haf’s repro on a separate issue: https://github.com/haf/skaffold-dockerignore - change the skaffold yaml to useDockerCLI: true creates this issue on minikube context, works in non minikube/non-local.

This thread seemed a little to quite so I opened this issue: #2187 and referenced it in the skaffold slack channel: https://kubernetes.slack.com/archives/CABQMSZA6/p1559010140012200. The issue was due to my minikube VM using an old ISO so minikube delete followed by minikube start which downloaded a new ISO solved it for me. @kdkeyser you should try it and see if you get the same results and close the issue. My current settings: OS: ubuntu/amd64 minikube version: v1.1.0 skaffold version: v0.30.0