Skip to content

Commit

Permalink
Make redis available before we deploy modoboa
Browse files Browse the repository at this point in the history
  • Loading branch information
tonioo committed Jan 12, 2024
1 parent e7995ad commit 715a5e3
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions modoboa_installer/scripts/modoboa.py
Original file line number Diff line number Diff line change
Expand Up @@ -303,16 +303,18 @@ def apply_settings(self):

def post_run(self):
"""Additional tasks."""
if 'centos' in utils.dist_name():
system.enable_and_start_service("redis")
else:
system.enable_and_start_service("redis-server")
self._deploy_instance()
if not self.upgrade:
self.apply_settings()

if 'centos' in utils.dist_name():
supervisor = "supervisord"
system.enable_and_start_service("redis")
else:
supervisor = "supervisor"
system.enable_and_start_service("redis-server")
# Restart supervisor
system.enable_service(supervisor)
utils.exec_cmd("service {} stop".format(supervisor))
Expand Down

0 comments on commit 715a5e3

Please sign in to comment.