https://github.com/tyronejosee/prototype_fiber
A modular and scalable e-commerce API built with Go, following Clean Architecture (Hexagonal) and Domain-Driven Design principles.
https://github.com/tyronejosee/prototype_fiber
api-rest clean-architecture ddd-architecture fiber fiber-framework go golang gorn postgresql redis swago
Last synced: about 2 months ago
JSON representation
A modular and scalable e-commerce API built with Go, following Clean Architecture (Hexagonal) and Domain-Driven Design principles.
- Host: GitHub
- URL: https://github.com/tyronejosee/prototype_fiber
- Owner: tyronejosee
- License: mit
- Created: 2025-06-25T22:31:23.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2025-06-25T22:35:47.000Z (12 months ago)
- Last Synced: 2025-06-25T23:27:46.436Z (12 months ago)
- Topics: api-rest, clean-architecture, ddd-architecture, fiber, fiber-framework, go, golang, gorn, postgresql, redis, swago
- Language: Go
- Homepage:
- Size: 0 Bytes
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
A modular and scalable e-commerce API built with Go, following Clean Architecture (Hexagonal) and Domain-Driven Design principles.
## ✨ Features
- **Clean Architecture**: Well-organized code with clear separation of concerns
- **Domain-Driven Design**: Business logic encapsulated in domain entities
- **RESTful API**: Comprehensive endpoints for e-commerce operations
- **Authentication & Authorization**: JWT-based auth with role-based access
- **Database Integration**: PostgreSQL with GORM ORM
- **Caching**: Redis for improved performance
- **Docker Support**: Easy deployment with Docker Compose
- **Unit Testing**: Comprehensive test coverage
- **API Documentation**: Well-documented endpoints
## 📋 Prerequisites
- Go 1.21+
- PostgreSQL 13+
- Redis 6+
- Docker & Docker Compose (optional)
## ⚙️ Installation
Clone the repository.
```bash
git clone git@github.com:tyronejosee/prototype_fiber.git
cd prototype_fiber
```
Copy the environment file.
```bash
cp .env.example .env
```
Update the `.env` file with your configuration.
```env
DB_HOST=
DB_PORT=
DB_USER=
DB_PASSWORD=
DB_NAME=
REDIS_HOST=
REDIS_PORT=
JWT_SECRET=
```
Start all services with Docker Compose.
```bash
make docker-up
```
Build and start with logs.
```bash
make docker-build
```
View logs.
```bash
make logs
```
Stop all services.
```bash
make docker-down
```
Start PostgreSQL and Redis services.
```bash
make deps
```
Run the application.
```bash
make run
```
Run tests.
```bash
make test
```
## 🌱 Contributing
1. Fork the repository
2. Create a feature branch, e.g. `feature/your-feature-name`
3. Implement your feature
4. Write tests for new functionality
5. Ensure all tests pass
6. Submit a pull request to the `main` branch
## ⚖️ License
This project is licensed under the [MIT License](/LICENSE).
Enjoy! 🎉