curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash
nvm install --lts
npm config set registry https://registry.npmmirror.com
npm install -g yarn
yarn config set registry https://registry.npmmirror.com
sudo apt-get update
sudo apt-get install -y git
git config --global user.name "xxname"
git config --global user.email "xx.email.com"
git config --global --list
ssh-keygen -t rsa -C "xx.email.com"
Host git.soejh.com
HostName git.soejh.com
IdentityFile ~/.ssh/id_rsa_xx
cd /home/ubuntu/data/code
git clone git@git.xx.git
cd app1
yarn
yarn build
yarn start
npm install -g pm2
cd /home/ubuntu/data/code/app1
pm2 start ecosystem.config.js
pm2 ls
pm2 restart app1
pm2 stop app1
pm2 delete app1
pm2 logs app1
pm2 save