The backend platform for Yancey Official Blog with Node.js, NestJS, MongoDB, GraphQL, JWT and more...
This library is part of the BEG (Blog Environment Group) ecosystem 📖
⭐️ Found it cool? Want more updates? Show your support by giving a ⭐️
In the project directory, you can run:
Builds the app for production to the dist
folder.
This script will delete the old dist
folder before build.
Runs the app in the development mode. Open http://localhost:3002 to view it in the browser. The page will reload if you make edits. You will also see any lint errors in the console.
Uses compodoc to generate an awesome document for this app.
Runs Jest via yarn test.
An optional way to use git cz
if you don't want to install commitizen
globally.
The main purpose of this repository is to continue to evolve BEG (Blog Environment Group), making it faster and easier to use. Development of Blog BE Next happens in the open on GitHub, and we are grateful to the community for contributing bugfixes and improvements. Read below to learn how you can take part in improving Blog BE Next.
BEG has adopted a Code of Conduct that we expect project participants to adhere to. Please read the full text so that you can understand what actions will and will not be tolerated.
Read our contributing guide to learn about our development process, how to propose bugfixes and improvements, and how to build and test your changes to Blog BE Next.
Please make sure to read the Issue Reporting Checklist before opening an issue. Issues not conforming to the guidelines may be closed immediately.
This app follows the Angular Team's Commit Message Guidelines, your commit will be checked by commitlint, please use git cz
instead of git commit
. For this reason, you should install commitizen
globally or use yarn commit
instead.
Rename env/.env.example
to 'production.env' and 'development.env' and save to the env
file folder. Then replace those environment variables with your own. Both DATABASE_USER
and DATABASE_PWD
are optional parameters in development.env
and test.env
file. Furthermore, NEED_SIMULATE_NETWORK_THROTTLE
is only taken efforts in the development environment.
NODE_ENV=<YOUR_NODE_ENV>
APP_PORT=<YOUR_APP_PORT>
DATABASE_HOST=<YOUR_DATABASE_HOST>
DATABASE_PORT=<YOUR_DATABASE_PORT>
DATABASE_USER=<YOUR_DATABASE_USER>
DATABASE_PWD=<YOUR_DATABASE_PWD>
DATABASE_COLLECTION=<YOUR_DATABASE_COLLECTION>
BANDWAGON_SECRET_KEY=<YOUR_BANDWAGON_SECRET_KEY>
BANDWAGON_SERVER_ID=<YOUR_BANDWAGON_SERVER_ID>
ALI_ACCESS_KEY_ID=<YOUR_ALI_ACCESS_KEY_ID>
ALI_ACCESS_KEY_SECRET=<YOUR_ALI_ACCESS_KEY_SECRET>
ALI_OSS_BUCKET=<YOUR_ALI_OSS_BUCKET>
ALI_SMS_SIGN_NAME=<YOUR_ALI_SMS_SIGN_NAME>
ALI_SMS_TEMPLATE_CODE=<YOUR_ALI_SMS_TEMPLATE_CODE>
IP_STACK_ACCESS_KEY=<YOUR_IP_STACK_ACCESS_KEY>
GOOGLE_RECAPTCHA_KEY=<YOUR_GOOGLE_RECAPTCHA_KEY>
JWT_SECRET_KEY=<YOUR_JWT_SECRET_KEY>
JWT_EXPIRES_TIME=<YOUR_JWT_EXPIRES_TIME>
# Only works in the development environment
NEED_SIMULATE_NETWORK_THROTTLE=<BOOLEAN>
We use e2e test for every module and test them at CI stage, you must write related test cases before PR.
The following are prehistoric changelogs on building infrastructure for this app. Just as a memorial. See the real detailed changes for each release are documented in the CHANGELOG.
-
2019-12-03 Integrates e2e test.
-
2019-11-26 Integrates JWT.
-
2019-11-07 Integrates dotenv.
-
2019-11-04 Integrates GraphQL.
-
2019-10-20 Integrates MongoDB and write the first RESTful CRUD.
-
2019-10-12 Initital repo.
-
Full text search for post
-
Vilidation schema optimization
-
Support forget password
-
Dockerize
Blog BE Next is under the MIT licensed. See the LICENSE file for the full license text.