Skip to content

Service never starts  #65

@VAggrippino

Description

@VAggrippino

I'm attempting to start a dockerflow/docker-flow-proxy service on a swarm with one manager and two workers, but the command never completes and never reports any errors. So, it never returns to the command prompt. Instead, it repeatedly switches between, "new", "assigned", "ready", and "starting".

20180911_125052_vaggrippino envy-lm19-64_ devgo-demo

Note that although the screenshot shows the image vfarcic/docker-flow-proxy I'm having exactly the same problem with dockerflow/docker-flow-proxy.

This is from the book "The DevOps 2.1 Toolkit - Docker Swarm" by @vfarcic
Here's the command I used to start the service

docker service create --name proxy -p 80:80 -p 443:443 -p 8080:8080 --network proxy -e MODE=swarm dockerflow/docker-flow-proxy

If I Ctrl-C it shows

Operation continuing in background.
Use docker service ps p473obsbo9tgjom1fd61or5ap to check progress.

... and returns to the command prompt

If I use docker service ps --no-trunc p473obsbo9tgjom1fd61or5ap I get:

ID                          NAME                IMAGE                                                                                                         NODE                DESIRED STATE       CURRENT STATE               ERROR                                                          PORTS
dbzvr67uzg5fq9w64uh324dtn   proxy.1             dockerflow/docker-flow-proxy:latest@sha256:e4e4a684d703bec18385caed3b3bd0482cefdff73739ae21bd324f5422e17d93   node-1              Running             Starting 11 seconds ago
vzlttk2xdd4ynmr4lir4t38d5    \_ proxy.1         dockerflow/docker-flow-proxy:latest@sha256:e4e4a684d703bec18385caed3b3bd0482cefdff73739ae21bd324f5422e17d93   node-1              Shutdown            Failed 16 seconds ago       "task: non-zero exit (137): dockerexec: unhealthy container"
q5dlvb7xz04cwxv9hpr9w5f7l    \_ proxy.1         dockerflow/docker-flow-proxy:latest@sha256:e4e4a684d703bec18385caed3b3bd0482cefdff73739ae21bd324f5422e17d93   node-1              Shutdown            Failed 49 seconds ago       "task: non-zero exit (137): dockerexec: unhealthy container"
z86h0pcj21joryb3sj59mx2pq    \_ proxy.1         dockerflow/docker-flow-proxy:latest@sha256:e4e4a684d703bec18385caed3b3bd0482cefdff73739ae21bd324f5422e17d93   node-1              Shutdown            Failed about a minute ago   "task: non-zero exit (137): dockerexec: unhealthy container"
uj2axgfm1xxpdxrkp308m28ys    \_ proxy.1         dockerflow/docker-flow-proxy:latest@sha256:e4e4a684d703bec18385caed3b3bd0482cefdff73739ae21bd324f5422e17d93   node-1              Shutdown            Failed about a minute ago   "task: non-zero exit (137): dockerexec: unhealthy container"

So, no mention of node-2 or node-3 and I don't know what the error message means.

If I run docker service logs -f proxy the following repeats every minute or so:

proxy.1.s585dio0clan@node-1    | 2018/09/12 03:13:02 Starting HAProxy
proxy.1.s585dio0clan@node-1    | 2018/09/12 03:13:02 Getting certs from http://202.71.99.195:8080/v1/docker-flow-proxy/certs

I can only guess that it fails to get whatever certs it's looking for. There doesn't seem to be anything at that address, but an IP address lookup shows that it leads to my ISP. Where's that coming from?

Steps to reproduce the issue:

  1. Create three nodes with docker-machine
  2. Initialize the swarm with the first node as the manager
  3. Join the swarm with the other two nodes.
  4. Create a network using the overlay driver.
  5. Create a service, using dockerflow/docker-flow-proxy; publishing mirrored ports 80, 443, and 8080; and setting the MODE=swarm environment variable.

Describe the results you received:

overall progress: 0 out of 1 tasks
1/1 starting

(never returns to command prompt)

Describe the results you expected:
Something like:

overall progress: 1 out of 1 tasks
verify: Service converged

Additional information you deem important (e.g. issue happens only occasionally):

Additional environment details (AWS, VirtualBox, physical, etc.):
I'm running this on a physical computer running Linux Mint 19 (based on Ubuntu 18.04). The driver / provider for docker-machine is virtualbox.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions