Docker Community Forums

Share and learn in the Docker community.

"NGINX Bad Gateway" error message after installing DTR as trial on my notebook

Hi There,

I tried to do the trial installation of DTR as part of the Docker datacenter installation on my Mac Notebook. Step Two: Install UCP and DTR (UCP installation was no problem). DTR installation is only the following command:
"docker run docker/trusted-registry install | \bash"
Pointing to https:// there just an NGINX page saying: “502 Bad Gateway”.

Any ideas where to look and what to fix?
Thx

For me when trying to restart the containers, for nginx I got

Cannot restart container <container name>: driver failed programming external connectivity on endpoint dtr-nginx-<replicaID>ptables failed: iptables --wait -t nat -A DOCKER -p tcp -d 0/0 --dport 444 -j DNAT --to-destination <nginxdockerIP> ! -i : iptables: No chain/target/match by that name. (exit status 1)

Although I still unfortunately don’t know what could have happened after my restart of the DTR node to cause these issues with the nginx and dtr-jobrunner dtr containers to where they wouldn’t start but at that point I was forced to remove and re-install DTR.

For your case though this is what I used to install DTR on my 3 node swarm configuration which would be documented here: http://docs.docker.com.s3-website-us-east-1.amazonaws.com/docker-trusted-registry/install/

docker run -it --rm
docker/dtr install
–replica-http-port 88
–replica-https-port 444
–ucp-node
–ucp-url https://
–ucp-username
–ucp-password <UCPAdminPassword
–ucp-ca “$(cat <your.pem>)”
–dtr-external-url https://:444

The node names are from the UCP > Resources > Nodes that you had named them. Let me know if this helps.

The iptables issue looks like something happened with libnetwork. If you have the docker engine logs, they’d be invaluable.