ERROR: for manager Container “e873879f164d” is unhealthy

I followed the Quickstart steps and downloaded the docker compose file linked below:
https://raw.githubusercontent.com/openremote/openremote/master/docker-compose.yml
Copy docker-compose.yml to the path D:\OpenRemote ,
an error occurred when executing “docker-compose -p openremote up”, the error message is “ERROR: for manager Container “e873879f164d” is unhealthy.

How can I fix this problem?

My environment
OS:Windows 10 64-bit Pro, version 1803 (Build 17134.1246)
Docker Desktop version:3.1.0(51484)

LOG

> D:\OpenRemote>docker-compose -p openremote up
> Pulling postgresql (openremote/postgresql:9.6.21.0)...
> 9.6.21.0: Pulling from openremote/postgresql
> a4feded82f54: Pull complete
> d19e7242f4bd: Pull complete
> 6cb253df2129: Pull complete
> ea721dc98310: Pull complete
> 68f7cd84a8b8: Pull complete
> 8393cbb84c4e: Pull complete
> 287e8e4b251d: Pull complete
> 2122c0a410c8: Pull complete
> ce2fcfb3d94a: Pull complete
> 5124a549865d: Pull complete
> 57ea93a66d30: Pull complete
> c9462e801511: Pull complete
> b1177777b89f: Pull complete
> bb48c796065e: Pull complete
> fad10c093cb5: Pull complete
> Digest: sha256:0652499c8a168ef8b234358d772ffe3d12fb47b3e625a4dc41bb8e49bd24c0f7
> Status: Downloaded newer image for openremote/postgresql:9.6.21.0
> Pulling keycloak (openremote/keycloak:12.0.1.0)...
> 12.0.1.0: Pulling from openremote/keycloak
> a591faa84ab0: Pull complete
> 76b9354adec6: Pull complete
> f4d8905294de: Pull complete
> 08c48b2eb240: Pull complete
> 13cf898e6765: Pull complete
> cb27d969b474: Pull complete
> b23cde3f16cb: Pull complete
> a3e0cac6490a: Pull complete
> ee0e82b59ae6: Pull complete
> aa96575cfa5c: Pull complete
> 50344b8d27b2: Pull complete
> Digest: sha256:622d7faac54b78cddc57e1262bc748646ffcc6097514b995d90c7f486b3e6719
> Status: Downloaded newer image for openremote/keycloak:12.0.1.0
> Pulling manager (openremote/manager:latest)...
> latest: Pulling from openremote/manager
> 23a3602cd30c: Pull complete
> d0fd962836b0: Pull complete
> 2149a13bfdd2: Pull complete
> 4c8deb4f4f97: Pull complete
> b22e60edadf3: Pull complete
> 378e99b262d5: Pull complete
> 46915995bc88: Pull complete
> 4e0983c20bd8: Pull complete
> 2a1b9f349411: Pull complete
> Digest: sha256:f504db5562d423de4882dd2032a788f64f297090c15449a0c9780415b3e92e72
> Status: Downloaded newer image for openremote/manager:latest
> Pulling proxy (openremote/proxy:2.1.2.1)...
> 2.1.2.1: Pulling from openremote/proxy
> a4feded82f54: Already exists
> b76a3b5f4b30: Pull complete
> 4a3bfe51246a: Pull complete
> 681e40435d03: Pull complete
> c6c108b71db4: Pull complete
> 1331eed7d04e: Pull complete
> befeae5515de: Pull complete
> 15a6a8f279c4: Pull complete
> fcd8d4984e6f: Pull complete
> 1f2714202d5f: Pull complete
> 8bcf4ceb7e7c: Pull complete
> 6ef7f98d240e: Pull complete
> 0360029a7926: Pull complete
> f54ffab727ae: Pull complete
> 96e7387c4018: Pull complete
> Digest: sha256:b93a142e806bb2816fc7bc269f6943b510403c6eecd5894399f9f78a171d5fb4
> Status: Downloaded newer image for openremote/proxy:2.1.2.1
> Creating openremote_postgresql_1 ... done
> Creating openremote_keycloak_1   ... done
> 
> ERROR: for manager  Container "e873879f164d" is unhealthy.
> ERROR: Encountered errors while bringing up the project.
> 
> D:\OpenRemote>

Hi,

have you tried an alternative deployment method through openremote-cli tool? It uses different deployment method through docker swarm deploy, which is more robust than vanilla docker-compose. I’ve just run it on Windows machine and it works, however the startup was considerably longer than the last time I remember trying it on Windows.

How to install CLI:

  • if you have python (recommended)
pip3 install -U openremote-cli

For pure deployment you don’t need any other tools mentioned in prerequisites beside python3.

  • if you only have docker
docker pull openremote/openremote-cli

How to deploy using CLI:

  • if you have python
openremote-cli deploy -v

-v flag gives you some verbosity of commands run during deployment.

  • if you have only docker (I use this mainly in headless CI/CD pipelines):
docker run -ti --rm -v /var/run/docker.sock:/var/run/docker.sock openremote/openremote-cli deploy -v

Note that on Windows /var/run/docker.sock doesn’t exist and you would probably need an alternative method to make the pipe with host docker daemon. Unfortunately, I’m not Windows expert and cannot help you there, hoewever we have @Don and @rich, which both are more experienced in the stuff than me.

Also, deploying it through docker has problems with health testing of the openremote stack from inside the container. Therefore you can exit docker run... with ^C when you see Stack deployed, waiting for startup to complete message. Then you can check running stack with docker service ls and wait till all services show 1/1 like here:

> docker service ls
ID             NAME                    MODE         REPLICAS   IMAGE                          PORTS
9s3u19bom804   openremote_keycloak     replicated   1/1        openremote/keycloak:latest     
f54ci4e7aoa1   openremote_manager      replicated   1/1        openremote/manager:latest      
cckp14jbqv1f   openremote_postgresql   replicated   1/1        openremote/postgresql:latest   
pbf9omw0wkv5   openremote_proxy        replicated   1/1        openremote/proxy:latest        *:80->80/tcp, *:443->443/tcp, *:8883->8883/tcp