make http(s) path for serving the account and admin pages configurable

so you can use the host (domain) name of the mail server for serving other
resources too. the default is is still that account is served on /, and so
takes all incoming requests before giving webhandlers a chance.

mox localserve now serves the account pages on /account/
This commit is contained in:
Mechiel Lukkien
2023-03-12 11:52:15 +01:00
parent 0099197d00
commit 10daf3cb81
10 changed files with 92 additions and 59 deletions

View File

@ -214,6 +214,10 @@ describe-static" and "mox config describe-domains":
# Default 80. (optional)
Port: 0
# Path to serve account requests on, e.g. /mox/. Useful if domain serves other
# resources. Default is /. (optional)
Path:
# Account web interface listener for HTTPS. Requires a TLS config. (optional)
AccountHTTPS:
Enabled: false
@ -221,6 +225,10 @@ describe-static" and "mox config describe-domains":
# Default 80. (optional)
Port: 0
# Path to serve account requests on, e.g. /mox/. Useful if domain serves other
# resources. Default is /. (optional)
Path:
# Admin web interface, for managing domains, accounts, etc. Served at /admin/.
# Preferrably only enable on non-public IPs. Hint: use 'ssh -L 8080:localhost:80
# you@yourmachine' and open http://localhost:8080/admin/, or set up a tunnel (e.g.
@ -231,6 +239,10 @@ describe-static" and "mox config describe-domains":
# Default 80. (optional)
Port: 0
# Path to serve admin requests on, e.g. /moxadmin/. Useful if domain serves other
# resources. Default is /admin/. (optional)
Path:
# Admin web interface listener for HTTPS. Requires a TLS config. Preferrably only
# enable on non-public IPs. (optional)
AdminHTTPS:
@ -239,6 +251,10 @@ describe-static" and "mox config describe-domains":
# Default 443. (optional)
Port: 0
# Path to serve admin requests on, e.g. /moxadmin/. Useful if domain serves other
# resources. Default is /admin/. (optional)
Path:
# Serve prometheus metrics, for monitoring. You should not enable this on a public
# IP. (optional)
MetricsHTTP: