Here is my NestJS pet project. It provides a platform for users to make/edit/remove and like posts. Additionally there is logic for admins and moderators to manage complaints or just mute and ban users.
- User authentication and authorization
- Create, read, update, and remove posts
- Create, read, remove complaints
- Liking system for posts
- User roles and permissions
- Moderation and administration tools
- Swagger documentation
- PostgreSQL as database
-
Clone the repository:
git clone https://github.com/Haguel/NestJS-Forum-Backend.git
-
Install dependencies
cd NestJS-Forum-Backend npm install -
Setup test.env file
PORT=3000 DB_HOST=localhost DB_PORT=5432 DB_PASSWORD=root DB_USERNAME=postgres DB_NAME=nest_forum_backend SALT_ROUNDS=6 JWT_SECRET=secret
-
Start the test server
npm run start:test
-
Run prepared seeder in order to get needed data to test (it creates needed roles and an admin)
npm run db:seed:test
Attention: Do not run seeder before the first initializtion of the app. Run the server first in order to init all the needed tables in the database