[Flask] Deploying as a Windows service

CCP Dragonedge ccp at drsb.com.my
Sun Aug 5 08:31:32 EDT 2018


Hi,

I am deploying my Flask application on Apache24 using mod_wsgi 4.5.4
running on a Windows 7 machine. I have encountered something strange - when
I start and stop Apache manually (i.e. by typing httpd.exe from the command
line to start, and just hitting ctrl-C to stop), everything works fine.

When I, however, install Apache as a Windows service (by doing a "httpd -k
install"; so it starts up when the machine is booted), I get a "500
internal server error" when I try to access my Flask application.

According to the error logs, Flask can't see my modules. I know it's
something to do with Apache because when I just run the Flask server
("python myapp.py"), I have no problems.

Anyone experience this? If so, how did you overcome this? And I hope this
isn't off-topic - if it is, sorry and please point me to the right place.

Thanks,
p
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/flask/attachments/20180805/ef8b12a4/attachment.html>


More information about the Flask mailing list