# Routing to the web server

**URL:** <https://openziti.discourse.group/t/routing-to-the-web-server/963>\
**Category:** Uncategorized\
**Created:** [January 10, 2023, 3:59am UTC](https://openziti.discourse.group/t/routing-to-the-web-server/963 "2023-01-10T03:59:16Z")\
**Posts on this page:** 1\
**Showing post:** 16

<div class="post-metadata">

**Author:** ![TheLumberjack](https://yyz2.discourse-cdn.com/free1/user_avatar/openziti.discourse.group/thelumberjack/32/113_2.png) [@TheLumberjack](https://openziti.discourse.group/u/TheLumberjack)\
**Post date:** [January 18, 2023, 8:23pm UTC](https://openziti.discourse.group/t/routing-to-the-web-server/963/16 "2023-01-18T20:23:28Z")

</div>

Hi @himeose. I don't have a video yet but I wanted to follow up. I think this is what you're doing, and I did it in my own lab:

 ![image](https://global.discourse-cdn.com/free1/uploads/netfoundry/original/1X/d3d1a7e7e49b87ae0730adb4d3a0043c37153dc5.png)

To accomplish this, here's exactly what I did:

### Prerequisites:

1. Provisioned two VMs in a single AWS VPC
2. Ran the quickstart on one VM and verified it works as expected
3. Ran the docker container `crccheck/hello-world` and exposed it on port 80 (this is the web server that shows the docker whale) `docker run --rm --name web-test -p 80:8000 crccheck/hello-world`

### Enable "private.web" access

1. obtain a docker env file and the simplified compose file in whatever folder you like:

2. update the `.env` file to look similar to this. Hopefully obvious, replace advertised.address with your externally accessible address. like '[ec2-3-134-108-218.us-east-2.compute.amazonaws.com](http://ec2-3-134-108-218.us-east-2.compute.amazonaws.com)' for example etc

3. start docker - **IMPORTANT** : notice I used `-p openziti` to start docker. That produces a predictable name used in step 5 below. Make sure you either understand what the `-p` flag is doing here, or just run it exactly as shown! 🙂

4. optional: If needed, get the latest ziti binaries and have them added to the path for you if needed

5. setup a file to source to make it easy to login to the environment. This pulls information from the container and makes a "docker.env" file that you can source and use to `ziti login`

6. Configure the OpenZiti overlay for the private web service and identity. (notice I used MY ip=172.31.50.50 of my private web server)

7. authorize the router identity to bind the service. Notice i used the name of MY edge router here (`ec2-3-134-108-218.us-east-2.compute.amazonaws.com`) - you have to replace with yours:

I'll make a video demo'ing all this in a bit

---

_[View the full topic](https://openziti.discourse.group/t/routing-to-the-web-server/963)._
