Skip to content

golangkorea/bloGO

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

bloGO

A blog platform built with Go backend and frontend services using clean architecture principles.

Architecture

backend/
├── cmd/                    # Application entrypoints
├── internal/              # Private application code
│   ├── app/               # Application bootstrapping
│   ├── config/            # Configuration management
│   ├── errors/            # Custom error types
│   ├── handler/           # HTTP handlers
│   │   └── http/
│   │       ├── health/    # Health check endpoint
│   │       └── interface/ # Router interface
│   ├── repository/        # Data access layer (empty)
│   └── service/           # Business logic layer (empty)
├── pkg/                   # Public libraries
│   ├── database/          # Database utilities (empty)
│   └── logger/            # Logging utilities
└── vendor/                # Dependencies

frontend/                  # Frontend application (placeholder)

Features

  • Clean architecture with dependency injection
  • HTTP server with Echo framework
  • Graceful shutdown handling
  • Custom error handling with HTTP status codes
  • Configuration management with Viper
  • Docker Compose setup with PostgreSQL
  • Health check endpoint

Quick Start

Prerequisites

  • Go 1.23.6+
  • Docker & Docker Compose

Running with Docker

# Start all services
docker-compose up --build

# Access the health endpoint
curl http://localhost:5678/health

Running Locally

cd backend
go mod tidy
go run cmd/main.go

API Endpoints

  • GET /health - Health check endpoint

Configuration

Configuration is managed through config.toml files using Viper. Place your configuration file in the backend directory.

Development

The project uses clean architecture patterns:

  • Handler Layer: HTTP request handling
  • Service Layer: Business logic (to be implemented)
  • Repository Layer: Data persistence (to be implemented)
  • Error Layer: Centralized error handling
  • Config Layer: Application configuration

Contributing

This project is maintained by Golang Korea community.

License

MIT

About

Modern blog platform built with Go

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published