I will check these in the morning. Thank you for all the help.
On Monday, October 29, 2018 at 5:48:39 PM UTC-7, Graham Dumpleton wrote:
>
> You don't need to chmod +x the WSGI script file.
>
> Ensure you still have:
>
> from mywebtool import app as application
>
> in the WSGi script file.
>
>
Nothing should be cached from old version of file, but to be safe I would
suggest stopping and starting Apache, trying again and seeing what error you
get.
Also see comments below.
> On 30 Oct 2018, at 11:36 am, wc wrote:
>
> mywebtool.wsgi is indeed in the location you noted
>
> my virtual
mywebtool.wsgi is indeed in the location you noted
my virtual host section (showing the WSGIScriptAlias) is:
ServerName my.server.edu
DocumentRoot /var/www/FLASKAPPS
Require all granted
WSGIScriptAlias / /var/www/wsgi-scripts/mywebtool.wsgi
Where is 'mywebtool.wsgi'.
The error suggests:
/var/www/wsgi-scripts/mywebtool.wsgi
yet, the error also says:
[Mon Oct 29 15:55:30.446084 2018] [wsgi:error] [pid 20476] [client
60.248.94.241:50359] File "/var/www/wsgi-scripts/mywebtool.wsgi", line 1, in
[Mon Oct 29 15:55:30.446150
I believe I understand what you mean for the package vs. module structure.
I get:
$ ls -las /var/www/FLASKAPPS
total 6
1 drwxr-xr-x 2 root wheel3 Oct 23 17:39 .
1 drwxr-xr-x 4 root wheel4 Oct 23 18:10 ..
5 -rw-r--r-- 1 wes wes148 Oct 23 17:33 mywebtool.py
When I do the ls
> On 30 Oct 2018, at 11:16 am, wc wrote:
>
> Yes, my "mywebtool" is under
>
> /var/www/FLASKAPPS
>
> I'm assuming that Apache is running as user www, though I should check that
> and check the permissions on the file. As I recall, I uploaded the files as
> root because I was unable to
Yes, my "mywebtool" is under
/var/www/FLASKAPPS
I'm assuming that Apache is running as user www, though I should check that
and check the permissions on the file. As I recall, I uploaded the files as
root because I was unable to modify the directory /var/www as myself from
my ftp prog.
I
Is your mywebtool module/package under:
/var/www/FLASKAPPS
or:
/var/www/wsgi-scripts
Are the directories/files readable to the user that Apache runs as?
Is mod_wsgi compiled for Python 2.7 or 3.X?
If mywebtool is a package, does it have an __init__.py file in it.
Graham
> On 30 Oct
Thank you both for your replies. I now have a better understanding of the
wsgi framework and I am using the error log to my advantage. I was able to
find an error in my httpd.conf - I was using Apache 2.2 syntax in my
directives, now I've updated it with the "Require all granted" and I am
I'd agree on that except as noted.
If the error message from the Apache error log is shown, along with
configuration for your WSGI application in Apache config, as well as saying
where your Python application code is located, that would help to give better
idea of what is going on.
> On 30
403 usually means that the directory to which you are hosting the .wsgi
isn't configured with:
AllowOverride None
Require all granted
This is required even though you have configured WSGIScriptAlias
/web/path/to/app /path/to/your/app.wsgi
On Monday, October 29, 2018 at 6:52:29 PM
Hello,
My colleague would like to get a Python Flask app running on our new sever.
I've been scratching my head for several days and doing lots of googling to
help me get just a simple hello world wsgi app to run on my FreeBSD 11.2
server. I've followed some online tutorials to make a .py
12 matches
Mail list logo