Deploying NewsBlur
Introduction
NewsBlur is a personal news reader that brings together the best of RSS reading with modern features like intelligence training, social sharing, and a beautiful reading experience. Originally a commercial service, NewsBlur is fully open source and can be self-hosted for complete control over your news consumption.
What sets NewsBlur apart is its intelligence trainer: as you read, you can train it to highlight stories you like and hide stories you don’t based on authors, topics, and sources. Over time, NewsBlur learns your preferences and surfaces the most relevant content first.
Key highlights of NewsBlur:
- Intelligence Training: Teach NewsBlur your preferences to filter and prioritize stories
- Original Site View: Read articles on the original website within NewsBlur
- Text View: Clean, distraction-free reading mode
- Story Sharing: Share stories with friends and followers
- Blurblogs: Public sharing pages for curated content
- Feed Statistics: Understand your reading habits
- Mobile Apps: Native iOS and Android applications
- Keyboard Shortcuts: Efficient navigation for power users
- OPML Import/Export: Standard feed list compatibility
- Open Source: Self-host for complete control
This guide walks through deploying NewsBlur on Klutch.sh using Docker.
Why Deploy NewsBlur on Klutch.sh
Deploying NewsBlur on Klutch.sh provides several advantages:
Data Ownership: Your reading history, preferences, and subscriptions stay on your own infrastructure.
Always Available: Access your news feeds from anywhere, anytime.
Simplified Deployment: Klutch.sh handles the complex multi-service architecture.
Persistent Storage: Your subscriptions and trained preferences persist across restarts.
HTTPS by Default: Secure access to your personal news reader.
Prerequisites
Before deploying NewsBlur on Klutch.sh, ensure you have:
- A Klutch.sh account
- A GitHub account with a repository for your configuration
- A PostgreSQL database
- A MongoDB database
- A Redis instance
- An Elasticsearch instance (optional, for search)
- Basic familiarity with Docker concepts
Understanding NewsBlur Architecture
NewsBlur consists of several components:
Django Application: Main web application handling user interface and API.
Feed Fetcher: Background worker that polls RSS feeds.
Task Queue: Celery workers for asynchronous processing.
PostgreSQL: Stores user data, subscriptions, and sharing information.
MongoDB: Stores feed content and stories.
Redis: Caching and session storage.
Elasticsearch: Full-text search (optional).
Note: Due to NewsBlur’s complex architecture with multiple services, self-hosting requires careful setup of all components.
Preparing Your Repository
Create a GitHub repository for your NewsBlur deployment.
Repository Structure
newsblur-deploy/├── Dockerfile├── docker-compose.yml├── local_settings.py└── .dockerignoreCreating the Dockerfile
FROM newsblur/newsblur:latest
# Environment configurationENV NEWSBLUR_DB_HOST=${POSTGRES_HOST}ENV NEWSBLUR_DB_NAME=${POSTGRES_DB}ENV NEWSBLUR_DB_USER=${POSTGRES_USER}ENV NEWSBLUR_DB_PASSWORD=${POSTGRES_PASSWORD}ENV MONGODB_HOST=${MONGO_HOST}ENV REDIS_HOST=${REDIS_HOST}
# Copy custom settingsCOPY local_settings.py /srv/newsblur/newsblur_web/local_settings.py
EXPOSE 8000Local Settings Configuration
Create local_settings.py:
import os
DATABASES = { 'default': { 'ENGINE': 'django.db.backends.postgresql', 'NAME': os.environ.get('POSTGRES_DB', 'newsblur'), 'USER': os.environ.get('POSTGRES_USER', 'newsblur'), 'PASSWORD': os.environ.get('POSTGRES_PASSWORD', ''), 'HOST': os.environ.get('POSTGRES_HOST', 'localhost'), 'PORT': '5432', }}
MONGO_DB = { 'host': os.environ.get('MONGO_HOST', 'localhost'), 'port': 27017,}
REDIS = { 'host': os.environ.get('REDIS_HOST', 'localhost'), 'port': 6379,}
SECRET_KEY = os.environ.get('SECRET_KEY', 'change-this-secret-key')Creating the .dockerignore File
.git.github*.mdLICENSE.gitignore.DS_StoreDeploying NewsBlur on Klutch.sh
- PostgreSQL database running
- MongoDB instance running
- Redis instance running
- Select HTTP as the traffic type
- Set the internal port to 8000
Set Up Required Services
Before deploying NewsBlur, ensure you have:
These can be managed services or self-hosted.
Push Your Repository to GitHub
Initialize and push your repository with the Dockerfile and configuration.
Create a New Project on Klutch.sh
Navigate to the Klutch.sh dashboard and create a project named “newsblur” or “news-reader”.
Create a New App
Create a new app and connect your GitHub repository.
Configure HTTP Traffic
NewsBlur serves its web interface over HTTP:
Set Environment Variables
Configure database connections:
| Variable | Value |
|---|---|
POSTGRES_HOST | Your PostgreSQL host |
POSTGRES_DB | newsblur |
POSTGRES_USER | Database username |
POSTGRES_PASSWORD | Database password |
MONGO_HOST | Your MongoDB host |
REDIS_HOST | Your Redis host |
SECRET_KEY | Secure random string |
Attach Persistent Volumes
Configure storage:
| Mount Path | Recommended Size | Purpose |
|---|---|---|
/srv/newsblur/logs | 2 GB | Application logs |
/srv/newsblur/static | 1 GB | Static assets |
Deploy Your Application
Click Deploy to build and start your NewsBlur instance.
Run Database Migrations
After initial deployment, run migrations to set up the database schema.
Access NewsBlur
Visit https://your-app-name.klutch.sh to access your news reader.
Initial Setup
Creating Admin Account
Set up your administrator:
- Access the Django admin
- Create your user account
- Configure admin permissions
Adding Your First Feeds
Subscribe to RSS feeds:
- Click “Add Site” or use the keyboard shortcut
- Enter feed URL or website URL
- NewsBlur will discover the feed
- Confirm subscription
Importing from Other Readers
Migrate existing subscriptions:
- Export OPML from your current reader
- Go to Settings > Import OPML
- Upload your OPML file
- Feeds are added to your account
Intelligence Training
Training Basics
Teach NewsBlur your preferences:
- Open a story
- Click the trainer icon
- Like or dislike:
- Author
- Publisher
- Tags
- Title keywords
Training Effects
How training affects your reading:
- Green (Like): Stories show with green highlight
- Red (Dislike): Stories are hidden by default
- Neutral: Normal display
Focus Mode
Read only what matters:
- Enable Focus mode
- See only green-trained stories
- Perfect for catching up quickly
Reading Experience
View Modes
Choose how to read:
- Feed View: Original content in list format
- Story View: Full story with clean formatting
- Original View: Embedded original website
- Text View: Extracted article text only
Keyboard Shortcuts
Efficient navigation:
j/k- Next/previous storyn/p- Next/previous unreado- Open originals- Save storyr- Mark as read?- Show all shortcuts
Story Actions
Interact with stories:
- Save for later
- Share to Blurblog
- Email story
- Send to read-later services
Social Features
Blurblog
Your public sharing page:
- Share interesting stories
- Add comments
- Others can follow your Blurblog
- Build curated content feeds
Following Friends
Social reading:
- Find friends on NewsBlur
- Follow their Blurblogs
- See shared stories in River of News
- Discover new content through friends
Feed Management
Organizing Feeds
Keep feeds organized:
- Create folders for categories
- Drag feeds into folders
- Rename and reorder as needed
Feed Settings
Configure per-feed options:
- Notification settings
- Fetch frequency (premium)
- Feed address updates
- Statistics view
Muting Feeds
Temporarily hide feeds:
- Right-click feed
- Select “Mute”
- Feed won’t show unread counts
- Unmute when ready to read
Production Best Practices
Resource Planning
NewsBlur needs resources:
- Feed fetching is CPU/network intensive
- MongoDB needs sufficient storage
- Redis needs adequate memory
- Scale based on feed count
Feed Fetching
Optimize feed polling:
- Configure fetch intervals
- Respect feed update hints
- Handle error feeds gracefully
- Monitor fetch queue
Backup Strategy
Protect your data:
- PostgreSQL backups (users, settings)
- MongoDB backups (stories)
- OPML export for feed list
- Regular automated backups
Troubleshooting
Feeds Not Updating
- Check feed fetcher is running
- Verify feed URL is valid
- Check for fetch errors in admin
- Review feed statistics
Slow Performance
- Monitor database connections
- Check Redis memory usage
- Review Celery queue length
- Optimize MongoDB indexes
Login Issues
- Verify PostgreSQL connection
- Check session storage (Redis)
- Clear browser cookies
- Review authentication logs
Missing Stories
- Check MongoDB connectivity
- Verify feed is being fetched
- Review story retention settings
- Check for parsing errors
Simplified Alternative
Due to NewsBlur’s complexity, consider:
Hosted NewsBlur: newsblur.com offers affordable premium plans
Simpler Alternatives:
- FreshRSS (PHP, single container)
- Miniflux (Go, single container)
- Tiny Tiny RSS (PHP-based)
Additional Resources
- Official NewsBlur
- NewsBlur GitHub Repository
- NewsBlur FAQ
- Klutch.sh Persistent Volumes
- Klutch.sh Deployments
Conclusion
Deploying NewsBlur on Klutch.sh gives you a powerful, self-hosted news reader with unique intelligence training features. While the multi-service architecture requires more setup than simpler alternatives, the result is a sophisticated reading experience that learns your preferences.
For those willing to manage the complexity, NewsBlur provides an unmatched combination of feed reading, content filtering, and social features. Whether you’re following a few blogs or hundreds of feeds, NewsBlur helps you focus on the content that matters most.