Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- root@example:~# docker stop mail
- mail
- root@example:~# docker rm -f mail
- mail
- root@example:~# docker rmi -f cinemapress/mail
- Untagged: cinemapress/mail:latest
- Untagged: cinemapress/mail@sha256:65d3c96e27733761a83ac7db90c52870611a65c8fd338d6d077552b4f1085f1a
- Deleted: sha256:a2c2e768321965f591291da807d040611abec8b544a7337af2f5e816f15905ec
- Deleted: sha256:00d066652406b87273d6f94bd3b17da44f2fcdd7ec5810a89f9dab77a5ab82e1
- Deleted: sha256:566ba02597ed16627b1bb705e0a5c12244907b7e992ca933b78896528712612a
- Deleted: sha256:ae3d16c739658addff4a16c9875167db57c08ba24dbe0004a903386718c29267
- Deleted: sha256:56475b85210525ed07c52e8d49dbc6f69323a260aa06b76c2df9e72827c6020b
- Deleted: sha256:957a2ce2fcda57f6de2d5b5f0af88f8f273b38e0beb5e25a6066c621bcb0e701
- Deleted: sha256:327754eacb2065073e9418469d091042ea702db756dc52c0559061c6bc9e7835
- Deleted: sha256:b9828262ca4cc3c6263115b398970cb66b3cf7d46aaca65ecc5375778294573d
- Deleted: sha256:ca80c765c70fd389800cbe543768d86ebb92889400ca753c1f523c9b5c40353c
- Deleted: sha256:9a255fce44766e4daba34c6baa67e761430ef862fdfcc9f1e47fea0776a0e5e2
- Deleted: sha256:26db0ebd3c7b42c09cc89c00d7cf528e75490b056566ef64b84c7cd3a184b2e8
- Deleted: sha256:5557c2b6aa926dc1388292621e940207d219587397da084afac44cef5bb2fa4c
- Deleted: sha256:50bf034b3c89974f2f0cf28f9ce1c252d9cf27a02bd071fe379ca639400c4984
- Deleted: sha256:42cdb80b527abcc08559076025e0dcd63a64001104010a3234aafc63cae8dc36
- Deleted: sha256:6f8f8271620a4e59cb809eda07f097f4e45c61e2eab0bd1041b02f093e856995
- Deleted: sha256:b28d71e7a747a198b57bce9d36609ce94111ad70f3a3bdff93064f6c6a7196bb
- Deleted: sha256:613343930491433d1f1edf76e10eb4e2cf12a957e9d97c07bc900a917af64126
- Deleted: sha256:11b4a46873338423ab124f2ec4f28d3e9eb25a3ea0671147f751ad9296279e02
- Deleted: sha256:df2648ee63837e084e4e44865e5f1374208bc15325e124d214d27869f1235536
- Deleted: sha256:f5b87bef9a05c5ff70e1ed615e0dcbb4553ec0cb3ec6c07e996e557643c462a7
- Deleted: sha256:39c0a3786b884757f31b3f64b2c21b774b05c4bdf0691d1dae70f10f49c19ccf
- Deleted: sha256:288ee21fa681b11b62ed10a53e89ca85fcc57a56fee87decb7ad9c7562bd4a21
- Deleted: sha256:c070bce54d0589e79d4c02f04d4886acdbd401348b75aecd6dfe27193939bebd
- Deleted: sha256:944a50e8069285e15f4522e5e5e7501277afeac2b8fccf410d0fce397357deb5
- Deleted: sha256:46bb121cf77fdeaaab651d7749b865b80df388c386c31f29d7708175f9e10990
- Deleted: sha256:63ae42e44e95293b28f50e1a41374689d0566cbd7f0b0caab0c421f8b4b762a6
- Deleted: sha256:46c1f780543262ab5774f83b41106f366e64b7b20a953182200b880b8761aaa6
- Deleted: sha256:6b6467e9429da271c32d566585434d284832fd16416aa35f1b85d6435d4ef111
- Deleted: sha256:52c4f88984f4c24350238d1aaebe23a39a9c60eb2704ee60b0b5f4a23113dc88
- Deleted: sha256:905b284f4a809bd2330c9f97178ff4a3f53a30dfeead3711514b3b593d3b0c16
- Deleted: sha256:c456091707e335d3a58bd64af214fabc2bb88657417f21f53e012186be63e000
- Deleted: sha256:f76dbea2ee49c3ca37382cba31525281dd863eae99b78a124803a73ddc6017f1
- Deleted: sha256:432e972d50b835ec383f254f60f6c38bfcda9363579b479dccd2afd6af2f8ee2
- Deleted: sha256:53a84f3dcfe691ea846f8dd31358f95d0a8b4a7867ac93a3a9fa25d18c88923b
- Deleted: sha256:fe7129b343f73bd04faa6c7d2a175339d65f0ab09bf138211cf4685fb2d56e65
- Deleted: sha256:618b4471406c21dd68f4a5a7144b1264d66e4bcbe9cd0e30749d975c818d9afa
- Deleted: sha256:dac28a390e7faade1c695e953e4d4bb057b9cdfe35da506e3eab685270a7ea5b
- Deleted: sha256:190c5fc2fe03fc34e028988507cb8a3bb16f934ff9dd9c63b405793ded949722
- Deleted: sha256:b264a9b301ff296cf7717a63008b2e774107d99622d07bec24d6e3c580c16e2f
- Deleted: sha256:f124cae28578740a9766a852f4dfa7f3efee91b94a4141baf152e3cd807f58c9
- Deleted: sha256:4f7c01f7b51b27625eff0f6357df39c65239576ce0df08d36e82f815029c1c45
- Deleted: sha256:94d2253d16a5719086adb6a386f42385d2265ba393581a5ca1a5d355650b3197
- Deleted: sha256:cb42413394c4059335228c137fe884ff3ab8946a014014309676c25e3ac86864
- root@example:~# cinemapress mailserver example.org
- Unable to find image 'cinemapress/mail:latest' locally
- latest: Pulling from cinemapress/mail
- a076a628af6f: Pulling fs layer
- b5afddf182ca: Pulling fs layer
- 5ebe891e3bb9: Pulling fs layer
- 6884ed77b465: Waiting
- a7f3ed9aa5e0: Pulling fs layer
- 67f2c647b931: Waiting
- 957fffd1ae7c: Waiting
- 1c4b0df1cd9e: Waiting
- 7273a7428794: Waiting
- dada312e98ce: Waiting
- 0d5d2dca50c0: Waiting
- 6c8bf8f4a6ea: Waiting
- 6d7fde925ef0: Waiting
- 9a1a40f74889: Waiting
- bc616c82c456: Waiting
- b8b44592d63b: Waiting
- c7fc93c40b71: Waiting
- 089df0c1dbe2: Waiting
- 16754d43405a: Waiting
- b15fd8b176ef: Pull complete
- 81fc63e1f721: Pull complete
- 0f937ab04b2b: Pull complete
- 900f6f23b9c9: Pull complete
- ca4fc3440b50: Pull complete
- aaaf32a49af9: Pull complete
- 403966b19ce8: Pull complete
- a695b896a262: Pull complete
- 6f67ef3bb964: Pull complete
- 664061e4a837: Pull complete
- b5b701be8c14: Pull complete
- 537f6a09b583: Pull complete
- 20f27a6d7613: Pull complete
- 21ea0759530b: Pull complete
- a2f5899740ab: Pull complete
- 96716172574f: Pull complete
- 147d9a1127de: Pull complete
- 6e747da52806: Pull complete
- 6bd2149387e1: Pull complete
- 8ea006e405a1: Pull complete
- 85a41f71d6e9: Pull complete
- 255c9cc3b759: Pull complete
- 3ed37aecf3d0: Pull complete
- Digest: sha256:65d3c96e27733761a83ac7db90c52870611a65c8fd338d6d077552b4f1085f1a
- Status: Downloaded newer image for cinemapress/mail:latest
- 284f545610ea97119fadcfdeafa82b443112773488e48ff64269d2c6c0aed144
- ------------------------------------------------------------------
- -----------------[ MAIL SERVER example.org STARTED ]----------------
- ------------------------------------------------------------------
- Type: A
- Name: mail.example.org
- Content: IP of your server
- ------------------------------------------------------------------
- Type: A
- Name: imap.example.org
- Content: IP of your server
- ------------------------------------------------------------------
- Type: A
- Name: smtp.example.org
- Content: IP of your server
- ------------------------------------------------------------------
- Type: MX
- Name: example.org
- Content: mail.example.org
- Priority: 1
- ------------------------------------------------------------------
- Type: TXT
- Name: example.org
- Content: v=spf1 mx -all
- ------------------------------------------------------------------
- root@example:~# cinemapress ms help
- SETUP(1)
- NAME
- setup.sh - docker-mailserver administration script
- SYNOPSIS
- ./setup.sh [ OPTIONS... ] COMMAND [ help | ARGUMENTS... ]
- COMMAND := { email | alias | quota | config | relay | debug } SUBCOMMAND
- DESCRIPTION
- This is the main administration script that you use for all interactions with your
- mail server. Setup, configuration and much more is done with this script.
- Please note that the script executes most of the commands inside the container itself.
- If the image was not found, this script will pull the :latest tag of
- mailserver/docker-mailserver. This tag refers to the latest release,
- see the tagging convention in the README under
- https://github.com/docker-mailserver/docker-mailserver/blob/master/README.md
- You will be able to see detailed information about the script you re invoking and
- its arguments by appending help after your command. Currently, this
- does not work with all scripts.
- VERSION
- The current version of this script is backwards compatible with versions of
- docker-mailserver after 8.0.1. In case that there is not a more recent release,
- this script is currently only working with the :edge tag.
- You can download the script for your release by substituting TAG from the
- following URL, where TAG looks like 'vX.X.X':
- https://raw.githubusercontent.com/docker-mailserver/docker-mailserver/TAG/setup.sh
- OPTIONS
- Config path, container or image adjustments
- -i IMAGE_NAME
- Provides the name of the docker-mailserver image. The default value is
- docker.io/mailserver/docker-mailserver:latest
- -c CONTAINER_NAME
- Provides the name of the running container.
- -p PATH
- Provides the config folder path. The default is
- /usr/bin/config/
- SELinux
- -z
- Allows container access to the bind mount content that is shared among
- multiple containers on a SELinux-enabled host.
- -Z
- Allows container access to the bind mount content that is private and
- unshared with other containers on a SELinux-enabled host.
- [SUB]COMMANDS
- COMMAND email :=
- /usr/bin/mailcinema email add <EMAIL ADDRESS> [<PASSWORD>]
- /usr/bin/mailcinema email update <EMAIL ADDRESS> [<PASSWORD>]
- /usr/bin/mailcinema email del [ OPTIONS... ] <EMAIL ADDRESS>
- /usr/bin/mailcinema email restrict <add|del|list> <send|receive> [<EMAIL ADDRESS>]
- /usr/bin/mailcinema email list
- COMMAND alias :=
- /usr/bin/mailcinema alias add <EMAIL ADDRESS> <RECIPIENT>
- /usr/bin/mailcinema alias del <EMAIL ADDRESS> <RECIPIENT>
- /usr/bin/mailcinema alias list
- COMMAND quota :=
- /usr/bin/mailcinema quota set <EMAIL ADDRESS> [<QUOTA>]
- /usr/bin/mailcinema quota del <EMAIL ADDRESS>
- COMMAND config :=
- /usr/bin/mailcinema config dkim [ ARGUMENTS... ]
- /usr/bin/mailcinema config ssl <FQDN> (ATTENTION: This is deprecated and will be removed soon.)
- COMMAND relay :=
- /usr/bin/mailcinema relay add-domain <DOMAIN> <HOST> [<PORT>]
- /usr/bin/mailcinema relay add-auth <DOMAIN> <USERNAME> [<PASSWORD>]
- /usr/bin/mailcinema relay exclude-domain <DOMAIN>
- COMMAND debug :=
- /usr/bin/mailcinema debug fetchmail
- /usr/bin/mailcinema debug fail2ban [unban <IP>]
- /usr/bin/mailcinema debug show-mail-logs
- /usr/bin/mailcinema debug inspect
- /usr/bin/mailcinema debug login <COMMANDS>
- EXAMPLES
- ./setup.sh email add test@domain.tld
- Add the email account test@domain.tld. You will be prompted
- to input a password afterwards since no password was supplied.
- ./setup.sh config dkim keysize 2048 domain 'whoami.com,whoareyou.org'
- Creates keys of length 2048 but in an LDAP setup where domains are not known to
- Postfix by default, so you need to provide them yourself in a comma-separated list.
- ./setup.sh config dkim help
- This will provide you with a detailed explanation on how to use the
- config dkim command, showing what arguments can be passed and what they do.
- EXIT STATUS
- Exit status is 0 if the command was successful. If there was an unexpected error, an error
- message is shown describing the error. In case of an error, the script will exit with exit
- status 1.
- root@example:~# cinemapress ms email add support@example.org
- root@example:~# cinemapress ms email update support@example.org
- root@example:~# cinemapress ms email list
- support@example.org
- root@example:~# cinemapress ms email del support@example.org
- Do you want to delete the mailbox as well (removing all mails) ? [Y/n] Y
- Mailbox directory '/var/mail/example.org/support' did not exist.
- Error :: No valid address:
- Aborting.
- root@example:~# cinemapress ms config dkim
- OPEN-DKIM(8)
- NAME
- open-dkim - configure DomainKeys Identified Mail (DKIM)
- SYNOPSIS
- ./setup.sh config dkim [ OPTIONS... ]
- DESCRIPTION
- Configures DKIM keys. OPTIONS can be used to configure a more complex setup.
- LDAP setups require these options.
- OPTIONS
- Generic Program Information
- help Print the usage information.
- Configuration adjustments
- keysize Set the size of the keys to be generated. Possible are 1024, 2024 and 4096 (default).
- selector Set a manual selector (default is 'mail') for the key. (ATTENTION: NOT IMPLEMENTED YET!)
- domain Provide the domain(s) for which keys are to be generated.
- EXAMPLES
- ./setup.sh config dkim size 2048
- Creates keys of length 2048 bit in a default setup where domains are obtained from
- your accounts.
- ./setup.sh config dkim size 2048 selector 2021-dkim
- Creates keys of length 2048 bit in a default setup where domains are obtained from
- your accounts. The DKIM selector used is '2021-dkim'.
- ./setup.sh config dkim size 2048 selector 2021-dkim domain 'whoami.com,whoareyou.org'
- Appropriate for an LDAP setup. Creates keys of length 2048 bit in a default setup
- where domains are obtained from your accounts. The DKIM selector used is '2021-dkim'.
- The domains for which DKIM keys are generated are 'whoami.com' and 'whoareyou.org'.
- EXIT STATUS
- Exit status is 0 if command was successful. If wrong arguments are provided or arguments contain
- errors, the script will exit early with exit status 2.
- Unknown options . Aborting.
- ––– UNCHECKED ERROR
- – script = setup.sh
- – function = _docker_image / ${CRI} run --rm -v "${CONFIG_PATH}:/tmp/docker-mailserver${USING_SELINUX}" "${USE_TTY}" "${IMAGE_NAME}" "${@}"
- – line = 235
- – exit code = 2
- Make sure you use a version of this script that matches
- the version / tag of docker-mailserver. Please read the
- 'Get the tools' section in the README on GitHub careful-
- ly and use ./setup.sh help and read the VERSION section.
- root@example:~# cinemapress ms example.org
- docker: Error response from daemon: Conflict. The container name "/mail" is already in use by container "284f545610ea97119fadcfdeafa82b443112773488e48ff64269d2c6c0aed144". You have to remove (or rename) that container to be able to reuse that name.
- See 'docker run --help'.
- ------------------------------------------------------------------
- -----------------[ MAIL SERVER example.org STARTED ]----------------
- ------------------------------------------------------------------
- Type: A
- Name: mail.example.org
- Content: IP of your server
- ------------------------------------------------------------------
- Type: A
- Name: imap.example.org
- Content: IP of your server
- ------------------------------------------------------------------
- Type: A
- Name: smtp.example.org
- Content: IP of your server
- ------------------------------------------------------------------
- Type: MX
- Name: example.org
- Content: mail.example.org
- Priority: 1
- ------------------------------------------------------------------
- Type: TXT
- Name: example.org
- Content: v=spf1 mx -all
- ------------------------------------------------------------------
- root@example:~# docker stop mail
- mail
- root@example:~# docker rm -f mail
- mail
- root@example:~# docker rmi -f cinemapress/mail
- Untagged: cinemapress/mail:latest
- Untagged: cinemapress/mail@sha256:65d3c96e27733761a83ac7db90c52870611a65c8fd338d6d077552b4f1085f1a
- Deleted: sha256:a2c2e768321965f591291da807d040611abec8b544a7337af2f5e816f15905ec
- Deleted: sha256:00d066652406b87273d6f94bd3b17da44f2fcdd7ec5810a89f9dab77a5ab82e1
- Deleted: sha256:566ba02597ed16627b1bb705e0a5c12244907b7e992ca933b78896528712612a
- Deleted: sha256:ae3d16c739658addff4a16c9875167db57c08ba24dbe0004a903386718c29267
- Deleted: sha256:56475b85210525ed07c52e8d49dbc6f69323a260aa06b76c2df9e72827c6020b
- Deleted: sha256:957a2ce2fcda57f6de2d5b5f0af88f8f273b38e0beb5e25a6066c621bcb0e701
- Deleted: sha256:327754eacb2065073e9418469d091042ea702db756dc52c0559061c6bc9e7835
- Deleted: sha256:b9828262ca4cc3c6263115b398970cb66b3cf7d46aaca65ecc5375778294573d
- Deleted: sha256:ca80c765c70fd389800cbe543768d86ebb92889400ca753c1f523c9b5c40353c
- Deleted: sha256:9a255fce44766e4daba34c6baa67e761430ef862fdfcc9f1e47fea0776a0e5e2
- Deleted: sha256:26db0ebd3c7b42c09cc89c00d7cf528e75490b056566ef64b84c7cd3a184b2e8
- Deleted: sha256:5557c2b6aa926dc1388292621e940207d219587397da084afac44cef5bb2fa4c
- Deleted: sha256:50bf034b3c89974f2f0cf28f9ce1c252d9cf27a02bd071fe379ca639400c4984
- Deleted: sha256:42cdb80b527abcc08559076025e0dcd63a64001104010a3234aafc63cae8dc36
- Deleted: sha256:6f8f8271620a4e59cb809eda07f097f4e45c61e2eab0bd1041b02f093e856995
- Deleted: sha256:b28d71e7a747a198b57bce9d36609ce94111ad70f3a3bdff93064f6c6a7196bb
- Deleted: sha256:613343930491433d1f1edf76e10eb4e2cf12a957e9d97c07bc900a917af64126
- Deleted: sha256:11b4a46873338423ab124f2ec4f28d3e9eb25a3ea0671147f751ad9296279e02
- Deleted: sha256:df2648ee63837e084e4e44865e5f1374208bc15325e124d214d27869f1235536
- Deleted: sha256:f5b87bef9a05c5ff70e1ed615e0dcbb4553ec0cb3ec6c07e996e557643c462a7
- Deleted: sha256:39c0a3786b884757f31b3f64b2c21b774b05c4bdf0691d1dae70f10f49c19ccf
- Deleted: sha256:288ee21fa681b11b62ed10a53e89ca85fcc57a56fee87decb7ad9c7562bd4a21
- Deleted: sha256:c070bce54d0589e79d4c02f04d4886acdbd401348b75aecd6dfe27193939bebd
- Deleted: sha256:944a50e8069285e15f4522e5e5e7501277afeac2b8fccf410d0fce397357deb5
- Deleted: sha256:46bb121cf77fdeaaab651d7749b865b80df388c386c31f29d7708175f9e10990
- Deleted: sha256:63ae42e44e95293b28f50e1a41374689d0566cbd7f0b0caab0c421f8b4b762a6
- Deleted: sha256:46c1f780543262ab5774f83b41106f366e64b7b20a953182200b880b8761aaa6
- Deleted: sha256:6b6467e9429da271c32d566585434d284832fd16416aa35f1b85d6435d4ef111
- Deleted: sha256:52c4f88984f4c24350238d1aaebe23a39a9c60eb2704ee60b0b5f4a23113dc88
- Deleted: sha256:905b284f4a809bd2330c9f97178ff4a3f53a30dfeead3711514b3b593d3b0c16
- Deleted: sha256:c456091707e335d3a58bd64af214fabc2bb88657417f21f53e012186be63e000
- Deleted: sha256:f76dbea2ee49c3ca37382cba31525281dd863eae99b78a124803a73ddc6017f1
- Deleted: sha256:432e972d50b835ec383f254f60f6c38bfcda9363579b479dccd2afd6af2f8ee2
- Deleted: sha256:53a84f3dcfe691ea846f8dd31358f95d0a8b4a7867ac93a3a9fa25d18c88923b
- Deleted: sha256:fe7129b343f73bd04faa6c7d2a175339d65f0ab09bf138211cf4685fb2d56e65
- Deleted: sha256:618b4471406c21dd68f4a5a7144b1264d66e4bcbe9cd0e30749d975c818d9afa
- Deleted: sha256:dac28a390e7faade1c695e953e4d4bb057b9cdfe35da506e3eab685270a7ea5b
- Deleted: sha256:190c5fc2fe03fc34e028988507cb8a3bb16f934ff9dd9c63b405793ded949722
- Deleted: sha256:b264a9b301ff296cf7717a63008b2e774107d99622d07bec24d6e3c580c16e2f
- Deleted: sha256:f124cae28578740a9766a852f4dfa7f3efee91b94a4141baf152e3cd807f58c9
- Deleted: sha256:4f7c01f7b51b27625eff0f6357df39c65239576ce0df08d36e82f815029c1c45
- Deleted: sha256:94d2253d16a5719086adb6a386f42385d2265ba393581a5ca1a5d355650b3197
- Deleted: sha256:cb42413394c4059335228c137fe884ff3ab8946a014014309676c25e3ac86864
- root@example:~# cinemapress ms email add support@example.org
- root@example:~# cinemapress ms config dkim
- OPEN-DKIM(8)
- NAME
- open-dkim - configure DomainKeys Identified Mail (DKIM)
- SYNOPSIS
- ./setup.sh config dkim [ OPTIONS... ]
- DESCRIPTION
- Configures DKIM keys. OPTIONS can be used to configure a more complex setup.
- LDAP setups require these options.
- OPTIONS
- Generic Program Information
- help Print the usage information.
- Configuration adjustments
- keysize Set the size of the keys to be generated. Possible are 1024, 2024 and 4096 (default).
- selector Set a manual selector (default is 'mail') for the key. (ATTENTION: NOT IMPLEMENTED YET!)
- domain Provide the domain(s) for which keys are to be generated.
- EXAMPLES
- ./setup.sh config dkim size 2048
- Creates keys of length 2048 bit in a default setup where domains are obtained from
- your accounts.
- ./setup.sh config dkim size 2048 selector 2021-dkim
- Creates keys of length 2048 bit in a default setup where domains are obtained from
- your accounts. The DKIM selector used is '2021-dkim'.
- ./setup.sh config dkim size 2048 selector 2021-dkim domain 'whoami.com,whoareyou.org'
- Appropriate for an LDAP setup. Creates keys of length 2048 bit in a default setup
- where domains are obtained from your accounts. The DKIM selector used is '2021-dkim'.
- The domains for which DKIM keys are generated are 'whoami.com' and 'whoareyou.org'.
- EXIT STATUS
- Exit status is 0 if command was successful. If wrong arguments are provided or arguments contain
- errors, the script will exit early with exit status 2.
- Unknown options . Aborting.
- ––– UNCHECKED ERROR
- – script = setup.sh
- – function = _docker_image / ${CRI} run --rm -v "${CONFIG_PATH}:/tmp/docker-mailserver${USING_SELINUX}" "${USE_TTY}" "${IMAGE_NAME}" "${@}"
- – line = 235
- – exit code = 2
- Make sure you use a version of this script that matches
- the version / tag of docker-mailserver. Please read the
- 'Get the tools' section in the README on GitHub careful-
- ly and use ./setup.sh help and read the VERSION section.
- root@example:~# docker stop mail
- Error response from daemon: No such container: mail
- root@example:~# docker rm -f mail
- Error: No such container: mail
- root@example:~# docker rmi -f cinemapress/mail
- Error: No such image: cinemapress/mail
- root@example:~# docker rmi -f cinemapress/mail
- Error: No such image: cinemapress/mail
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement