Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support docker desktop on Linux #1759

Closed
cjsewell opened this issue May 10, 2023 · 3 comments · Fixed by #1878 or #1894
Closed

Support docker desktop on Linux #1759

cjsewell opened this issue May 10, 2023 · 3 comments · Fixed by #1878 or #1894
Assignees
Labels
size/sm Small level of effort status/ready Issue ready to be worked on. type/bug Issue that reports an unexpected behaviour.
Milestone

Comments

@cjsewell
Copy link

Description

By default it appears build pack only checks /var/run/docker.sock
Docker desktop for Linux creates the socket in $HOME/.docker/desktop/docker.sock

When running pack build on Linux with Docker desktop installed I get the error:
ERROR: failed to build: failed to fetch builder image 'gcr.io/buildpacks/builder:latest': Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

Proposed solution

It should check if $HOME/.docker/desktop/docker.sock exists and use that if it does

Describe alternatives you've considered

Creating a symlink works for me as a work around, but this may not work for everyone
sudo ln -s $HOME/.docker/desktop/docker.sock /var/run/docker.sock

@cjsewell cjsewell added status/triage Issue or PR that requires contributor attention. type/enhancement Issue that requests a new feature or improvement. labels May 10, 2023
@jjbustamante
Copy link
Member

Hi @cjsewell, thanks for creating this issue!

Just for curiosity, is your env DOCKER_HOST set?

I think, if you set

export DOCKER_HOST=unix://$HOME/.docker/desktop/docker.sock

it should also work without the symlink

@jjbustamante jjbustamante added type/bug Issue that reports an unexpected behaviour. status/ready Issue ready to be worked on. size/sm Small level of effort and removed status/triage Issue or PR that requires contributor attention. type/enhancement Issue that requests a new feature or improvement. labels Aug 15, 2023
@jjbustamante jjbustamante added this to the 0.30.1 milestone Aug 15, 2023
@jjbustamante
Copy link
Member

Hi @cjsewell

We just released a RC pack version, it will be great if you can give it a try and confirm the issue was solved

@pellizzetti
Copy link

It works for me, @jjbustamante

Thanks a lot! <3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size/sm Small level of effort status/ready Issue ready to be worked on. type/bug Issue that reports an unexpected behaviour.
Projects
None yet
3 participants