# Should return example.com's HTML, NOT jumble.imwald.eu's HTML
# If you see Jumble HTML, the proxy server is using the Host header instead of the URL path
```
**If the test returns Jumble HTML instead of the requested site's HTML:**
The proxy server is using the `Host` header (`jumble.imwald.eu`) to determine what to fetch. Update your Apache config to use `ProxyPreserveHost Off` for the `/proxy/` path:
```apache
# In your Apache config, change from:
ProxyPreserveHost On
ProxyPass /proxy/ http://127.0.0.1:8090/
# To:
ProxyPreserveHost Off
ProxyPass /proxy/ http://127.0.0.1:8090/
ProxyPassReverse /proxy/ http://127.0.0.1:8090/
# Then set it back to On for the main app:
ProxyPreserveHost On
ProxyPass / http://127.0.0.1:32768/
```
```
Then reload Apache and test again.
6. **Build with the proxy URL:**
6. **Build with the proxy URL:**
```bash
```bash
docker build \
docker build \
@ -220,6 +250,147 @@ docker build \
## Troubleshooting
## Troubleshooting
### If Proxy Returns Jumble HTML Instead of Requested Site
If you've set `ProxyPreserveHost Off` but still get Jumble HTML, test the proxy server directly:
**1. Test the proxy server directly (bypassing Apache):**
# Check Apache error log for proxy-related entries
sudo tail -f /var/log/apache2/error.log
# Then make a request and see what Apache is doing
```
**3c. Verify Apache config is being used:**
```bash
# Check that your Location block syntax is correct:
sudo apache2ctl -S | grep jumble.imwald.eu
# Make sure the site is enabled and config syntax is correct:
sudo apache2ctl configtest
```
**4. Possible Issues:**
**IMPORTANT: If you see `Server: nginx` in response headers, nginx is in front of Apache!**
If you see `Server: nginx/1.29.3` or `X-Powered-By: PleskLin` in the response headers, nginx reverse proxy is handling requests before Apache. You need to configure nginx directly (bypassing Plesk interface) to pass `/proxy/` to Apache, or route it directly to the proxy server.
**If nginx is in front of Apache (bypassing Plesk interface):**
Since nginx is handling requests before Apache, configure nginx directly by editing nginx config files.
**Option A: Configure nginx to pass `/proxy/` through to Apache:**