Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ai
autoca
Commits
f01868f7
Commit
f01868f7
authored
Jan 15, 2012
by
ale
Browse files
allow a caller to pass settings to make_app()
parent
64ffd1af
Changes
1
Hide whitespace changes
Inline
Side-by-side
autoca/ca_app.py
View file @
f01868f7
...
...
@@ -92,9 +92,11 @@ def sign():
return
crypto
.
dump_certificate
(
crypto
.
FILETYPE_PEM
,
signed_cert
)
def
make_app
(
ca_instance
):
def
make_app
(
ca_instance
,
settings
=
{}
):
app
=
Flask
(
__name__
)
app
.
register_blueprint
(
ca_app
)
if
settings
:
app
.
config
.
update
(
settings
)
app
.
config
.
from_envvar
(
'CA_APP_SETTINGS'
,
silent
=
True
)
app
.
ca
=
ca_instance
return
app
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment