Skip to content

Commit

Permalink
add general ssl key name
Browse files Browse the repository at this point in the history
  • Loading branch information
Maria dErrico authored and mariaderrico committed Jun 2, 2023
1 parent d655def commit f4682f7
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions bfabric/scripts/bfabric_flask.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@
2017-05-11
2019-10-16 adapted to bfabric10
2022-02-04 adaptation to start flask by Debian's systemd
2023-05-08 use https if certified ssh keys are available
useful commands when using the debian package:
Expand Down Expand Up @@ -468,7 +470,7 @@ def add_workunit():
return jsonify({'rv': 'ok'})

if __name__ == '__main__':
if exists('/etc/ssl/fgcz-host.pem') and exists('/etc/ssl/private/fgcz-c-072_key.pem'):
app.run(debug=False, host="0.0.0.0", port=5001, ssl_context=('/etc/ssl/fgcz-host.pem', '/etc/ssl/private/fgcz-c-072_key.pem'))
if exists('/etc/ssl/fgcz-host.pem') and exists('/etc/ssl/private/fgcz-host_key.pem'):
app.run(debug=False, host="0.0.0.0", port=5001, ssl_context=('/etc/ssl/fgcz-host.pem', '/etc/ssl/private/fgcz-host_key.pem'))
else:
app.run(debug=False, host="127.0.0.1", port=5000)

0 comments on commit f4682f7

Please sign in to comment.