diff --git a/lemur/__init__.py b/lemur/__init__.py index 1cdb3468..769e0cec 100644 --- a/lemur/__init__.py +++ b/lemur/__init__.py @@ -62,8 +62,8 @@ LEMUR_BLUEPRINTS = ( ) -def create_app(config=None): - app = factory.create_app(app_name=__name__, blueprints=LEMUR_BLUEPRINTS, config=config) +def create_app(config_path=None): + app = factory.create_app(app_name=__name__, blueprints=LEMUR_BLUEPRINTS, config=config_path) configure_hook(app) return app diff --git a/lemur/manage.py b/lemur/manage.py index 184b9aa6..9161109b 100755 --- a/lemur/manage.py +++ b/lemur/manage.py @@ -50,7 +50,7 @@ from lemur.pending_certificates.models import PendingCertificate # noqa from lemur.dns_providers.models import DnsProvider # noqa manager = Manager(create_app) -manager.add_option('-c', '--config', dest='config') +manager.add_option('-c', '--config', dest='config_path', required=False) migrate = Migrate(create_app) @@ -391,7 +391,7 @@ class LemurServer(Command): # run startup tasks on an app like object validate_conf(current_app, REQUIRED_VARIABLES) - app.app_uri = 'lemur:create_app(config="{0}")'.format(current_app.config.get('CONFIG_PATH')) + app.app_uri = 'lemur:create_app(config_path="{0}")'.format(current_app.config.get('CONFIG_PATH')) return app.run() diff --git a/lemur/tests/conftest.py b/lemur/tests/conftest.py index b3dad8b2..43fa7163 100644 --- a/lemur/tests/conftest.py +++ b/lemur/tests/conftest.py @@ -43,7 +43,7 @@ def app(request): Creates a new Flask application for a test duration. Uses application factory `create_app`. """ - _app = create_app(os.path.dirname(os.path.realpath(__file__)) + '/conf.py') + _app = create_app(config_path=os.path.dirname(os.path.realpath(__file__)) + '/conf.py') ctx = _app.app_context() ctx.push()