- 🛣 Memory Motel API Documentation: memory-api.azurewebsites.net/docs
- 📘 NestJS Documentation: docs.nestjs.com
- 📘 MongoDB Documentation: docs.mongodb.com
- 📘 Mongoose Documentation: mongoosejs.com/docs
- 📘 TypeScript Documentation: typescriptlang.org/docs/
- 🚦 Git workflow Git flow cheatsheet
Plugins | Description | Version |
---|---|---|
@expressjs/multer | 🏞 Files middleware | |
sharp | 🏞 Cut images | |
passport-jwt | 🔑 JWT authentification | |
imagemin | 🏞 Minify images |
Memory Motel App : github.com/Hashs7/memory-app
Postman configuration : Memory motel.postman_collection.json
brew services start mongodb-community
mongo
use memorymotel
# copy env variables and fill with dev values
cp .env.example .env
# install dependencies
yarn install
- Refer to the documentation of memory-app to see full HTTPS configuration steps on the app.
- Copy the
cert.pem
andkey.pem
you generated in the/cert
folder of the app to the/cert
folder in the api.
# Populate categories
npx nestjs-command create:memory:categories
# development
yarn run start
# watch mode
yarn run start:dev
# production mode
yarn run start:prod
# see lint errors and warnings
yarn lint
# fix errors and warnings automatically
yarn lint --fix
# build for production and launch server
yarn build
yarn start
# generate static project
yarn generate
mongodump --host localhost:27017 -d {dbname} --out ./dump
mongodump --uri=mongodb+srv://{user}:{password}@{url}.mongodb.net/{dbname} --out ./dump-production
mongorestore ./dump-production --drop
mongorestore --uri=mongodb+srv://{user}:{password}@{url}.mongodb.net/{dbname} ./dump --drop
# init git flow
git flow init
# init git flow
git checkout develop
git flow feature start my-feature-name
git flow feature publish my-feature-name
git flow feature finish my-feature-name