diff --git a/content/2.getting-started/4.configuration.md b/content/2.getting-started/4.configuration.md new file mode 100644 index 0000000..c97d631 --- /dev/null +++ b/content/2.getting-started/4.configuration.md @@ -0,0 +1,28 @@ +--- +title: Configuration +description: '' +category: Installation +--- +Postal can be configured through its configuration file or environment variables. There are a fair number of areas which can be configured. + +You can review all the available configuration options. + +* [Full Postal Configuration file](https://github.com/postalserver/postal/blob/main/doc/config/yaml.yml) - this is an example configuration file that contains all the configuration options along with their defaults and a description. This file would usually exist in `/opt/postal/config/postal.yml`. + +* [All environment variables](https://github.com/postalserver/postal/blob/main/doc/config/environment-variables.md) - this page lists all the environment variables. All configuration that can be set in the config file can also be set by an environment variable. + +::callout +Note: If you change any configuration, you should be sure to restart Postal +:: + +## Ports and bind addresses + +The web & SMTP server listen on ports and addresses. The defaults for these can be set through configuration however, if you're running multiple instances of these on a single host you will need to specify different ports for each one. + +You can use the `PORT` and `BIND_ADDRESS` environment variables to provide instance-specific values for these processes. + +## Legacy configuration + +The current version for the Postal configuration file is `2`. This is shown by the `version: 2` in the configuration file itself. + +Postal still supports the version 1 (or legacy) configuration format from Postal v2 and earlier. If you are using this config file, you will receive a warning in the logs when starting Postal. We recommend changing your configuration to follow the new v2 format which is documented above. diff --git a/content/2.getting-started/4.dns-configuration.md b/content/2.getting-started/4.dns-configuration.md index ccd300f..14d654d 100644 --- a/content/2.getting-started/4.dns-configuration.md +++ b/content/2.getting-started/4.dns-configuration.md @@ -118,15 +118,15 @@ If you wish to receive incoming e-mail by forwarding messages directly to routes ## Example Postal Configuration -In your `postal.yml` you should have something that looks like the below: +In your `postal.yml` you should have something that looks like the below to cover the key DNS records. ```yaml dns: mx_records: - - postal.example.com - smtp_server_hostname: postal.example.com - track_domain: postal.example.com + - mx1.postal.example.com + - mx2.postal.example.com spf_include: spf.postal.example.com - return_path: rp.postal.example.com + return_path_domain: rp.postal.example.com route_domain: routes.postal.example.com + track_domain: track.postal.example.com ``` diff --git a/content/2.getting-started/4.upgrade-to-v3.md b/content/2.getting-started/5.upgrade-to-v3.md similarity index 100% rename from content/2.getting-started/4.upgrade-to-v3.md rename to content/2.getting-started/5.upgrade-to-v3.md diff --git a/content/2.getting-started/5.upgrade-to-v2.md b/content/2.getting-started/6.upgrade-to-v2.md similarity index 100% rename from content/2.getting-started/5.upgrade-to-v2.md rename to content/2.getting-started/6.upgrade-to-v2.md diff --git a/content/3.features/click-and-open-tracking.md b/content/3.features/click-and-open-tracking.md index a424c44..1c64427 100644 --- a/content/3.features/click-and-open-tracking.md +++ b/content/3.features/click-and-open-tracking.md @@ -1,7 +1,6 @@ --- title: Click & Open Tracking description: '' -position: 3.0 category: Features --- diff --git a/content/3.features/ip-pools.md b/content/3.features/ip-pools.md index d7bfc37..d98bdd6 100644 --- a/content/3.features/ip-pools.md +++ b/content/3.features/ip-pools.md @@ -1,7 +1,6 @@ --- title: IP Pools description: '' -position: 3.1 category: Features --- Postal supports sending messages from different IP addresses. This allows you to configure certain sets of IPs for different mail servers or send from different IPs based on the sender or recipient addresses. diff --git a/content/3.features/logging.md b/content/3.features/logging.md new file mode 100644 index 0000000..3928f18 --- /dev/null +++ b/content/3.features/logging.md @@ -0,0 +1,34 @@ +--- +title: Logging +description: '' +category: Features +--- + +All Postal processes log to STDOUT and STDERR which means their logs are managed by whatever engine is used to run the container. In the default case, this is Docker. + +## Limiting the size of logs + +Docker cam be configured to limit the size of the log files it stores. To avoid storing large numbers of log files, you should configure this appropriately. This can be achieved by setting a maximum size in your `/etc/docker/daemon.json` file. + +```json +{ + "log-driver": "local", + "log-opts": { + "max-size": "100m" + } +} +``` + +## Sending logs to Graylog + +Postal includes support for sending log output to a central Graylog server over UDP. This can be configured using the following options: + +```yaml +gelf: + # GELF-capable host to send logs to + host: + # GELF port to send logs to + port: 12201 + # The facility name to add to all log entries sent to GELF + facility: postal +``` diff --git a/content/3.features/smtp-tls.md b/content/3.features/smtp-tls.md index 077237f..5b5d2ab 100644 --- a/content/3.features/smtp-tls.md +++ b/content/3.features/smtp-tls.md @@ -1,7 +1,6 @@ --- title: SMTP TLS description: '' -position: 3.2 category: Features --- diff --git a/content/3.features/spam-and-virus-checking.md b/content/3.features/spam-and-virus-checking.md index 029e7b7..63e71f2 100644 --- a/content/3.features/spam-and-virus-checking.md +++ b/content/3.features/spam-and-virus-checking.md @@ -1,7 +1,6 @@ --- title: Spam & Virus Checking description: '' -position: 3.2 category: Features --- Postal can integrate with SpamAssassin and ClamAV to automatically scan incoming and outgoing messages that pass through mail servers.