Commit be6031a9 authored by Cédric Le Ninivin's avatar Cédric Le Ninivin

do not delete file with rsync on import (not a good idea so far). Remove trap,...

do not delete file with rsync on import (not a good idea so far). Remove trap, equeue doesn't seem like loving it (block equeue which start using one core at a 100%)
parent e6f228a3
##############################################################################
#
# Copyright (c) 2013 Vifib SARL and Contributors. All Rights Reserved.
......@@ -108,14 +107,14 @@ class ImportRecipe(GenericBaseRecipe):
#!%(shell-binary)s
umask 077
cd %(backup-directory)s;
%(rsync-binary)s -avz --delete runner/ %(srv-directory)s/runner;
%(rsync-binary)s -avz runner/ %(srv-directory)s/runner;
%(rsync-binary)s -avz etc/ %(etc-directory)s;
ifs=$IFS IFS=';'
read user pass remaining < %(etc-directory)s/.users
IFS=$ifs
trap 'rm -f login_cookie' EXIT
%(curl-binary)s -vg6L -F clogin="$user" -F cpwd="$pass" --dump-header login_cookie %(backend-url)s/doLogin;
%(curl-binary)s -vg6LX POST --cookie login_cookie --max-time 5 %(backend-url)s/runSoftwareProfile;
rm -f login_cookie
""" % self.options)
self.createExecutable(wrapper, content=content)
......
Markdown is supported
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