propellor spin
This commit is contained in:
parent
0b5c5f7c9a
commit
8bb029002e
|
@ -0,0 +1,26 @@
|
||||||
|
module Propellor.Property.Postfix where
|
||||||
|
|
||||||
|
import Propellor
|
||||||
|
import qualified Propellor.Property.Apt as Apt
|
||||||
|
import Propellor.Property.User
|
||||||
|
import Utility.SafeCommand
|
||||||
|
import Utility.FileMode
|
||||||
|
|
||||||
|
import System.PosixCompat
|
||||||
|
|
||||||
|
installed :: Property
|
||||||
|
installed = Apt.serviceInstalledRunning "postfix"
|
||||||
|
|
||||||
|
-- | Configures postfix as a satellite system, which
|
||||||
|
-- relats all mail through a relay host, which defaults to smtp.domain.
|
||||||
|
--
|
||||||
|
-- The smarthost may refuse to relay mail on to other domains, without
|
||||||
|
-- futher coniguration/keys. But this should be enough to get cron job
|
||||||
|
-- mail flowing to a place where it will be seen.
|
||||||
|
satellite :: Property
|
||||||
|
satellite = Apt.reConfigure "postfix"
|
||||||
|
[ ("postfix/main_mailer_type", "select", "Satellite system")
|
||||||
|
, ("postfix/destinations", "string", "")
|
||||||
|
]
|
||||||
|
`describe` "postfix satellite system"
|
||||||
|
`requires` installed
|
|
@ -18,6 +18,7 @@ import qualified Propellor.Property.OpenId as OpenId
|
||||||
import qualified Propellor.Property.Docker as Docker
|
import qualified Propellor.Property.Docker as Docker
|
||||||
import qualified Propellor.Property.Git as Git
|
import qualified Propellor.Property.Git as Git
|
||||||
import qualified Propellor.Property.Apache as Apache
|
import qualified Propellor.Property.Apache as Apache
|
||||||
|
import qualified Propellor.Property.Postfix as Postfix
|
||||||
import qualified Propellor.Property.SiteSpecific.GitHome as GitHome
|
import qualified Propellor.Property.SiteSpecific.GitHome as GitHome
|
||||||
import qualified Propellor.Property.SiteSpecific.GitAnnexBuilder as GitAnnexBuilder
|
import qualified Propellor.Property.SiteSpecific.GitAnnexBuilder as GitAnnexBuilder
|
||||||
import qualified Propellor.Property.SiteSpecific.JoeySites as JoeySites
|
import qualified Propellor.Property.SiteSpecific.JoeySites as JoeySites
|
||||||
|
@ -40,7 +41,9 @@ hosts = -- (o) `
|
||||||
& Apt.unattendedUpgrades
|
& Apt.unattendedUpgrades
|
||||||
& Network.ipv6to4
|
& Network.ipv6to4
|
||||||
& Tor.isBridge
|
& Tor.isBridge
|
||||||
|
& Postfix.satellite
|
||||||
& Docker.configured
|
& Docker.configured
|
||||||
|
|
||||||
& cname "shell.olduse.net"
|
& cname "shell.olduse.net"
|
||||||
& JoeySites.oldUseNetShellBox
|
& JoeySites.oldUseNetShellBox
|
||||||
|
|
||||||
|
@ -62,6 +65,7 @@ hosts = -- (o) `
|
||||||
, standardSystem "orca.kitenet.net" Unstable "amd64"
|
, standardSystem "orca.kitenet.net" Unstable "amd64"
|
||||||
& Hostname.sane
|
& Hostname.sane
|
||||||
& Apt.unattendedUpgrades
|
& Apt.unattendedUpgrades
|
||||||
|
& Postfix.satellite
|
||||||
& Docker.configured
|
& Docker.configured
|
||||||
& Docker.docked hosts "amd64-git-annex-builder"
|
& Docker.docked hosts "amd64-git-annex-builder"
|
||||||
& Docker.docked hosts "i386-git-annex-builder"
|
& Docker.docked hosts "i386-git-annex-builder"
|
||||||
|
@ -79,8 +83,7 @@ hosts = -- (o) `
|
||||||
& Apt.unattendedUpgrades
|
& Apt.unattendedUpgrades
|
||||||
& Apt.serviceInstalledRunning "ntp"
|
& Apt.serviceInstalledRunning "ntp"
|
||||||
& Dns.zones myDnsSecondary
|
& Dns.zones myDnsSecondary
|
||||||
|
& Postfix.satellite
|
||||||
& Apt.serviceInstalledRunning "postfix"
|
|
||||||
|
|
||||||
& Apt.serviceInstalledRunning "apache2"
|
& Apt.serviceInstalledRunning "apache2"
|
||||||
& File.hasPrivContent "/etc/ssl/certs/web.pem"
|
& File.hasPrivContent "/etc/ssl/certs/web.pem"
|
||||||
|
|
|
@ -81,6 +81,7 @@ Library
|
||||||
Propellor.Property.Network
|
Propellor.Property.Network
|
||||||
Propellor.Property.Obnam
|
Propellor.Property.Obnam
|
||||||
Propellor.Property.OpenId
|
Propellor.Property.OpenId
|
||||||
|
Propellor.Property.Postfix
|
||||||
Propellor.Property.Reboot
|
Propellor.Property.Reboot
|
||||||
Propellor.Property.Scheduled
|
Propellor.Property.Scheduled
|
||||||
Propellor.Property.Service
|
Propellor.Property.Service
|
||||||
|
|
Loading…
Reference in New Issue