hongy19’s blog
pip proxy bug
I have a company laptop which is behind a company HTTP proxy. It takes me lots of time to study how to use proxy for pip. At beginning, I tried “pip search –proxy xxx.xxx.xx.xx:xxxx matplotlib”, but it doesn’t work. Then I searched internet and found there are some bugs in pip proxy, like link,NTLM proxy issue. I even tried to use privoxy to convert socket5 proxy from ssh to HTTP to fix them, but it still doesn’t work.
…Nginx + fastcgi/wsgi
Python web application normally should use wsgi as interface, but nginx only support fascgi, scgi,uwsgi and no wsgi support.
flup is python library which could convert your wsgi application into fastcgi server. Since it is a library, you don’t need to setup other extra standalone application. flup could hep to set up fastcgi through Unix socket domain or TCP port. It is also support scgi. webpy could use flup directly.
app = web.application(urls,locals())
https build with nginx + startssl
startssl provide free ssl certification. I have updated my website with https connection.
first step is to apply a ssl certifciation on startsll. Please notice there is no username/passwd to login startsll website instead of certification on your browser which is installed by startssl. second is to follow website to fill personal information, validation your email and produce private key. private key (ssl.key) is not stored in startsll server, but it will download to your computer. Then you need to wait for sometimes to fetch public key (ssl.crt) and retrieve it from “Retrieve Certificate” in Toolbox.
…