Swift Server

Swift Ubuntu上配置运行环境

2018-01-18  本文已影响153人  OneByte

1.购买Ubuntu

vultr上有活动,绑定信用卡有送$10美元,并且vps价格低(最低$2.5一个月)、性价比高:

服务器区域.png
价格.png

2.配置Swift环境

获取地址.png

右键->获取链接地址
wget https://swift.org/builds/swift-4.0.3-release/ubuntu1604/swift-4.0.3-RELEASE/swift-4.0.3-RELEASE-ubuntu16.04.tar.gz

sudo tar xzf swift-4.0.3-RELEASE-ubuntu16.04.tar.gz

sudo apt-get install clang

echo "export PATH=~/swift-4.0.3-RELEASE-ubuntu16.04/usr/bin:"${PATH}"" >> ~/.profile
source ~/.profile

1.$ swift --version
输出:
$Swift version 4.0.3 (swift-4.0.3-RELEASE)
Target: x86_64-unknown-linux-gnu
2.$ swift

3.错误提示修复

sudo apt-get install libcurl

sudo apt-get install libpython2.7

上一篇下一篇

猜你喜欢

热点阅读