mirror of
https://github.com/zulip/zulip.git
synced 2025-10-23 04:52:12 +00:00
[manual] Switch over to new /etc/zulip/zulip.conf config file
Run the following commands as root before deploying this branch: # /root/zulip/tools/migrate-server-config # rm /etc/zulip/machinetype /etc/zulip/server /etc/zulip/local /etc/humbug-machinetype /etc/humbug-server /etc/humbug-local (imported from commit aa7dcc50d2f4792ce33834f14761e76512fca252)
This commit is contained in:
@@ -15,11 +15,9 @@ logging.basicConfig(format="%(asctime)s restart-server: %(message)s",
|
||||
deploy_path = os.path.realpath(os.path.join(os.path.dirname(__file__), '..'))
|
||||
os.chdir(deploy_path)
|
||||
|
||||
if os.path.exists("/etc/zulip/server"):
|
||||
with open("/etc/zulip/machinetype") as mtf:
|
||||
if pwd.getpwuid(os.getuid())[0] != "zulip":
|
||||
logging.error("Must be run as user 'zulip'.")
|
||||
sys.exit(1)
|
||||
if pwd.getpwuid(os.getuid())[0] != "zulip":
|
||||
logging.error("Must be run as user 'zulip'.")
|
||||
sys.exit(1)
|
||||
|
||||
# Send a statsd event on restarting the server
|
||||
subprocess.check_call(["python", "./manage.py", "send_stats", "incr", "events.server_restart", str(int(time.time()))])
|
||||
|
Reference in New Issue
Block a user