Dear all,
I have installed scout on a local server to try it out for a class lab. I have gotten as far as I running it successfully through the demo or using the flask example. However, the command for running it with gunicorn does not seem to work. I get this error:
ModuleNotFoundError: No module named 'wsgi_gunicorn'
[... lots of Python messages ...]
I can not find the documented wsgi_gunicorn.py file anywhere among the files I checked out with git. Is it missing or am I doing something wrong?
In terms of production runs, do you continue using the docker mongodb instance? If so, how do you set up authentication on it?
Hi @andreaswallberg , nice that you're trying out Scout!
Our current setup here at SciLifeLab Solna is not with Docker (for either Scout or the mongo database), but @ninanorgren managed a setup with Docker and LDAP authentication in a prod environment, she can give you some tips perhaps?
We are using Google authentication for our users at the moment, but we might be switching to a new system (LDAP as well?) in the future.
Regarding the gunicorn file, you are right, it's not included in the current repository, and I couldn't find any reference to a file named like that in the past.. We'll need to fix the documentation, sorry!
I think what is supposed to be in the missing file is in scout/scout/server/auto.py. What happens if you try to run
/path/to/gunicorn
--workers=4 # for production, 2 for staging
--bind=":8080" # port to listen on localhost
--access-logfile=- # redirect access log to STDOUT
--error-logfile=- # redirect errors to STDOUT
scout.server.auto:app
?
Cool! We do have a locally adapted production config in our internal server repo; let's see if we can't edit that to be a bit more generic and add to this as well!
Thanks for the very rapid feedback!
This works for me:
SCOUT_CONFIG=./scoutconfig.py gunicorn --workers=4 --bind=":8080" --access-logfile=- --error-logfile=- scout.server.auto:app and it starts without error and stays up!I can not actually check out the web server from where I am located atm but will do so asap later this evening.
It works. I also got it up and running with my own key and certificate. Great!
Most helpful comment
It works. I also got it up and running with my own key and certificate. Great!