From a8b5a32ff4c2d6afb7531c561e15c933c4717569 Mon Sep 17 00:00:00 2001 From: James Valleroy Date: Fri, 22 Jan 2021 19:33:45 -0500 Subject: [PATCH] setup: Enable essential apps that use firewall Tests in testing container: - SSH, Service Discovery, and Web Server are shown as enabled on Firewall page. - FreedomBox interface can be accessed after disabling Cockpit. Closes: #2016. Signed-off-by: James Valleroy Reviewed-by: Sunil Mohan Adapa --- plinth/modules/apache/__init__.py | 1 + plinth/modules/avahi/__init__.py | 1 + plinth/modules/ssh/__init__.py | 1 + 3 files changed, 3 insertions(+) diff --git a/plinth/modules/apache/__init__.py b/plinth/modules/apache/__init__.py index 114076c70..b093c5c59 100644 --- a/plinth/modules/apache/__init__.py +++ b/plinth/modules/apache/__init__.py @@ -66,6 +66,7 @@ def setup(helper, old_version=None): actions.superuser_run( 'apache', ['setup', '--old-version', str(old_version)]) + helper.call('post', app.enable) # (U)ser (W)eb (S)ites diff --git a/plinth/modules/avahi/__init__.py b/plinth/modules/avahi/__init__.py index 82931f1c8..076dfe8c5 100644 --- a/plinth/modules/avahi/__init__.py +++ b/plinth/modules/avahi/__init__.py @@ -98,6 +98,7 @@ def setup(helper, old_version=None): # available and require restart. helper.call('post', actions.superuser_run, 'service', ['reload', 'avahi-daemon']) + helper.call('post', app.enable) def on_post_hostname_change(sender, old_hostname, new_hostname, **kwargs): diff --git a/plinth/modules/ssh/__init__.py b/plinth/modules/ssh/__init__.py index 1281bfeb5..7010bb962 100644 --- a/plinth/modules/ssh/__init__.py +++ b/plinth/modules/ssh/__init__.py @@ -68,6 +68,7 @@ class SSHApp(app_module.App): def setup(helper, old_version=None): """Configure the module.""" actions.superuser_run('ssh', ['setup']) + helper.call('post', app.enable) def get_host_keys():