# node-restful **Repository Path**: jellyfish/node-restful ## Basic Information - **Project Name**: node-restful - **Description**: my study node restful template - **Primary Language**: NodeJS - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2016-12-10 - **Last Updated**: 2021-11-03 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # node-restful use nodejs make easy restful service example. -------------------------------------------------------------------------------- 构建image: docker build -t node/restful:0.1 . 运行这个image, 但肯定会运行失败, 因为还没有mongodb 服务 docker run -d --name node-restful -p 8888:8888 -v 'pwd:/home/service/node-restful' node/restful:0.1 运行mongodb服务: docker run -v $(pwd)/db:/data -p 27017:27017 --name mongo -d mongo mongo docker run -d -p 27017:27017 --name mongo -v $(pwd)/db:/data mongo // 进入mongo的bash docker exec -it mongo bash 运行node的服务, 并连接mongodb: docker run -d --name node -v "$(pwd)":/data --link mongo:mongo -w /data -p 8888:8888 node/restful:0.1