Django、Gunicorn、Nginx、CloudFlare踩坑
Gunicorn 是python wsgi 網關server,Nginx會把收到的請求轉發到Gunicorn上,然後靜態資源Nginx直接處理
坑一、
Centos Nginx 不是使用site-avaiable方式處理
/etc/nginx/conf.d/ 直接把要弄的設定檔放在該目錄,demo.com.conf
sudo service nginx restart
坑二、
CloudFlare 只開放特定port 所以,自定義的port 從外面是訪問不到的,沒注意你就會往其他方面找
Which ports will Cloudflare work with?
Cloudflare can only proxy traffic going over the HTTP/HTTPS ports listed below. If your traffic is on a different port…support.cloudflare.com
Cloudflare can only proxy traffic going over the HTTP/HTTPS ports listed below. If your traffic is on a different port…support.cloudflare.com
待續….