Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: document webapp configuration for multi-ingress environments #3569

Merged
merged 4 commits into from
Sep 7, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 32 additions & 1 deletion docs/src/developer/reference/config-options.md
Original file line number Diff line number Diff line change
Expand Up @@ -764,4 +764,35 @@ Example:
multiIngress:
red.example.com: https://accounts.red.example.com/conversation-join/
green.example.com: https://accounts.green.example.net/conversation-join/
```
```

### Webapp

atomrc marked this conversation as resolved.
Show resolved Hide resolved
supersven marked this conversation as resolved.
Show resolved Hide resolved
In order to completely hide the root domain to the webapp, some environment variable need to be set. They will allow the webapp hostname to be used to generate the API endpoint, team settings links, account page links and CSP headers.

To enable dynamic hostname replacement, first set this variable:

```
ENABLE_DYNAMIC_HOSTNAME="true"
```

atomrc marked this conversation as resolved.
Show resolved Hide resolved
Then any other variable that will contain the string `[[hostname]]` will then be replaced by the hostname of the running webapp. (eg. if a webapp is running on `webapp.red.example.com` then any occurence of `[[hostname]]` in the config will be replaced by `red.example.com`).

atomrc marked this conversation as resolved.
Show resolved Hide resolved
You may then add this `[[hostname]]` in any environment variable

```
APP_BASE: https://[[hostname]]
BACKEND_REST: https://nginz-https.[[hostname]]
BACKEND_WS: wss://nginz-ssl.[[hostname]]
CSP_EXTRA_CONNECT_SRC: https://*.[[hostname]], wss://*.[[hostname]]
CSP_EXTRA_DEFAULT_SRC: https://*.[[hostname]]
CSP_EXTRA_FONT_SRC: https://*.[[hostname]]
CSP_EXTRA_FRAME_SRC: https://*.[[hostname]]
CSP_EXTRA_IMG_SRC: https://*.[[hostname]]
CSP_EXTRA_MANIFEST_SRC: https://*.[[hostname]]
CSP_EXTRA_MEDIA_SRC: https://*.[[hostname]]
CSP_EXTRA_PREFETCH_SRC: https://*.[[hostname]]
CSP_EXTRA_SCRIPT_SRC: https://*.[[hostname]]
CSP_EXTRA_STYLE_SRC: https://*.[[hostname]]
CSP_EXTRA_WORKER_SRC: https://*.[[hostname]]
```
Loading