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

problem starting containers with docker-machine #717

Closed
codefromthecrypt opened this issue May 30, 2018 · 13 comments
Closed

problem starting containers with docker-machine #717

codefromthecrypt opened this issue May 30, 2018 · 13 comments

Comments

@codefromthecrypt
Copy link

getting the following with latest (1.7.3)

18/05/30 16:21:28 INFO DockerClientFactory: Docker host IP address is 192.168.99.100
18/05/30 16:21:28 INFO DockerClientFactory: Connected to docker: 
  Server Version: 18.05.0-ce
  API Version: 1.37
  Operating System: Boot2Docker 18.05.0-ce (TCL 8.2.1); HEAD : b5d6989 - Thu May 10 16:35:28 UTC 2018
  Total Memory: 2002 MB
18/05/30 16:21:40 INFO DockerClientFactory: Ryuk started - will monitor and terminate Testcontainers containers on JVM exit
        ℹ︎ Checking the system...
        ✔ Docker version should be at least 1.6.0
        ✔ Docker environment should have more than 2GB free disk space
        ✔ File should be mountable
---snip---
Caused by: com.github.dockerjava.api.exception.BadRequestException: {"message":"OCI runtime create failed: container_linux.go:348: starting container process caused \"chdir to cwd (\\\"/root\\\") set in config.json failed: permission denied\": unknown"}

	at com.github.dockerjava.netty.handler.HttpResponseHandler.channelRead0(HttpResponseHandler.java:99)
	at com.github.dockerjava.netty.handler.HttpResponseHandler.channelRead0(HttpResponseHandler.java:33)
	at org.testcontainers.shaded.io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105)

I am able to use docker normally ex with zipkin's docker-compose file

@rnorth
Copy link
Member

rnorth commented May 30, 2018

Ouch, thank you for reporting and sorry you hit this. I'll try and reproduce; from the error it looks like Testcontainers and/or docker-java is trying to do something that's no longer possible in docker-machine.

As a workaround, do you have Docker for Mac (/Windows?) available to try?

@bsideup
Copy link
Member

bsideup commented May 30, 2018

Hey @adriancole, I have a feeling that it relates to #680 :(
Apparently they released 18.05.0-ce with a regression inside :(

May I kindly recommend you to try Docker for Mac? It's proven to be MUCH more stable (and faster)

@bsideup bsideup self-assigned this May 30, 2018
@bsideup
Copy link
Member

bsideup commented May 30, 2018

@adriancole FYI 18.05 is "edge" release, the latest stable is 18.03.1:
https://docs.docker.com/release-notes/docker-ce/

@codefromthecrypt
Copy link
Author

codefromthecrypt commented May 30, 2018 via email

@bsideup
Copy link
Member

bsideup commented May 30, 2018

@adriancole I think there are some reports of that regression on SO as well:
https://stackoverflow.com/questions/50325096/grafana-5-1-0-docker-image-permission-issue

could you please run the following commands to verify it?

$ mkdir data
$ docker run -ti -p 3000:3000 --entrypoint bash --volume "$PWD/data:/var/lib/grafana" grafana/grafana:5.1.0

$ ls /var/lib/grafana

@rnorth
Copy link
Member

rnorth commented May 30, 2018

Based on the error message alone it looks like moby/moby#32708.

That was first reported back on 17.03, more than a year ago, so I'm skeptical that it's going to be the same actual cause in our case. Still, maybe this ticket will give us some clues.

@codefromthecrypt
Copy link
Author

codefromthecrypt commented May 30, 2018 via email

@bsideup
Copy link
Member

bsideup commented May 30, 2018

@adriancole thanks! We're checking what's wrong with the edge Docker anyways, but, in general, highly recommend running Docker for Mac :)

@codefromthecrypt
Copy link
Author

using docker-machine...

○ → docker run -ti -p 3000:3000 --entrypoint bash --volume "$PWD/data:/var/lib/grafana" grafana/grafana:5.1.0
Unable to find image 'grafana/grafana:5.1.0' locally
5.1.0: Pulling from grafana/grafana
2a72cbf407d6: Pull complete 
89f824064239: Pull complete 
b90280be2e0d: Pull complete 
Digest: sha256:a6b37f9afdd9782f1e6264acaf3b09519aad454f34ca6b0e863dd9873e11fa67
Status: Downloaded newer image for grafana/grafana:5.1.0
grafana@7aaf88a18a3f:/$ ls /var/lib/grafana
grafana@7aaf88a18a3f:/$

@bsideup
Copy link
Member

bsideup commented May 31, 2018

@adriancole did you create data folder on host before running the command?

@codefromthecrypt
Copy link
Author

yep

@stale
Copy link

stale bot commented Oct 28, 2018

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. If you believe this is a mistake, please reply to this comment to keep it open. If there isn't one already, a PR to fix or at least reproduce the problem in a test case will always help us get back on track to tackle this.

@stale stale bot added the stale label Oct 28, 2018
@stale
Copy link

stale bot commented Nov 11, 2018

This issue has been automatically closed due to inactivity. We apologise if this is still an active problem for you, and would ask you to re-open the issue if this is the case.

@stale stale bot closed this as completed Nov 11, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants