GoSkeleton is a structured and scalable Go project template with built-in support for gRPC, HTTP, Swagger, telemetry, circuit breakers, rate limiting, and export utilities. It provides a clean foundation for developing production-ready applications.
- gRPC & HTTP Support β Fully integrated gRPC and RESTful HTTP APIs.
- Swagger API Documentation β Automatically generated API docs with Swagger UI.
- Telemetry (Tracing & Metrics) β OpenTelemetry support for monitoring and observability.
- Circuit Breaker β Built-in resilience patterns to handle failures gracefully.
- Rate Limiting β Prevents abuse with request throttling mechanisms.
- Export Utilities β Includes Makefile commands for running and managing the application.
- Docker Support β Easily deployable using
docker-compose
. - Security & Code Quality β Integrated linters and security scanners.
- Go 1.16+
buf
(for Protocol Buffers)- Docker (for containerized deployments)
- Make (for running commands efficiently)
-
Clone the repository
git clone https://github.com/tolgaOzen/go-skeleton.git cd go-skeleton
-
Install dependencies
go mod tidy
-
Run the application
go run cmd/skeleton/skeleton.go
-
Run with Docker
docker-compose up --build
go-skeleton/
βββ cmd/skeleton # Main application entry point
βββ config # Configuration files
βββ internal # Private application logic and business rules
βββ pkg # Reusable utilities and helpers
βββ proto # gRPC Protocol Buffers definitions
βββ docs # Swagger documentation & OpenAPI specs
βββ tools # Developer tools (linting, security scans, etc.)
βββ Makefile # Helpful automation commands
Swagger UI is available at:
http://localhost:8080/swagger/index.html
- Tracing β OpenTelemetry integration for distributed tracing.
- Metrics β Prometheus-compatible metrics for monitoring.
GoSkeleton includes export utilities via Makefile to streamline development.
make help
Command | Description |
---|---|
make build |
Build the Go application |
make format |
Format code using gofumpt |
make lint-all |
Run all linters (golangci-lint , hadolint ) |
make security-scan |
Scan for security vulnerabilities using gosec |
make coverage |
Generate global code coverage report |
make clean |
Remove temporary and generated files |
make release |
Prepare for release (format, scan, clean) |
make serve |
Run the compiled Go application |
make compose-up |
Start the application using docker-compose |
make compose-down |
Stop all docker-compose services |
This project is licensed under the MIT License. See the LICENSE file for details.
For more details, visit the GoSkeleton GitHub repository.