summaryrefslogtreecommitdiff
path: root/Propellor/Types
diff options
context:
space:
mode:
authorJoey Hess2014-04-13 02:28:40 -0400
committerJoey Hess2014-04-13 02:28:40 -0400
commitc97285a21ea0e392e8c63c1898ee2deeb34e99a0 (patch)
tree7f7dfd46b003b5e41ea566e9ecd44316ec12d6af /Propellor/Types
parentc7830f4e669735bf46945592b315e7e367129888 (diff)
propellor spin
Diffstat (limited to 'Propellor/Types')
-rw-r--r--Propellor/Types/Attr.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/Propellor/Types/Attr.hs b/Propellor/Types/Attr.hs
index c253e32b..cdbe9ca3 100644
--- a/Propellor/Types/Attr.hs
+++ b/Propellor/Types/Attr.hs
@@ -6,6 +6,7 @@ import qualified Data.Set as S
data Attr = Attr
{ _hostname :: HostName
, _cnames :: S.Set Domain
+ , _sshPubKey :: Maybe String
, _dockerImage :: Maybe String
, _dockerRunParams :: [HostName -> String]
@@ -15,6 +16,7 @@ instance Eq Attr where
x == y = and
[ _hostname x == _hostname y
, _cnames x == _cnames y
+ , _sshPubKey x == _sshPubKey y
, _dockerImage x == _dockerImage y
, let simpl v = map (\a -> a "") (_dockerRunParams v)
@@ -25,12 +27,13 @@ instance Show Attr where
show a = unlines
[ "hostname " ++ _hostname a
, "cnames " ++ show (_cnames a)
+ , "sshPubKey " ++ show (_sshPubKey a)
, "docker image " ++ show (_dockerImage a)
, "docker run params " ++ show (map (\mk -> mk "") (_dockerRunParams a))
]
newAttr :: HostName -> Attr
-newAttr hn = Attr hn S.empty Nothing []
+newAttr hn = Attr hn S.empty Nothing Nothing []
type HostName = String
type Domain = String