Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Protect Japonicus web UI with username+password? #185

Open
rcoenen opened this issue Jul 4, 2019 · 3 comments
Open

Protect Japonicus web UI with username+password? #185

rcoenen opened this issue Jul 4, 2019 · 3 comments

Comments

@rcoenen
Copy link

rcoenen commented Jul 4, 2019

Now that I have everything up & running on an EC2 instance:

I have the nice web interface running for Japonicus. Can this protected with a simple username / password (basic auth)

@Gab0
Copy link
Owner

Gab0 commented Jul 4, 2019

Flask should have some option for it, but I don't know...
Try to do a research and update the repo :3 If it's built in on Flask it should be simple.

@rcoenen
Copy link
Author

rcoenen commented Jul 4, 2019

Yeah I have been messing around with that for a few hours. I'm learning Flask, Dash, Python, etc here in real-time.
I guess I should try to hook in the basic auth in /japonicus/promoterz/webServer/core.py somewhere. Any pointers, code snippets?

@rcoenen
Copy link
Author

rcoenen commented Jul 4, 2019

Ok update: I have it working now. Turns out basic auth had to be added to the Dash app, not the Flaskh server (or in either case, this is how I got it to work)

  1. yes the file to modify is /japonicus/promoterz/webServer/core.py
  2. helpful example found here https://dash.plot.ly/authentication -- see Basic Auth Example

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants