转载请注明出处: http://qiudeqing.com/tools/2017/04/10/ubuntu.html

ssh禁止密码登录

添加好public key之后禁止密码登录服务器可以增加系统安全性.

sudo vim /etc/ssh/sshd_config

去掉PasswordAuthentication前面的#并设置值为no

PasswordAuthentication no

重启SSH daemon

``` sudo systemctl reload sshd ``

更新nodejs

sudo apt-get install curl

UPDATE Node.js v7:

curl -sL https://deb.nodesource.com/setup_7.x | sudo -E bash -
sudo apt-get install -y nodejs

参考: http://stackoverflow.com/questions/34974535/install-latest-nodejs-version-in-ubuntu-14-04

安装yarn

配置仓库:

curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list

安装:

sudo apt-get update && sudo apt-get install yarn

参考资料