Deploying Rybbit
Introduction
Rybbit is a privacy-focused, open-source web analytics platform that provides actionable insights without compromising visitor privacy. It offers an alternative to invasive tracking tools by collecting only essential metrics while respecting user privacy and GDPR compliance.
Key highlights of Rybbit:
- Privacy-First: No cookies, no personal data collection
- GDPR Compliant: Designed for privacy regulations compliance
- Lightweight Script: Minimal impact on page load times
- Real-Time Analytics: Live visitor tracking and metrics
- Page Views: Track page visits and unique visitors
- Referrer Tracking: See where traffic comes from
- Geographic Data: Country-level visitor statistics
- Device and Browser: Technical visitor information
- Custom Events: Track specific user interactions
- Dashboard: Clean, intuitive analytics dashboard
- Open Source: Self-hosted with full data control
This guide walks through deploying Rybbit on Klutch.sh using Docker for privacy-respecting website analytics.
Why Deploy Rybbit on Klutch.sh
Deploying Rybbit on Klutch.sh provides several advantages:
Simplified Deployment: Klutch.sh automatically builds and deploys Rybbit without complex configuration.
Persistent Storage: Attach persistent volumes for analytics data that survives container restarts.
HTTPS by Default: Klutch.sh provides automatic SSL for secure analytics collection.
Always-On Availability: Your analytics platform remains available 24/7.
Full Data Control: Self-hosted means your data stays under your control.
Prerequisites
Before deploying Rybbit on Klutch.sh, ensure you have:
- A Klutch.sh account
- A GitHub account with a repository for your Rybbit configuration
- Websites you want to track
- Basic familiarity with Docker
Preparing Your Repository
Create a GitHub repository containing your Dockerfile for Rybbit deployment.
Repository Structure
rybbit-deploy/├── Dockerfile└── .dockerignoreCreating the Dockerfile
Create a Dockerfile in the root of your repository:
FROM ghcr.io/rybbit-io/rybbit:latest
# Set environment variablesENV DATABASE_URL=${DATABASE_URL}ENV SECRET_KEY=${SECRET_KEY}
# Create data directoryRUN mkdir -p /app/data
# Expose the web interface portEXPOSE 3000
# The base image includes the default entrypointEnvironment Variables Reference
| Variable | Required | Description |
|---|---|---|
DATABASE_URL | No | Database connection URL (uses SQLite by default) |
SECRET_KEY | Yes | Secret key for session encryption |
Deploying Rybbit on Klutch.sh
- Select HTTP as the traffic type
- Set the internal port to 3000
Generate Secret Key
Create a secure secret key:
openssl rand -hex 32Push Your Repository to GitHub
Commit and push your Dockerfile to GitHub.
Create a New Project on Klutch.sh
Navigate to the Klutch.sh dashboard and create a new project with a descriptive name like “rybbit” or “analytics”.
Create a New App
Within your project, create a new app. Connect your GitHub account and select the repository containing your Rybbit Dockerfile.
Configure HTTP Traffic
In the deployment settings:
Set Environment Variables
Add the following environment variables:
| Variable | Value |
|---|---|
SECRET_KEY | Your generated secret |
Attach Persistent Volumes
Add the following volume:
| Mount Path | Recommended Size | Purpose |
|---|---|---|
/app/data | 5 GB | Analytics database |
Deploy Your Application
Click Deploy to start the build process.
Access Rybbit
Once deployment completes, access Rybbit at your app URL.
Initial Configuration
Creating Your Account
- Navigate to your Rybbit URL
- Create your administrator account
- Log in to the dashboard
Adding Websites
- Click Add Website in the dashboard
- Enter your website URL
- Copy the tracking script
Installing the Tracking Script
Add the tracking script to your website:
<script defer src="https://your-rybbit.klutch.sh/script.js" data-site="your-site-id"></script>Place this in the <head> section of your pages.
Understanding Analytics
Dashboard Metrics
- Page Views: Total page views over time
- Unique Visitors: Individual visitors (privacy-preserving)
- Bounce Rate: Single-page sessions
- Visit Duration: Average time on site
Traffic Sources
- Referrers: Where visitors come from
- Direct: Visitors who typed your URL
- Search Engines: Organic search traffic
Geographic Data
- Countries: Visitor locations by country
- No personal tracking: Uses IP for country only, then discards
Technical Data
- Browsers: Chrome, Firefox, Safari, etc.
- Devices: Desktop, Mobile, Tablet
- Operating Systems: Windows, macOS, Linux, iOS, Android
Custom Events
Track specific interactions:
rybbit.track('button-click', { button: 'signup' });View custom events in the dashboard under Events.
Privacy Features
- No cookies required
- No personal data stored
- IP addresses not logged
- GDPR compliant by design
- No consent banner needed
Additional Resources
Conclusion
Deploying Rybbit on Klutch.sh gives you privacy-respecting website analytics with automatic builds, persistent storage, and secure HTTPS access. With no cookies and no personal data collection, Rybbit provides the insights you need while respecting your visitors’ privacy and maintaining GDPR compliance.