Skip to content

Commit 6ac5aed

Browse files
Grout Wildcard documentation (#1441)
* Add documentation around `Grout Wildcard` support * Fix spellcheck * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent b9fa0d5 commit 6ac5aed

File tree

2 files changed

+59
-3
lines changed

2 files changed

+59
-3
lines changed

README.md

Lines changed: 56 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,10 @@
7373
- [TLS Interception](#tls-interception)
7474
- [TLS Interception With Docker](#tls-interception-with-docker)
7575
- [GROUT (NGROK Alternative)](#grout-ngrok-alternative)
76+
- [Grout Usage](#grout-usage)
77+
- [Grout Authentication](#grout-authentication)
78+
- [Grout Paths](#grout-paths)
79+
- [Grout Wildcard Domains](#grout-wildcard-domains)
7680
- [Grout using Docker](#grout-using-docker)
7781
- [How Grout works](#how-grout-works)
7882
- [Self-hosted Grout](#self-hosted-grout)
@@ -1323,7 +1327,10 @@ with TLS Interception:
13231327

13241328
# GROUT (NGROK Alternative)
13251329

1326-
`grout` is a drop-in alternative to `ngrok` that comes packaged within `proxy.py`
1330+
1. `grout` is a drop-in alternative for `ngrok` and `frp`
1331+
2. `grout` comes packaged within `proxy.py`
1332+
1333+
## Grout Usage
13271334

13281335
```console
13291336
grout
@@ -1375,12 +1382,58 @@ SUPPORT:
13751382
https://jaxl.io
13761383
```
13771384

1385+
## Grout Authentication
1386+
1387+
Grout supports authentication to protect your files, folders and services from unauthorized
1388+
access. Use `--basic-auth` flag to enforce authentication. Example:
1389+
1390+
```console
1391+
grout /path/to/folder --basic-auth user:pass
1392+
grout https://localhost:8080 --basic-auth u:p
1393+
```
1394+
1395+
## Grout Paths
1396+
1397+
By default, Grout allows access to all paths on the services. Use `--path` flag to restrict
1398+
access to only certain paths on your web service. Example:
1399+
1400+
```console
1401+
grout https://localhost:8080 --path /worker/
1402+
grout https://localhost:8080 --path /webhook/ --path /callback/
1403+
```
1404+
1405+
## Grout Wildcard Domains
1406+
1407+
By default, Grout client serves incoming traffic on a dedicated subdomain.
1408+
However, some services (e.g. Kubernetes) may want to serve traffic on adhoc subdomains.
1409+
Starting a dedicated Grout client for every adhoc subdomain may not be a practical solution.
1410+
1411+
For such scenarios, Grout supports wildcard domains. Here is how to configure your own
1412+
wildcard domain for use with Grout clients.
1413+
1414+
1. Choose a domain e.g. `custom.example.com`
1415+
2. Your service wants to serve traffic for `custom.example.com` and `*.custom.example.com`
1416+
3. If you plan on using `https://`, you need to setup a load balancer:
1417+
- Setup a HTTPS load balancer (LB)
1418+
- Configure LB with certificate generated for `custom.example.com` and `*.custom.example.com`
1419+
- Point traffic to Grout service public IP addresses
1420+
4. Contact Grout team at support@jaxl.com to whitelist `custom.example.com`. Grout team will make
1421+
sure you really own the domain and you have configured a valid SSL certificate as described above
1422+
1423+
Start Grout with `--wildcard` flag. Example:
1424+
1425+
```console
1426+
grout https://localhost:8080 custom.example.com --wildcard
1427+
2024-08-05 18:24:59,294 - grout - Logged in as someone@gmail.com
1428+
2024-08-05 18:25:03,159 - setup - Grouting https://*.custom.domain.com
1429+
```
1430+
13781431
## Grout using Docker
13791432

13801433
```console
1381-
docker run -it \
1434+
docker run --rm -it \
13821435
--entrypoint grout \
1383-
--rm -v ~/.proxy:/root/.proxy \
1436+
-v ~/.proxy:/root/.proxy \
13841437
abhinavsingh/proxy.py:latest \
13851438
http://host.docker.internal:29876
13861439
```

docs/spelling_wordlist.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,6 @@ websocket
2828
writables
2929
www
3030
youtube
31+
Kubernetes
32+
adhoc
33+
balancer

0 commit comments

Comments
 (0)