From 5cf3781ad4beddfab5aa7181c0990a5462ffe06f Mon Sep 17 00:00:00 2001 From: Lars Wirzenius Date: Wed, 7 Feb 2018 18:54:13 +0200 Subject: Change: make all .service units be conditional on config If the config file is missing, the unit won't start. --- ick_controller.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'ick_controller.py') diff --git a/ick_controller.py b/ick_controller.py index 85c0bca..a176351 100644 --- a/ick_controller.py +++ b/ick_controller.py @@ -1,5 +1,5 @@ #!/usr/bin/python3 -# Copyright (C) 2017 Lars Wirzenius +# Copyright (C) 2017-2018 Lars Wirzenius # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as published by @@ -46,6 +46,7 @@ default_config = { 'token-issuer': None, 'log': [], 'statedir': None, + 'blob-service': None, } @@ -93,7 +94,10 @@ def main(): state.set_state_directory(config['statedir']) api = ick2.ControllerAPI(state) - ick2.log.log('info', msg_text='created ControllerAPI') + api.set_blob_service_url(config['blob-service']) + ick2.log.log( + 'info', msg_text='created ControllerAPI', + blob_service=config['blob-service']) application = apifw.create_bottle_application( api, counter, dict_logger, config) -- cgit v1.2.1