Commit 5eb5e69e authored by mh's avatar mh
Browse files

do it outside the sudo block

parent 56142b70
......@@ -72,12 +72,8 @@ def upgrade_wordpress(wd)
# run the upgrade as sftp user
log "Running the upgrade script in #{wd}"
cmd_prefix = options['scl'] ? "scl enable #{options['scl']} -- " : ''
sudo(sftp_user_uid,group_gid) do
if options['scl']
cmd_prefix = "scl enable #{options['scl']} -- "
else
cmd_prefix = ''
end
cmd("#{cmd_prefix}/usr/local/bin/upgrade_wordpress #{shellescape(wd)}")
end
log "Upgrading Wordpress in #{wd} finished."
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment