Hi,
I setup Web2py with Apache successfully, but when I setup a Nginx proxy for Apache server I get error :
-----------------------------------------------
<type 'exceptions.TypeError'>(getattr(): attribute name must be string)
Traceback (most recent call last):
File "C:\web2py\gluon\main.py", line 436, in wsgibase
session.connect(request, response)
File "C:\web2py\gluon\globals.py", line 960, in connect
session_pickled = pickle.dumps(self, pickle.HIGHEST_PROTOCOL)
File "C:\web2py\gluon\storage.py", line 56, in <lambda>
getnewargs = lambda self: getattr(dict,self).__getnewargs__(self)
TypeError: getattr(): attribute name must be string
-----------------------------------------------
Environment :
- Web2py 2.11.2
- Apache 2.2.25
- Nginx 1.0.15
Nginx proxy setting :
upstream qlkh {
ip_hash;
}
server {
listen 80;
location / {
if ($request_uri ~* ".(jpg|jpeg|gif|gz|zip|flv|rar|wmv|avi|css|swf|png|htc|ico|mpeg|mpg|txt|mp3|mov|js)(\?v=[0-9.]+)?$") {
expires 30d;
break;
}
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
add_header X-Cache-Status $upstream_cache_status;
}
}
Does anyone got this error? please help!
Thanks in advance!
Tuan.