2
0
mirror of https://github.com/frappe/bench.git synced 2024-11-11 15:51:03 +00:00

restart supervisor before restarting workers

This commit is contained in:
Ameya Shenoy 2018-03-19 13:04:00 +05:30
parent c295be6114
commit c6f8800a2f
No known key found for this signature in database
GPG Key ID: 735490161CD5C91E

View File

@ -407,6 +407,8 @@ def restart_supervisor_processes(bench_path='.', web_workers=False):
else:
group = 'frappe:'
if find_executable('systemctl'):
exec_cmd('sudo systemctl restart supervisor.service && sleep 1')
exec_cmd('sudo supervisorctl restart {group}'.format(group=group), cwd=bench_path)
def set_default_site(site, bench_path='.'):