#!/bin/sh
#http://morning.work/page/2015-12/install-shadowsocks-on-centos-7.html
yum update -y
curl "https://bootstrap.pypa.io/get-pip.py" -o "get-pip.py"
python ./get-pip.py
pip install --upgrade pip
pip install shadowsocks
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" "http://download.oracle.com/otn-pub/java/jdk/8u121-b13/e9e7ea248e2c4826b92b3f075a80e441/jdk-8u121-linux-x64.tar.gz"
echo 'unpacking jdk...'
tar xzf ./jdk*.tar.gz
wget http://apache.mesi.com.ar/tomcat/tomcat-9/v9.0.0.M17/bin/apache-tomcat-9.0.0.M17.tar.gz
echo 'unpacking tomcat...'
tar xzf apache-tomcat-9.0.0.M17.tar.gz
wget https://www.kyrray.tech/s.sh
wget https://www.kyrray.tech/ss.json
#!/bin/sh
#http://morning.work/page/2015-12/install-shadowsocks-on-centos-7.html
export LC_ALL=C
apt-get update -y
apt-get upgrade -y
apt-get install python-pip -y
pip install setuptools
pip install --upgrade pip
pip install shadowsocks
wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" "http://download.oracle.com/otn-pub/java/jdk/8u121-b13/e9e7ea248e2c4826b92b3f075a80e441/jdk-8u121-linux-x64.tar.gz"
echo 'unpacking jdk...'
tar xzf ./jdk*.tar.gz
wget http://apache.mesi.com.ar/tomcat/tomcat-9/v9.0.0.M17/bin/apache-tomcat-9.0.0.M17.tar.gz
echo 'unpacking tomcat...'
tar xzf apache-tomcat-9.0.0.M17.tar.gz
wget https://www.kyrray.tech/s.sh
wget https://www.kyrray.tech/ss.json
#!/bin/sh
apt-get update -y
apt-get upgrade -y
wget https://swift.org/builds/swift-3.0.2-release/ubuntu1604/swift-3.0.2-RELEASE/swift-3.0.2-RELEASE-ubuntu16.04.tar.gz
tar xzf swift-3.0.2-RELEASE-ubuntu16.04.tar.gz
apt-get install clang libicu-dev -y
wget -q -O - https://swift.org/keys/all-keys.asc | gpg --import -
gpg --keyserver hkp://pool.sks-keyservers.net --refresh-keys Swift
gpg --verify swift-3.0.2-RELEASE-ubuntu16.04.tar.gz.sig
apt-get install python2.7-dev libcurl3 -y
apt-get install openssl libssl-dev
sudo apt-get install libcurl4-openssl-dev -y
将swift中的bin目录添加到PATH即可使用.
export PATH="$PATH:/root/swift302/usr/bin"
source ~/.bashrc
swift --version
{
"server":"0.0.0.0",
"port_password": {
"26":"showgp123456",
"25":"showgp123456",
"27567":"showgp123456"
},
"local_address": "127.0.0.1",
"local_port":1080,
"timeout":300,
"method":"aes-256-cfb",
"fast_open": false
}
关于 apt-get 升级时候卡在 security 的解决办法:
/etc/gai.conf
的# precedence ::ffff:0:0/96 100 注释取消掉.
脚手架起始模板
swift package init
从package生成工程:
swift package init --type executable
//加入Kitura
swift build
swift package generate-xcodeproj
树莓派首次写入系统, 要开启 ssh, 只需要在 boot 分区放置一个文件名为 ssh 的文件即可.
默认用户名是 pi, 密码是 raspberry