Try it out: https://www.fertit.com
A Go-based web application for sending newsletters and allowing subscribers to manage their preferences. Designed for ease of deployment (Docker-ready), with a modern web UI and admin dashboard.
- Admin dashboard: Login, manage subscribers, and send newsletters.
- Subscriber portal: Signup, manage email preferences, and unsubscribe.
- Rate limiting: Prevents abuse of subscription endpoints.
- JWT authentication: Secure admin session management.
- SMTP integration: Send emails using your SMTP provider.
- PostgreSQL: Stores subscriber and newsletter data.
- Redis: Used for rate limiting and caching.
- Responsive UI: HTML templates for dashboard, login, preferences, and success messages.
- Backend: Go (Gin web framework)
- Database: PostgreSQL
- Cache/Queue: Redis
- Frontend: HTML templates (Go's html/template)
- Containerization: Docker, Docker Compose
Fertit/
├── cmd/server/main.go # Application entry point
├── internal/handlers/ # Route handlers (admin, subscriber, static)
├── internal/services/ # Business logic (auth, email, subscriber, rate limiting)
├── internal/database/ # Database and Redis connection logic
├── web/templates/ # HTML templates (dashboard, login, preferences, etc.)
├── Dockerfile # Multi-stage build for Go app
├── docker-compose.yml # Compose file for app, PostgreSQL, Redis
├── .env.example # Example environment variables
└── ...
git clone https://github.com/rasadov/Fertit.git
cd FertitCopy the example file and fill in your SMTP, DB, and other secrets:
cp .env.example .env
# Edit .env with your valuesThis will start the Go app, PostgreSQL, and Redis:
docker-compose up --build- App will be available at http://localhost:8080
- PostgreSQL at port 5433 (default user/pass from .env)
- Redis at port 6379
- Install Go 1.23+
- Set up PostgreSQL and Redis (see .env.example for config)
- Build and run:
go build -o fertit ./cmd/server
./fertit- Visit
/admin/loginto access the dashboard - Credentials set via
ADMIN_USERNAMEandADMIN_PASSWORDin.env - Send newsletters, manage subscribers
- Homepage: subscribe with email
/preferences: manage subscription topics or unsubscribe
See .env.example for all options. Key variables:
POSTGRES_URL— PostgreSQL connection stringREDIS_ADDR— Redis addressSMTP_HOST,SMTP_PORT,SMTP_USERNAME,SMTP_PASSWORD— SMTP settingsJWT_SECRET,JWT_ISSUER— JWT auth configADMIN_USERNAME,ADMIN_PASSWORD— Admin credentialsBASE_URL— Public URL of your app
MIT or see repository for details.
Feel free to open issues or PRs for improvements!