mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-05-27 10:44:33 +00:00
ttrss: Make setup process reusable
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
parent
2f0bc29239
commit
0dea9e80f3
@ -81,9 +81,7 @@ def subcommand_setup(_):
|
|||||||
|
|
||||||
aug.save()
|
aug.save()
|
||||||
|
|
||||||
action_utils.service_restart('tt-rss')
|
action_utils.service_try_restart('tt-rss')
|
||||||
action_utils.webserver_enable('tt-rss-plinth')
|
|
||||||
enable_api_access()
|
|
||||||
|
|
||||||
|
|
||||||
def enable_api_access():
|
def enable_api_access():
|
||||||
@ -117,6 +115,7 @@ def subcommand_enable(_):
|
|||||||
"""Enable web configuration and reload."""
|
"""Enable web configuration and reload."""
|
||||||
action_utils.service_enable('tt-rss')
|
action_utils.service_enable('tt-rss')
|
||||||
action_utils.webserver_enable('tt-rss-plinth')
|
action_utils.webserver_enable('tt-rss-plinth')
|
||||||
|
enable_api_access()
|
||||||
|
|
||||||
|
|
||||||
def subcommand_disable(_):
|
def subcommand_disable(_):
|
||||||
|
|||||||
@ -88,6 +88,7 @@ def setup(helper, old_version=None):
|
|||||||
helper.call('pre', actions.superuser_run, 'ttrss', ['pre-setup'])
|
helper.call('pre', actions.superuser_run, 'ttrss', ['pre-setup'])
|
||||||
helper.install(managed_packages)
|
helper.install(managed_packages)
|
||||||
helper.call('post', actions.superuser_run, 'ttrss', ['setup'])
|
helper.call('post', actions.superuser_run, 'ttrss', ['setup'])
|
||||||
|
helper.call('post', actions.superuser_run, 'ttrss', ['enable'])
|
||||||
global service
|
global service
|
||||||
if service is None:
|
if service is None:
|
||||||
service = service_module.Service(managed_services[0], name, ports=[
|
service = service_module.Service(managed_services[0], name, ports=[
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user