# photo-share-server **Repository Path**: ahcheng/photo-share-server ## Basic Information - **Project Name**: photo-share-server - **Description**: 摄影作品分享网站后端 - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2026-01-21 - **Last Updated**: 2026-02-08 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README
A modern NestJS backend application with authentication, WebSockets, scheduled tasks, and API documentation.
## Features - 🛡️ **Security**: JWT authentication, rate limiting, and Helmet for security headers - 📡 **Real-time**: Socket.IO for WebSocket communication - 📅 **Scheduling**: Built-in task scheduling - 📝 **API Docs**: Swagger/OpenAPI documentation - 📊 **Logging**: Winston with daily rotating logs - 🗃️ **Database**: Prisma ORM with PostgreSQL/MySQL support - ✅ **Validation**: Class-validator and class-transformer - 🧪 **Testing**: Jest testing framework with supertest ## Tech Stack ### Core Dependencies - NestJS 10 - Prisma 5 - TypeScript 5 - Socket.IO 4 - Passport.js (JWT & Local strategies) ### Development Tools - Jest for testing - ESLint + Prettier for code quality - Swagger for API documentation - Winston for logging ## Prerequisites - Node.js 18+ - npm/yarn/pnpm - Database (PostgreSQL/MySQL) - (Optional) Docker for containerization ## Installation ```bash # Clone the repository git clone https://gitee.com/ahcheng/nest-like-admin # Install dependencies pnpm install # Set up environment variables cp .env.example .env # Edit .env with your configuration # Generate Prisma client pnpx prisma generate # Run database migrations pnpx prisma migrate dev ``` ## Running the App ```bash # development $ pnpm run start # watch mode $ pnpm run start:dev # production mode $ pnpm run start:prod ``` ## API Documentation After starting the development server, access the Swagger UI at: `http://localhost:7001/api/v1/doc.html` ## Testing ```bash # Unit tests pnpm run test # E2E tests pnpm run test:e2e # Test coverage pnpm run test:cov ``` ## Database This project uses Prisma ORM. To interact with your database: ```bash # Open Prisma Studio pnpx prisma studio # Run migrations pnpx prisma migrate dev ``` ## Contributing Contributions are welcome! Please follow these steps: 1. Fork the repository 2. Create your feature branch (`git checkout -b feature/AmazingFeature`) 3. Commit your changes (`git commit -m 'Add some AmazingFeature'`) 4. Push to the branch (`git push origin feature/AmazingFeature`) 5. Open a Pull Request ## License [MIT licensed](LICENSE)