※ 조건

모델 : 라즈베리파이 B+

OS : Rasbian (stretch) 2017.11 Lite(Minimal)

Storage : MicroSD 8gb 10Class


쓸때없는 삽질 방지를 위해 글을 올림. 2014년에 샀지만 현재는 많은 부분이 업데이트 되어 고생 중.


[NodeJS]


■ 설치

apt-get install nodejs


■ 버전 확인

nodejs -v


■ 샘플코드


1
2
3
4
5
6
var http = require('http');
 
http.createServer(function (req, res) {
    res.writeHead(200, {'Content-Type''text/plain'});
    res.end('Hello World!');
}).listen(8080);
cs