Docker Community Forums

Share and learn in the Docker community.

2 containers, same domain name, but alternate ports, possible?

Hey peeps!

I’m running a multi-container web-app, and for testing I’d like to have 2 containers:

  • 1 running a web-server with ports 80 and 443 open
  • 1 running a web-server with ports 8088 and 8443 open

Both are running the same code, but one is built (webpack) specifically for IE. This version does not look or function the same as the other one.

What I’d like is to be able to use the same URL, but different ports.
So one site would be and the other would be

Is this possible? Would I have to use 2 different domain names?

If you’re wondering why this is needed, it’s because our build pipeline spits out an app_bundler.js file at the end of the build process, and it’s different for IE then it is for other browsers. When testing, developers have to stop the web-server container, rebuild with a flag set for IE, restart the web-server container, then do IE testing. This works, but is inconvenient.