From 91610aee8f34bb10959bdf6a6e5b16c895c7c1c2 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Fri, 16 Oct 2015 19:06:29 -0400 Subject: improve ssh user key properties * Ssh.keyImported is replaced with Ssh.userKeys. (API change) The new property only gets the private key from the privdata; the public key is provided as a parameter, and so is available as Info that other properties can use. * Ssh.keyImported' is renamed to Ssh.userKeyAt, and also changed to only import the private key from the privdata. (API change) * While Ssh.keyImported and Ssh.keyImported' avoided updating existing keys, the new Ssh.userKeys and Ssh.userKeyAt properties will always update out of date key files. * Ssh.pubKey renamed to Ssh.hostPubKey. (API change) This makes eg, setting up ssh for spin controllers work better. --- src/Propellor/Property/Dns.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Propellor/Property/Dns.hs') diff --git a/src/Propellor/Property/Dns.hs b/src/Propellor/Property/Dns.hs index 963b82f6..6646582b 100644 --- a/src/Propellor/Property/Dns.hs +++ b/src/Propellor/Property/Dns.hs @@ -524,7 +524,7 @@ getNamedConf = asks $ fromNamedConfMap . getInfo . hostInfo genSSHFP :: Domain -> Host -> Propellor [(BindDomain, Record)] genSSHFP domain h = concatMap mk . concat <$> (gen =<< get) where - get = fromHost [h] hostname Ssh.getPubKey + get = fromHost [h] hostname Ssh.getHostPubKey gen = liftIO . mapM genSSHFP' . M.elems . fromMaybe M.empty mk r = mapMaybe (\d -> if inDomain domain d then Just (d, r) else Nothing) (AbsDomain hostname : cnames) -- cgit v1.2.3