Hello,I don't understand how the fabric.operations.run() could work with use_sudo=True.
I'm connecting as user "foo", and "foo" is able to "sudo -u bar" on remote host.
with: env.sudo_user = "bar" I'm running: put(src, dst, use_sudo=True) Fabric does the following on remote host: 1) It creates a temporary file in foo's $HOME (a sha1 file) 2) File is owned by foo:foo 3) Fabric runs something like the following: Requested: mv "994c72888735e219222f3212ea67c3adbfda2ca0" "/home/foo/dst/src"Executed: sudo -S -p 'sudo password:' -u "bar" /bin/sh -c "mv \"994c72888735e219222f3212ea67c3adbfda2ca0\" \"/home/foo/dst/src\"" 4) The operation fails with a "Permission denied" wich is logical, as file is owner by foo:foo and sudo -u bar mv foo dst will never work ..
Did I missed something .. ? My ultimate goal is to be able to deploy without root access. Thanks, Julien -- No trees were killed in the creation of this message. However, many electrons were terribly inconvenienced.
<<attachment: jcigar.vcf>>
_______________________________________________ Fab-user mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/fab-user
