Skip to content

TheKankan/Bloggy

Repository files navigation

CI

Bloggy

A REST API and web interface for a blog platform, built in Go. Users can register, write articles and comment on each other's posts.

Features

  • 🔐 Authentication with hashed passwords (argon2id) and JWT tokens
  • 📝 Full CRUD for articles and comments
  • 🛡️ Route protection with auth middleware
  • 🌐 Web interface served with Go templates

Quick Start (Docker)

Prerequisites

Running

  1. Clone the repo
git clone https://github.com/TheKankan/Terminal_Chat.git
  1. Edit .env.example : rename it .env and change the values inside it

  2. Start the server and database

docker compose up

The server is now running on http://localhost:8080 !

Manual Setup (without Docker)

Prerequisites

  • Go 1.25+
  • PostgreSQL
  • goose for migrations

Running

  1. Clone the repo
git clone https://github.com/TheKankan/Bloggy.git
  1. Edit .env with your PostgreSQL connection string and JWT_SECRET

  2. Run migrations

goose -dir sql/schema postgres "$DB_URL" up
  1. Start the server
go run ./cmd/server

The server is now running on http://localhost:8080 !

Tech Stack

  • Go — server and web templates
  • PostgreSQL — persistent storage
  • chi — HTTP router (go-chi/chi)
  • JWT — authentication (golang-jwt)
  • argon2id — password hashing (alexedwards/argon2id)
  • sqlc — type-safe SQL (sqlc)
  • goose — database migrations (pressly/goose)
  • Docker — containerization

Contributing

Clone the repo and set up your .env (see Quick Start above)

# Run tests
go test ./...

# Start the server
go run ./cmd/server

Open a pull request to the main branch to add new features or fix issues.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages