第一步:
在腾讯云购买服务器
第二步:
在本机下载scrapyd-client:
对于windows系统,建议不要用pip install scrapyd-client去安装scrapyd-client,会出现,scrapyd-deploy不是内部或外部命令,因为scrapyd-deploy不能被windows执行。应当直接去github上下载并解压安装包后,进入解压后的目录下,执行python setup.py install进行安装。
python setup.py install
若已经用pip安装了的,先卸载Scrapyd-client
pip list
pip uninstall scrapyd-client
第三步:
1.登陆远端服务器里面进行相应的python和相关库安装
# 安装相关库
yum -y groupinstall "Development tools"
yum -y install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel gdbm-devel db4-devel libpcap-devel xz-devel
yum -y install gcc
# 下载python3.6安装包
wget https://www.python.org/ftp/python/3.6.8/Python-3.6.8.tgz
# 创建一个文件夹
mkdir /usr/local/python3.6
# 解压安装包
tar -zxvf Python-3.6.8.tgz
# 进入解压后的目录
cd Python-3.6.8
# 配置,使安装路径为/usr/local/python3.6
./configure --prefix=/usr/local/python3.6
# 编译,测试,安装
make
make test
make install
# 添加环境变量
PATH=$PATH:$HOME/bin:/usr/local/python3.6/bin
echo $PATH
# 备份原来python和pip链接
# 创建软连接,使python和pip指向python3.6和pip