# Use multiple Docker containers without exposing ports

**URL:** https://meta.discourse.org/t/use-multiple-docker-containers-without-exposing-ports/22283
**Category:** Sysadmins
**Tags:** docker, how-to, advanced-setup
**Created:** [November 18, 2014, 9:43pm UTC](https://meta.discourse.org/t/use-multiple-docker-containers-without-exposing-ports/22283 "2014-11-18T21:43:13Z")
**Posts on this page:** 1
**Showing post:** 7

<div class="post-metadata">

### Author: ![almereyda](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/almereyda/32/367792_2.png) [@almereyda](https://meta.discourse.org/u/almereyda)
#### Post date: [October 22, 2015, 1:05am UTC](https://meta.discourse.org/t/use-multiple-docker-containers-without-exposing-ports/22283/7 "2015-10-22T01:05:19Z")

</div>

Just in case anybody stumbles here for running several Discourse instances behind [https://github.com/jwilder/nginx-proxy:](https://github.com/jwilder/nginx-proxy:)

Set discourse to listen on a local link port and tell the proxy to use the container’s internal port 80 like

```plaintext
expose:
  - "127.0.0.1:2836:80"

env:
  VIRTUAL_PORT: '80'

```

---

_[View the full topic](https://meta.discourse.org/t/use-multiple-docker-containers-without-exposing-ports/22283)._
