diff options
author | Joey Hess <joeyh@joeyh.name> | 2015-07-27 11:03:58 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2015-07-27 11:03:58 -0400 |
commit | 3b102f7870753b1d47dcc45ceca65a25e086e01d (patch) | |
tree | 831a0920d2bdaecf46d1140a2dad26be4fe696c2 /Assistant | |
parent | 4215e8c7cf4d3a5fb2c42bf9c87c8c0881e8ff13 (diff) |
use mangled hostname for gitlab repo when using a dedicated git-annex ssh key
Diffstat (limited to 'Assistant')
-rw-r--r-- | Assistant/Ssh.hs | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/Assistant/Ssh.hs b/Assistant/Ssh.hs index cd29d5036..80fb5c19a 100644 --- a/Assistant/Ssh.hs +++ b/Assistant/Ssh.hs @@ -325,11 +325,16 @@ setSshConfig sshdata config = do (settings ++ config) setSshConfigMode configfile - return $ sshdata { sshHostName = T.pack mangledhost } + return $ sshdata + { sshHostName = T.pack mangledhost + , sshRepoUrl = replace orighost mangledhost + <$> sshRepoUrl sshdata + } where + orighost = T.unpack $ sshHostName sshdata mangledhost = mangleSshHostName sshdata settings = - [ ("Hostname", T.unpack $ sshHostName sshdata) + [ ("Hostname", orighost) , ("Port", show $ sshPort sshdata) ] |