mirror of
https://github.com/frappe/bench.git
synced 2024-11-12 00:06:36 +00:00
fix(playbooks): pre v5.1 compatibility for playbooks folder
This commit is contained in:
parent
a8688db8dc
commit
08bc61a53a
@ -359,7 +359,10 @@ def run_playbook(playbook_name, sudo=False, extra_vars=None):
|
|||||||
else:
|
else:
|
||||||
cwd = os.path.join(os.path.expanduser('~'), 'bench')
|
cwd = os.path.join(os.path.expanduser('~'), 'bench')
|
||||||
|
|
||||||
success = subprocess.check_call(args, cwd=os.path.join(cwd, 'bench', 'playbooks'), stdout=log_stream, stderr=sys.stderr)
|
playbooks_locations = [os.path.join(cwd, 'bench', 'playbooks'), os.path.join(cwd, 'playbooks')]
|
||||||
|
playbooks_folder = [x for x in playbooks_locations if os.path.exists(x)][0]
|
||||||
|
|
||||||
|
success = subprocess.check_call(args, cwd=playbooks_folder, stdout=log_stream, stderr=sys.stderr)
|
||||||
return success
|
return success
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user