심심풀이 개발

centos nodejs8 버전 설치

WebHack 2020. 4. 14. 16:10
$ yum install -y gcc-c++ make 	#의존성 패키지 설치
$ curl -sL https://rpm.nodesource.com/setup_8.x | sudo -E bash - # nodejs 최신버전 저장소 설치
$ curl -sL https://rpm.nodesource.com/setup_10.x | sudo -E bash
$ yum install nodejs -y
$ npm install yarn -g
$ npm install pm2 -g

후에 nodeapp 설치는

node_modules 디렉토리를 제외하고 복사

$ npm init
엔터~~
$ npm install​

$ pm2 start server.js --watch