Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Debugging docker compose deploy

I have some trouble with my docker compose (Docker version 1.13.1, build 092cba3) as the deploy fails with a non-descriptive error message

docker stack deploy -c myapp/docker-compose-dev.yml myapp
Creating service myservice
Error response from daemon: rpc error: code = 4 desc = context deadline exceeded

The compose file should start containers from five different images, which all can be successfully runned one by one with "docker run". Yet the compose doesn't even create any container. This is surpricing as the same compose has worked well just a couple of months ago and hasn't changed. I even tried to re-install my whole virtual machine that acts as the docker host, but even that didn't help. There should be enough resources on the docker host.

Is there any way to dig out more information on what exactly fails in the compose deploy? I didn't find any verbose mode or any logs. And since no containers are created in the process, there will be no logs for them either.

I'm pretty confused on how to analyse the issue further!?

like image 424
Fluster Avatar asked Jun 06 '26 14:06

Fluster


1 Answers

When you are not able to figure out such issues you should take help of journalctl system wide logs. You can run below

journalctl -f -n10

This will show you last 10 lines of logs and keep it in tail mode. Then you can run your original command with the issue and see what happens in log

like image 159
Tarun Lalwani Avatar answered Jun 10 '26 03:06

Tarun Lalwani



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!