itchan

module
v0.4.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 11, 2026 License: MIT

README

Itchan Imageboard

Go CI PostgreSQL

A modern, high-performance imageboard built with Go. Designed for privacy-conscious communities with domain-based board access control.

Features

  • Boards, Threads & Messages with file attachments (images and video), markdown, and cross-thread replies
  • Authentication: JWT-based with cookie and Bearer token support, email confirmation, invite system
  • Access Control: Public boards readable without login; private boards restricted by email domain
  • Admin Tools: Board/thread/message moderation, user blacklist
  • Rate Limiting: Multi-tier (Nginx + per-IP + per-user)
  • Media Sanitization: EXIF/metadata stripping via ffmpeg
  • CSRF Protection, security headers, gzip, graceful shutdown

Quick Start

git clone https://github.com/itchan-dev/itchan.git
cd itchan
docker-compose up --build

# Frontend: http://localhost:8081
# API:      http://localhost:8080/v1

Production Deployment

chmod +x scripts/*.sh
./scripts/setup.sh yourdomain.com your-email@example.com
make deploy

See SETUP.md for the full guide.

Tech Stack

  • Backend: Go 1.24+ — REST API (Chi router, JWT auth)
  • Frontend: Go templates (html/template)
  • Database: PostgreSQL 17.6 with table partitioning and materialized views
  • Proxy: Nginx (TLS, HTTP/2, rate limiting)
  • Media: ffmpeg for sanitization
  • Monitoring: Prometheus + Grafana (optional)
  • Container: Docker & Docker Compose

Documentation

License

MIT — see LICENSE.

Directories

Path Synopsis
backend
cmd/itchan-api command
internal/storage/fs
in storage/localfs/localfs.go
in storage/localfs/localfs.go
internal/storage/pg
Package pg implements the storage layer for the application using a PostgreSQL database.
Package pg implements the storage layer for the application using a PostgreSQL database.
frontend
cmd/frontend command
shared
api
jwt
middleware/metrics
Package metrics provides Prometheus HTTP metrics middleware.
Package metrics provides Prometheus HTTP metrics middleware.
storage/pg
Package pg provides core PostgreSQL database primitives for storage layers.
Package pg provides core PostgreSQL database primitives for storage layers.
tools

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL