mirror of
https://github.com/mjl-/mox.git
synced 2025-07-12 17:44:35 +03:00
new website for www.xmox.nl
most content is in markdown files in website/, some is taken out of the repo README and rfc/index.txt. a Go file generates html. static files are kept in a separate repo due to size.
This commit is contained in:
61
gendoc.sh
61
gendoc.sh
@ -6,7 +6,22 @@ cat <<EOF
|
||||
Command mox is a modern, secure, full-featured, open source mail server for
|
||||
low-maintenance self-hosted email.
|
||||
|
||||
# Commands
|
||||
Mox is started with the "serve" subcommand, but mox also has many other
|
||||
subcommands.
|
||||
|
||||
Many of those commands talk to a running mox instance, through the ctl file in
|
||||
the data directory. Specify the configuration file (that holds the path to the
|
||||
data directory) through the -config flag or MOXCONF environment variable.
|
||||
|
||||
Commands that don't talk to a running mox instance are often for
|
||||
testing/debugging email functionality. For example for parsing an email message,
|
||||
or looking up SPF/DKIM/DMARC records.
|
||||
|
||||
Below is the usage information as printed by the command when started without
|
||||
any parameters. Followed by the help and usage information for each command.
|
||||
|
||||
|
||||
# Usage
|
||||
|
||||
EOF
|
||||
|
||||
@ -14,10 +29,6 @@ EOF
|
||||
|
||||
cat <<EOF
|
||||
|
||||
Many commands talk to a running mox instance, through the ctl file in the data
|
||||
directory. Specify the configuration file (that holds the path to the data
|
||||
directory) through the -config flag or MOXCONF environment variable.
|
||||
|
||||
EOF
|
||||
|
||||
# setting XDG_CONFIG_HOME ensures "mox localserve" has reasonable default
|
||||
@ -36,17 +47,39 @@ gofmt -w doc.go
|
||||
(
|
||||
cat <<EOF
|
||||
/*
|
||||
Package config holds the configuration file definitions for mox.conf (Static)
|
||||
and domains.conf (Dynamic).
|
||||
Package config holds the configuration file definitions.
|
||||
|
||||
These config files are in "sconf" format. Summarized: Indent with tabs, "#" as
|
||||
first non-whitespace character makes the line a comment (you cannot have a line
|
||||
with both a value and a comment), strings are not quoted/escaped and can never
|
||||
span multiple lines. See https://pkg.go.dev/github.com/mjl-/sconf for details.
|
||||
Mox uses two config files:
|
||||
|
||||
1. mox.conf, also called the static configuration file.
|
||||
2. domains.conf, also called the dynamic configuration file.
|
||||
|
||||
The static configuration file is never reloaded during the lifetime of a
|
||||
running mox instance. After changes to mox.conf, mox must be restarted for the
|
||||
changes to take effect.
|
||||
|
||||
The dynamic configuration file is reloaded automatically when it changes.
|
||||
If the file contains an error after the change, the reload is aborted and the
|
||||
previous version remains active.
|
||||
|
||||
Below are "empty" config files, generated from the config file definitions in
|
||||
the source code, along with comments explaining the fields. Fields named "x" are
|
||||
placeholders for user-chosen map keys.
|
||||
|
||||
# sconf
|
||||
|
||||
The config files are in "sconf" format. Properties of sconf files:
|
||||
|
||||
- Indentation with tabs only.
|
||||
- "#" as first non-whitespace character makes the line a comment. Lines with a
|
||||
value cannot also have a comment.
|
||||
- Values don't have syntax indicating their type. For example, strings are
|
||||
not quoted/escaped and can never span multiple lines.
|
||||
- Fields that are optional can be left out completely. But the value of an
|
||||
optional field may itself have required fields.
|
||||
|
||||
See https://pkg.go.dev/github.com/mjl-/sconf for details.
|
||||
|
||||
Annotated empty/default configuration files you could use as a starting point
|
||||
for your mox.conf and domains.conf, as generated by "mox config
|
||||
describe-static" and "mox config describe-domains":
|
||||
|
||||
# mox.conf
|
||||
|
||||
|
Reference in New Issue
Block a user