linux环境

[python3]
1 ./configure –prefix=/usr/local/python3
2 make
3 make install
4 ln -s /usr/local/python3/bin/python3 /usr/bin/python3

make install error required PIP.
We could
yum -y install epel-release
yum install python-pip
yum -y install zlib*

When we used the pip3 to install some package that the install error is ssl balabalabla.
The python3 is not support the ssl because the security.
just like. import ssl is error;
So we should in the setup directory. vi Modules/Setup, and edit the file like:
“`
_socket socketmodule.c
Socket module helper for SSL support; you must comment out the other

_ssl _ssl.c \
-DUSE_SSL -I ( S S L ) / i n c l u d e I (SSL)/include/openssl \
-L$(SSL)/lib -lssl -lcrypto
“`
And then, we should setup the python3 again.
/configure –prefix=/usr/local/python3 —-with-ssl

When we do that again. We could use the pip3 install somepackes that we want;

[MariaDB]
1 start the service
systemctl start mariadb.service
2 start the service when turn on the compute
systemctl enable mariadb
3 init the SQL, set the init passwd
mysql_secure_installation
4 http://www.linuxidc.com/Linux/2016-03/128880.htm
5 passwd is admin123

[Mysql]
1. init the SQL passwd
/usr/bin/mysqladmin -u root password “xxxx”

[apache2]
1 yum install httpd
2 systemctl enable httpd

[firewall]
https://www.cnblogs.com/moxiaoan/p/5683743.html
1. firewall-cmd –zone=public –list-ports
2. add the port
<1> firewall-cmd –zone=public –add-port=80/tcp –permanent
<2> firewall-cmd –reload

[django]
When run the cmd “python manage.py startapp flexible” error. The info is
from _sqlite3 import *
ModuleNotFoundError: No module named ‘_sqlite3’

We should yum install sqlite-devel and then rebuild the python3

猜你喜欢

转载自blog.csdn.net/death_include/article/details/79922514