uwsgi 的http访问修改成https的访问报错 The -s/--socket option is missing and stdin is not a socket.

uwsgi之前是使用http,后来项目需要使用https认证

安装uwsgi文档 修改

1:需要使用openssl生成 crt和key文件,切记最后一条命令,不是csr文件是crt文件

openssl genrsa -out foobar.key 2048
openssl req -new -key foobar.key -out foobar.csr
openssl x509 -req -days 365 -in foobar.csr -signkey foobar.key -out foobar.crt 
2:ini文件中配置

https = :8443,foobar.crt,foobar.key

 

之前一直The -s/--socket option is missing and stdin is not a socket.

后来重新编译后,配置文件使用crt文件,之前是csr文件

python   uwsgiconfig.py --build

 

posted @ 2018-04-08 14:20  any小鱼  阅读(2172)  评论(0编辑  收藏  举报