mirror of
https://github.com/frappe/bench.git
synced 2024-11-13 08:46:30 +00:00
refactor: check_supervisord_config
This commit is contained in:
parent
db13ce3732
commit
f734eef7a7
@ -58,7 +58,7 @@ def reload_nginx():
|
||||
def setup_supervisor(user=None, yes=False, skip_redis=False, skip_supervisord=False):
|
||||
from bench.utils import get_cmd_output
|
||||
from bench.config.supervisor import (
|
||||
update_supervisord_config,
|
||||
check_supervisord_config,
|
||||
generate_supervisor_config,
|
||||
)
|
||||
|
||||
@ -67,7 +67,7 @@ def setup_supervisor(user=None, yes=False, skip_redis=False, skip_supervisord=Fa
|
||||
if not skip_supervisord and "Permission denied" in get_cmd_output(
|
||||
"supervisorctl status"
|
||||
):
|
||||
update_supervisord_config(user=user)
|
||||
check_supervisord_config(user=user)
|
||||
|
||||
generate_supervisor_config(bench_path=".", user=user, yes=yes, skip_redis=skip_redis)
|
||||
|
||||
|
@ -9,7 +9,7 @@ import bench
|
||||
from bench.config.nginx import make_nginx_conf
|
||||
from bench.config.supervisor import (
|
||||
generate_supervisor_config,
|
||||
update_supervisord_config,
|
||||
check_supervisord_config,
|
||||
)
|
||||
from bench.config.systemd import generate_systemd_config
|
||||
from bench.bench import Bench
|
||||
@ -48,7 +48,7 @@ def setup_production(user, bench_path=".", yes=False):
|
||||
generate_systemd_config(bench_path=bench_path, user=user, yes=yes)
|
||||
else:
|
||||
print("Setting Up supervisor...")
|
||||
update_supervisord_config(user=user)
|
||||
check_supervisord_config(user=user)
|
||||
generate_supervisor_config(bench_path=bench_path, user=user, yes=yes)
|
||||
|
||||
print("Setting Up NGINX...")
|
||||
|
@ -79,7 +79,7 @@ def get_supervisord_conf():
|
||||
return possibility
|
||||
|
||||
|
||||
def update_supervisord_config(user=None):
|
||||
def check_supervisord_config(user=None):
|
||||
"""From bench v5.x, we're moving to supervisor running as user"""
|
||||
# i don't think bench should be responsible for this but we're way past this now...
|
||||
# removed updating supervisord conf & reload in Aug 2022 - gavin@frappe.io
|
||||
|
Loading…
Reference in New Issue
Block a user