Skip to content

Commit 53fe4ca

Browse files
committed
Add note on TLS for dashboard
Signed-off-by: Alex Ellis (OpenFaaS Ltd) <[email protected]>
1 parent 3c8b338 commit 53fe4ca

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

docs/edge/tls.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,21 @@ sudo journalctl -u caddy --follow
5050

5151
If your license contains the OpenFaaS Dashboard, you can also add TLS for the dashboard.
5252

53+
There are three steps required:
54+
55+
1. Set the `public_url` environment variable in the `docker-compose.yml` file.
56+
2. Add a DNS record for the dashboard.
57+
3. Restart Caddy and faasd
58+
59+
First, edit `/var/lib/faasd/docker-compose.yml` and add the following to the `services` section:
60+
61+
```diff
62+
services:
63+
dashboard:
64+
environment:
65+
+ - "public_url=https://dashboard.example.com"
66+
```
67+
5368
Create another DNS record, this time for `dashboard.example.com`, and add the following to the Caddyfile:
5469

5570
```caddyfile
@@ -60,6 +75,10 @@ dashboard.example.com {
6075

6176
Then restart Caddy as before.
6277

78+
Then restart faasd with `sudo systemctl restart faasd`.
79+
80+
The dashboard will now be accessible via TLS at teh given URL i.e. `https://dashboard.example.com`.
81+
6382
## Expose a service
6483

6584
If you add a stateful service such as Grafana to the compose file, then you can use the same technique to expose it with TLS.

0 commit comments

Comments
 (0)