diff options
| author | Joey Hess <joey@kitenet.net> | 2014-11-22 00:34:34 -0400 |
|---|---|---|
| committer | Joey Hess <joey@kitenet.net> | 2014-11-22 00:34:34 -0400 |
| commit | f1fdd6f678d2d5d753407434a53cc6e2876185ae (patch) | |
| tree | c3dd0405c6cce8b2fc6dd2c9bd10aab97d49bfc0 /src | |
| parent | d3b7c8585e2c290a3e005f17411827c8836bd225 (diff) | |
propellor spin
Diffstat (limited to 'src')
| -rw-r--r-- | src/Propellor/Server.hs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/Propellor/Server.hs b/src/Propellor/Server.hs index d6987d2d..a72c83ae 100644 --- a/src/Propellor/Server.hs +++ b/src/Propellor/Server.hs @@ -128,13 +128,14 @@ sendPrecompiled hn = void $ actionMessage ("Uploading locally compiled propellor cacheparams <- sshCachingParams hn withTmpDir "propellor" $ \tmpdir -> bracket getWorkingDirectory changeWorkingDirectory $ \_ -> do - changeWorkingDirectory tmpdir let shimdir = "propellor" + changeWorkingDirectory shimdir me <- readSymbolicLink "/proc/self/exe" - shim <- Shim.setup me shimdir + shim <- Shim.setup me "." + changeWorkingDirectory tmpdir when (shim /= shimdir </> "propellor") $ renameFile shim (shimdir </> "propellor") - withTmpFile "propellor.tar" $ \tarball _ -> allM id + withTmpFile "propellor.tar." $ \tarball _ -> allM id [ boolSystem "strip" [File me] , boolSystem "tar" [Param "cf", File tarball, File shimdir] , boolSystem "scp" $ cacheparams ++ [File tarball, Param ("root@"++hn++":"++remotetarball)] |
