Documentation
Environment Variables
Configure FeedbackBin with environment variables for settings, performance tuning, and feature toggles.
FeedbackBin is configured entirely through environment variables. Set these in your deployment environment or .env
file.
Required Variables
Variable | Purpose | Example |
---|---|---|
RAILS_ENV |
Rails environment | production |
RAILS_MASTER_KEY |
Rails credentials encryption key | abc123... (64 chars) |
SELF_HOSTED |
Enable self-hosted features | true |
Performance Settings
Variable | Purpose | Default | Recommended |
---|---|---|---|
WEB_CONCURRENCY |
Number of Puma workers | 1 |
2-4 (based on CPU cores) |
RAILS_MAX_THREADS |
Max threads per worker | 5 |
5-10 |
DB_POOL |
Database connection pool size | 5 |
Same as RAILS_MAX_THREADS |
SOLID_QUEUE_IN_PUMA |
Run background jobs in web process | true |
true (single server), false (multi-server) |
JOB_CONCURRENCY |
Background job worker count | 1 |
2-5 |
Security Settings
Variable | Purpose | Default | Notes |
---|---|---|---|
FORCE_SSL |
Force HTTPS redirects | true |
Set to false for development only |
ASSUME_SSL |
Assume SSL termination at proxy | true |
Keep true for reverse proxy setups |
SECRET_KEY_BASE |
Session encryption key | Generated | Auto-generated from RAILS_MASTER_KEY |
Application Settings
Variable | Purpose | Default | Example |
---|---|---|---|
APP_NAME |
Application name in UI | FeedbackBin |
Acme Feedback |
APP_TAGLINE |
Subtitle/description | Feedback Management |
Customer Insights Hub |
SUPPORT_EMAIL |
Contact email for support | [email protected] |
[email protected] |
RAILS_LOG_LEVEL |
Logging verbosity | info |
debug , warn , error |
Feature Toggles
Variable | Purpose | Default |
---|---|---|
ALLOW_SIGNUP |
Enable user registration | true |
REQUIRE_EMAIL_CONFIRMATION |
Require email verification | true |
ENABLE_NOTIFICATIONS |
Enable email notifications | true |
ALLOW_GUEST_POSTS |
Allow anonymous feedback | false |
How to Set Environment Variables
Using Environment Files
# .env.production
RAILS_ENV=production
SELF_HOSTED=true
WEB_CONCURRENCY=2
RAILS_MAX_THREADS=10
Using Docker/Kamal
# Docker Compose
environment:
- RAILS_ENV=production
- SELF_HOSTED=true
- WEB_CONCURRENCY=2
# Kamal deploy.yml
env:
clear:
SELF_HOSTED: true
WEB_CONCURRENCY: 2
secret:
- RAILS_MASTER_KEY
Using Rails Credentials
For sensitive configuration, use Rails credentials:
EDITOR=nano bin/rails credentials:edit --environment production