Skip to content

Commit ed85997

Browse files
authored
chore: add reverse proxy test guide (#64)
Signed-off-by: Anupam Kumar <[email protected]>
1 parent 190adfa commit ed85997

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

README.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -445,6 +445,41 @@ These checks run **inside the HaRP container** (e.g., `docker exec -it appapi-ha
445445
# Expected: OK
446446
```
447447
448+
### Verify that the Reverse Proxy configuration is correct
449+
450+
Stop the HaRP container temporarily and start a dummy server with `nc` (netcat) to confirm that your reverse proxy is forwarding requests correctly with all the headers:
451+
452+
```bash
453+
# Stop HaRP container
454+
docker stop appapi-harp
455+
# Start a dummy server on the same port as HaRP's ExApps frontend
456+
nc -l -k -p 8780
457+
```
458+
459+
Now, send a request through your reverse proxy to the ExApps endpoint (e.g., `https://cloud.example.com/exapps/hello`):
460+
461+
```bash
462+
curl -v https://cloud.example.com/exapps/hello
463+
```
464+
465+
For nginx, you should see output similar to this in the terminal where `nc` is running:
466+
467+
```
468+
GET /exapps/hello HTTP/1.1
469+
Host: cloud.example.com
470+
Connection: close
471+
X-Real-IP: 20.207.73.82
472+
X-Forwarded-For: 20.207.73.82 192.168.21.1
473+
X-Forwarded-Host: cloud.example.com
474+
X-Forwarded-Proto: https
475+
X-Forwarded-Ssl: on
476+
X-Forwarded-Port: 443
477+
X-Original-URI: /exapps/hello
478+
X-Forwarded-Proto: https
479+
user-agent: curl/8.11.1
480+
accept: */*
481+
```
482+
448483
## Contributing
449484

450485
Contributions to HaRP are welcome. Feel free to open issues, discussions or submit pull requests with improvements, bug fixes, or new features.

0 commit comments

Comments
 (0)