A high-performance web API built with Go Fiber framework.
- Go 1.24 or higher
- Make (for running Makefile commands)
- Clone the repository
git clone https://github.com/tinoimammp/imagyn_go.git
cd imagyn_go- Install dependencies using make command
make deps- Create a
.envfile in the root directory and fill it with your configuration settings using the values from.example.env.
cp .env.example .env- Run the application
make run- Build the application
make build- For database migration, we use
migrate(https://github.com/golang-migrate/migrate). Runmigratecommand:
migrate -path migrations -database "postgres://db_username:db_password@localhost:5432/db_name?sslmode=disable" upmake run- Run the applicationmake build- Build the applicationmake dev- Build and run the applicationmake test- Run testsmake clean- Clean build filesmake deps- Download and update dependencies
├── cmd/ # Entry point
│ └── main.go
├── internal/ # Business logic
│ ├── domain/ # Entity definitions (core business rules)
│ │ ├── example/
│ │ │ └── example.go # Domain model
│ │ │ └── repository.go # Repository interface
│ │ │ └── service.go # Domain service
│ │ │ └── value_objects.go # Value objects
│ │ └── .../
│ │ └── ...
│ ├── application/
│ │ └── example/
│ │ ├── usecases/
│ │ │ └── create.go
│ │ └── dto/
│ │ └── example_dto.go
│ ├── infrastructure/
│ │ └── config/ # Configuration related
│ │ ├── config.go
│ │ └── database.go
│ │ └── persistence/
│ │ └── postgres/
│ │ ├── provider.go # Configuration for Postgres
│ │ └── example_repository.go
│ └── interfaces/
│ └── http/
│ └── example_handler.go
├── migration/ # Migration files
│ ├── 001_create_examples.sql
│ └── ...
├── .env.example # Environment variables
├── go.mod
├── Makefile
└── README.md