mirror of https://github.com/tiyn/wiki
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
45 lines
1.3 KiB
45 lines
1.3 KiB
5 years ago
|
# Dovecot
|
||
|
|
||
|
## Setup Server
|
||
|
|
||
|
### Docker
|
||
|
|
||
5 years ago
|
The official container and documentation was made by [tvial](https://hub.docker.com/r/tvial/docker-mailserver).
|
||
5 years ago
|
It contains dovecot, antispam, antivirus, ssl, etc.
|
||
|
|
||
|
#### Configuration
|
||
5 years ago
|
|
||
|
The configuration is done automatically using scripts by tvial.
|
||
|
First you need to download the essential setup files.
|
||
|
|
||
|
```
|
||
|
curl -o setup.sh https://raw.githubusercontent.com/tomav/docker-mailserver/master/setup.sh; chmod a+x ./setup.sh
|
||
|
|
||
|
curl -o docker-compose.yml https://raw.githubusercontent.com/tomav/docker-mailserver/master/docker-compose.yml.dist
|
||
|
|
||
|
curl -o .env https://raw.githubusercontent.com/tomav/docker-mailserver/master/.env.dist
|
||
|
|
||
|
curl -o env-mailserver https://raw.githubusercontent.com/tomav/docker-mailserver/master/env-mailserver.dist
|
||
|
```
|
||
|
|
||
5 years ago
|
After that you need to edit the `.env` and the `env-mailserver` files to configure the mailserver.
|
||
5 years ago
|
|
||
5 years ago
|
You then need to start the container with the `rebuild.sh` and add email accounts using the following command.
|
||
5 years ago
|
|
||
5 years ago
|
`./setup.sh email add <user@domain> (<password>)`
|
||
5 years ago
|
|
||
|
And finally generate the DCIM keys and rebuild once again.
|
||
|
|
||
5 years ago
|
`./setup.sh config dkim`
|
||
5 years ago
|
|
||
5 years ago
|
Afterwards you're ready to go by once again running the `rebuild.sh` file.
|
||
|
|
||
|
#### Rebuild
|
||
|
|
||
|
```
|
||
|
#!/bin/sh
|
||
|
docker-compose down
|
||
|
docker pull tvial/docker-mailserver:latest
|
||
|
docker-compose up -d
|
||
|
```
|