https://www.mongodb.com/try/download/community
Try MongoDB Community Edition
Try MongoDB Community Edition on premise non-relational database including the Community Server and Community Kubernetes Operator for your next big project!
www.mongodb.com


๋ชฝ๊ณ DB ๋ค์ด๋ก๋

๋ค์ด๋ก๋ ํ์ผ ์คํํ๋ค.

Next->

Next->

complete ->

Next->

Next->

Install->


๋ค์ด๋ก๋ ๋๋ ๋์ mongoDB Shell๋ ๋ค์ด๋ก๋



์์ถ ํ๊ธฐ

mongosh.exeํ์ผ์ MongoDB๊ฐ ์ค์น๋ ํด๋์ bin์ ๋ถ์ฌ๋ฃ๋๋ค.


ํ์ฌ ํด๋์ ๊ฒฝ๋ก๋ฅผ ๋ณต์ฌํด์ ์์คํ ํ๊ฒฝ ๋ณ์ ํธ์ง์ path์ ์ถ๊ฐํด์ค๋ค.



์ถ๊ฐ๋๋์ง ํ์ธํ๋ค.
๋ช ๋ น ํ๋กฌํํธ์์ mongosh๋ฅผ ์ ๋ ฅํ๋ฉด mongodb์ค์น ํ์ธ์ด๋๋ค.

๋ฐฑ์ค๋ ์คํ -> ์๋์ ์์ถ ํ๊ธฐ

git bash๋ก ๋ ธ๋ ๋ชจ๋์ ์ค์นํ๋ค
$ npm install

์์ ํ๊ณ ์๋ fullstack ํด๋๋ก ์ฎ๊น
์๋ฐ์คํฌ๋ฆฝํธ ๋ฐฑ์ค๋๋ฅผ node js ๋ผ๊ณ ํจ

DATABASE ์ 27017 ํฌํธ๋ ์๊น ๋ช ๋ น ํ๋กฌํํธ์์ mongosh ์ ๋ ฅํ์๋ ๋์ค๋ ์ฃผ์์

์ฌ๊ธฐ์ myCart ํ ์ด๋ธ์ ๋ง๋ค์ด์ค๋ค.
๋ชฝ๊ณ DB๋ฅผ ์คํํด๋ณธ๋ค.




๋ชฝ๊ณ DB ์๋ก๊ณ ์นจํ๋ฉด myCart ํ ์ด๋ธ์ด ์์ฑ๋๊ฒ์ด ๋ณด์
( ํ์ด์ด๋ฒ ์ด์ค ์ฒ๋ผ Document ํ์์ db์ )


๋ฐฑ์๋๋ฅผ ๊ณ์ ์คํํ๋ ๋ช ๋ น์ด
$ node index.js

port ๋ฒํธ๋ 5000๋ฒ์
๊ตฌ๊ธ ๋ธ๋ผ์ฐ์ ์์ ํ์ธํด๋ดค๋ค.



์ด ๋ฐฑ์๋ ์๋ฒ๋ฅผ ๊ณ์ ์คํ์์ผ์ค์ผ ํ๋ก์ ํธ ๊ฐ๋ฅํจ
๋ฐฑ์๋ vscode๋ ๊บผ๋ ๋จ