diff options
| author | Joey Hess <joey@kitenet.net> | 2014-07-18 12:48:08 -0400 |
|---|---|---|
| committer | Joey Hess <joey@kitenet.net> | 2014-07-18 12:48:08 -0400 |
| commit | 1143ca7c5c673094ec2ab11d61d75a8928da6f2b (patch) | |
| tree | a03a0b28261a3aa88fa8ea15955cfbe0528bdcee /src | |
| parent | ad80a1600df71eb23c0e6948b179637dc3f74e24 (diff) | |
propellor spin
Diffstat (limited to 'src')
| -rw-r--r-- | src/Propellor/Property/Hostname.hs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/Propellor/Property/Hostname.hs b/src/Propellor/Property/Hostname.hs index c3821eb4..c489e2fb 100644 --- a/src/Propellor/Property/Hostname.hs +++ b/src/Propellor/Property/Hostname.hs @@ -9,6 +9,8 @@ import Data.List -- -- Configures /etc/hostname and the current hostname. -- +-- Configures /etc/mailname with the domain part of the hostname. +-- -- /etc/hosts is also configured, with an entry for 127.0.1.1, which is -- standard at least on Debian to set the FDQN. -- @@ -31,6 +33,8 @@ setTo hn = combineProperties desc go else Just $ trivial $ hostsline "127.0.1.1" [hn, basehost] , Just $ trivial $ hostsline "127.0.0.1" ["localhost"] , Just $ trivial $ cmdProperty "hostname" [basehost] + , Just $ "/etc/mailname" `File.hasContent` + [if null domain then hn else domain] ] hostsline ip names = File.fileProperty desc |
