本人脑袋不好使,做过的事情总会忘记,头一天搭建的环境,第二天怎么搭建的就都忘了,因此,自己又找了台机子 又搭建了一遍,并认真的做了记录,供以后查阅
环境:Centos 7 纯净
1、yum更新,安装当时能首先想到的对STF没直接影响的组件
yum unpdate
yum install wget
yum install -y unzip zip
yum install lrzsz
2、Java 1.8安装
跳走:https://www.cnblogs.com/stulzq/p/9286878.html
3、ADB相关安装:
a、SDK-tools安装(usr/local/android):
- wget https://dl.google.com/android/repository/sdk-tools-linux-3859397.zip
- unzip sdk-tools-linux-3859397.zip
- vi /etc/profile #环境变量配置
export PATH=$PATH:/usr/local/android/tools/bin
-
source /etc/profile #配置生效
- sdkmanager --list #sdk管理工具,查看已安装的东西(此时应该只有一个 tools内容)
- sdkmanager "platform-tools" # 安装ADB
- 继续使用sdkmanager --list 查看 应该是两个已经安装内容:
- adb校验:adb --version
4、node安装(版本:8.17.0 路径:usr/local/node)
- wget https://nodejs.org/dist/latest-v8.x/node-v8.17.0-linux-x64.tar.gz
- tar xvf node-v8.17.0-linux-x64.tar.gz
- 软链
ln -s /usr/local/node/node-v8.17.0-linux-x64/bin/node /usr/local/bin/node
ln -s /usr/local/node/node-v8.17.0-linux-x64/bin/npm /usr/local/bin/npm
4. 校验
5、rethinkdb安装(路径:/usr/dong)
1.wget http://download.rethinkdb.com/centos/7/`uname -m`/rethinkdb.repo -O /etc/yum.repos.d/rethinkdb.repo
2.yum install rethinkdb
3.rethinkdb -v
6、GraphicsMagick(版本:1.3.35 路径:/usr/dong)
1.wget ftp://ftp.graphicsmagick.org/pub/GraphicsMagick/1.3/GraphicsMagick-1.3.35.tar.gz
2.tar xvf GraphicsMagick-1.3.35.tar.gz
3.cd GraphicsMagick-1.3.35/
4.yum install -y gcc libpng libjpeg libpng-devel libjpeg-devel ghostscript libtiff libtiff-devel freetype freetype-devel
5../configure
6.make && make install
7、yasm(路径:/usr/dong)
1.wget http://www.tortall.net/projects/yasm/releases/yasm-1.3.0.tar.gz
2.tar xvf yasm-1.3.0.tar.gz
3.cd yasm-1.3.0/
4../configure
5.make && make install
8、libsoduim(/usr/dong)
cd /opt/dong
wget https://download.libsodium.org/libsodium/releases/libsodium-1.0.15.tar.gz
tar xvf libsodium-1.0.15.tar.gz
./configure
make make install
9、zeromq-4.1.4(/usr/dong)
1.wget https://github.com/zeromq/zeromq4-1/releases/download/v4.1.4/zeromq-4.1.4.tar.gz
2.tar xvf zeromq-4.1.4.tar.gz
3.cd zeromq-4.1.4 && ./configure --without-libsodium && make && make install
10、protobuf
cd /opt/dong
wget https://github.com/google/protobuf/releases/download/v3.5.0/protobuf-cpp-3.5.0.tar.gz
tar xvf protobuf-cpp-3.5.0.tar.gz
cd protobuf-3.5.0
./configure --prefix=/usr/local/protobuf
make make instal
环境变量:
export PATH=$PATH:/usr/local/protobuf/bin/
export PKG_CONFIG_PATH=/usr/local/protobuf/lib/pkgconfig/
11、pkg-config安装
cd /opt/dong
wget http://pkgconfig.freedesktop.org/releases/pkg-config-0.29.2.tar.gz
tar xvf pkg-config-0.29.2.tar.gz
cd pkg-config-0.29.2
./configure --prefix=/usr/local/pkg-config --with-internal-glib
make make install
12、python3安装
wget https://www.python.org/ftp/python/3.7.4/Python-3.7.4.tgz
tar -xzvf Python-3.7.4.tgz
cd Python-3.7.4/
./configure --prefix=/usr/local/python3.7
make && make install
pip3 find / -name pip3
yum install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel gcc make
ln -s /usr/local/python3.7/bin/python3.7 /usr/bin/python
ln -s /usr/local/python3.7/bin/python3.7 /usr/bin/python3
python -V
python3 -V
pip -V
pip3 -V
13、npm配置(很重要哦,不然npm install的时候会有权限问题,和资源问题)
npm config set prefix /usr/local
npm root -g
npm install -g gulp
npm install -g power
14、STF安装
源码:https://github.com/openstf/stf
解压路径,
npm install
bower install --allow-root
npm link
15、健康检查
stf路径/bin/stf doctor