deeping linux下安装配置nginx+django
python3.6-venv python3.6-doc binfmt-support
编译安装python3.6.3
解压
tar -xvzf Python-3.6.3.tgz
配置
./configure --with-ssl --enable-optimizations --prefix=/usr/local/python36
编译和安装
make
make install
1.安装nginx
apt-get install -y nginx-full
启动nginx
service nginx start
service nginx restart
安装python3虚拟环境
sudo pip3 install virtualenv
pip下载慢
Linux下,修改 ~/.pip/pip.conf (没有就创建一个文件夹及文件。文件夹要加“.”,表示是隐藏文件夹)
内容如下:
[global] index-url = https://pypi.tuna.tsinghua.edu.cn/simple
[install] trusted-host=mirrors.aliyun.com
建立python虚拟环境
virtualenv --no-site-packages myweb
运行虚拟环境
source myweb/bin/activate
查看安装包
pip list
安装和源环境一样的包
pip install -r requirements.txt