Sock Shop deployed to Docker Swarm does not work
See original GitHub issueThe Problem
As someone reported on the Weave Users Slack group, the deployment with Docker Swarm is broken.
Here’s a screenshot of how it looks when trying to access the shop via the browser:
To reproduce the error one simply needs to follow our official guide to deploy the Sock Shop to Docker Swarm
Setting up Docker Swarm, bundling the shop with Docker Compose and deploying the service works good. It’s only during runtime that one gets this error.
Errors
When querying the catalogue service, this is the response:
$ curl http://localhost:30000/catalogue?size=5
{"message":"getaddrinfo ENOTFOUND catalogue catalogue:80","error":{"code":"ENOTFOUND","errno":"ENOTFOUND","syscall":"getaddrinfo","hostname":"catalogue","host":"catalogue","port":80}}
A similar error is returned for the cart service
$ curl http://localhost:30000/cart
{"message":"getaddrinfo ENOTFOUND carts carts:80","error":{"code":"ENOTFOUND","errno":"ENOTFOUND","syscall":"getaddrinfo","hostname":"carts","host":"carts","port":80}}
Specs
My system:
macOS Sierra 10.12.4
$ docker version
Client:
Version: 17.03.1-ce
API version: 1.27
Go version: go1.7.5
Git commit: c6d412e
Built: Tue Mar 28 00:40:02 2017
OS/Arch: darwin/amd64
Server:
Version: 17.03.1-ce
API version: 1.27 (minimum version 1.12)
Go version: go1.7.5
Git commit: c6d412e
Built: Fri Mar 24 00:00:50 2017
OS/Arch: linux/amd64
Experimental: true
Issue Analytics
- State:
- Created 6 years ago
- Comments:9 (4 by maintainers)
Top Results From Across the Web
Documentation - Microservices Demo: Sock Shop
The easiest and fastest way to get started with the Sock Shop application is by using Docker Compose. If you don't have Docker...
Read more >Docker swarm does not distribute the container in the cluster
I think the images are not accessible from a worker node, that is why they not receive containers, try to use this guide...
Read more >The Sock Shop: Microservices from dev to prod with Docker ...
Your browser can 't play this video. ... Luke Marsden - The Sock Shop : Microservices from dev to prod with Docker and...
Read more >Run Docker Engine in swarm mode
$ docker swarm init Swarm initialized: current node (dxn1zf6l61qsb1josjja83ngz) is now a manager. To add a worker to this swarm, run the following...
Read more >Running Applications on a Docker Swarm Mode Cluster
In this tutorial you will learn how to define, deploy, and scale a multi-service application with Docker Swarm Mode.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I´ve got the same behaviour with kubernetes… the carts and catalogue services can´t find their databases…
root@my-pc~# microk8s.enable dns
made it work