503 — Nginx-proxy — multiple virtual_host

Nginx-proxy is a powerful and easy way to have SSL/HTTPS support on your docker container, and it also can run multiple websites when using docker.

However, when I try to run the website from localhost I got “503 services temporarily unavailable” It’s because virtual hosts only have one host which is “yourdomain.com”, we haven't added the localhost yet.

The way to solve this is by adding other virtual_host domains on your environment settings. In this case, I added the localhost on VIRTUAL_HOST variable

After that, you can stop and run your container with docker-compose.



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Rahmat Ramadhan Irianto

I’m a Python & Js Enthusiast. @BlockchainSpace BI Solution Architect. This is about my dev journal #Github https://github.com/rririanto