1. install.sh
yum install wget -y rm -rf /usr/local/python3/ mkdir /wget mkdir /code/byb/venv -p mkdir /code/byb/src wget https://www.python.org/ftp/python/3.6.5/Python-3.6.5.tar.xz -O /wget/python3.tar.xz tar -xvf /wget/python3.tar.xz -C /wget cd /wget/Python-3.6.5/ mkdir /usr/local/python3 ./configure --prefix=/usr/local/python3/ make make install rm -rf /usr/bin/python3 ln -s /usr/local/python3/bin/python3 /usr/bin/python3 pip install virtualenv virtualenv /code/byb/venv --no-site-packages -p /usr/bin/python3 source /code/byb/venv/bin/activate pip install sqlalchemy wget https://github.com/yugengde/tools/blob/Linux_centos/Twisted-17.9.0.tar.bz2?raw=true --no-check-certificate -O /wget/twisted.tar.bz2 tar -xjf /wget/twisted.tar.bz2 -C /wget/ cd /wget/Twisted-17.9.0/ python setup.py install pip install scrapy pip install pysqlite3 pip install pymongo cd -
2 control.sh
scp install.sh c4:/ ssh c4 "cd /root/; nohub /bin/sh /install.sh &"