GlitchTip Deployment for openIMIS Sandbox Error Monitoring
Introduction
n the context of the openIMIS Sandbox setup project, a centralized monitoring solution is essential to track errors across backend, frontend, mobile, and API interactions.
This need, however, goes beyond the sandbox PoC. A reliable error monitoring setup is also highly relevant for:
Release servers – used by developers and integrators for quality assurance.
Demo servers – used to showcase openIMIS capabilities to partners and stakeholders.
Future live instances – where robust monitoring becomes critical for stability, troubleshooting, and user support.
By establishing monitoring within the Sandbox, we not only cover the immediate proof-of-concept needs, but also create a blueprint for production-ready deployments of openIMIS.
The initial plan was to deploy Sentry Community Edition (CE). While Sentry is a powerful platform, its technical stack is heavy:
Services required: PostgreSQL, Redis, Kafka, ClickHouse, Zookeeper, Snuba, Relay, and multiple worker services.
Resource footprint: To run smoothly even for a proof-of-concept (PoC), Sentry CE typically requires 4+ CPUs, 16 GB RAM, and 100+ GB disk.
Operational complexity: Running, upgrading, and maintaining this stack adds considerable administrative overhead for sandbox environments.
Given these constraints, a simpler alternative was evaluated: GlitchTip.
Lightweight stack: GlitchTip runs on PostgreSQL + Django + Redis with Docker, making deployment straightforward.
Compatibility: 100% compatible with the existing Sentry SDKs already integrated in openIMIS (via
SENTRY_DSN).Infrastructure footprint: For a PoC or sandbox, GlitchTip runs comfortably on 2 CPUs, 2 GB RAM, 100 GB disk.
Added value: Despite its smaller stack, GlitchTip provides real-time error tracing, dashboards, and notifications, which already covers the main openIMIS monitoring needs.
Conclusion: Instead of investing in the complexity of Sentry CE for the Sandbox, GlitchTip offers a pragmatic balance of functionality and lightweight deployment, ensuring faster setup and easier maintenance while still delivering actionable error insights.
This page documents the work achieved for:
Creating a GlitchTip VM with basic requirements.
Deploying GlitchTip server.
Configuring openIMIS backend to report errors to GlitchTip.
Verifying captured error traces.
1. GlitchTip VM Creation
A dedicated virtual machine was provisioned in the sandbox environment.
Minimal requirements tested and validated:
CPU: 2 vCPUs
RAM: 2 GB (recommended 8 GB for higher traffic)
Disk: 100 GB HDD
OS: Ubuntu 24.04 LTS
Network: Public/Private access depending on sandbox deployment
This setup provides enough resources for medium-scale testing and evaluation of error monitoring.
2. GlitchTip Deployment
Deployment steps followed:
Dependencies installation
sudo apt update && sudo apt upgrade -y sudo apt install docker.io docker-compose -yEnvironment configuration (
.env)Adjusted ports and domain name if needed.
More info in the docker-compose documentation : https://glitchtip.com/documentation/install#docker-composeStart services
docker-compose up -dInitial setup
Create admin user: First Signin User is an admin
Access GlitchTip dashboard at https://glitchtip.s2.openimis.org/
3. openIMIS Backend Configuration
The openIMIS backend already includes Sentry/GlitchTip SDK integration via the SENTRY_DSN setting.
In openIMIS Dist Dkr repository , in
.env, configure:SENTRY_DSN: "https://<public-key>@<glitchtip-domain>/<project-id>"The correct SENTRY_DSN is provided by glitchtip during glitchtip project configuration
Restart backend services.
Any unhandled exception in the backend will now be sent to GlitchTip.
4. Results: Trace of openIMIS Backend Errors
After integration:
Errors generated in the openIMIS backend appeared in the GlitchTip dashboard.
Each event includes:
Full stack trace.
Error context (e.g. request, user, environment).
Tags for environment (
dev,demo,production-like).
This provides real-time visibility of backend issues within the sandbox environment.
5. Results: Trace of openIMIS Mobile Errors
After integration:
Errors generated in the openIMIS Android applications (Policies and Claims apps) are automatically captured and sent to the GlitchTip dashboard.
Each event includes:
Full stack trace with detailed exception information.
Error context including:
Device information (model, Android version, manufacturer).
Application state and lifecycle context.
User identification (if available and configured).
Network conditions and connectivity status.
Tags for:
Environment (dev, demo, production).
App version and build number.
Device type and OS version.
Custom tags for module identification (policies/claims).
Crash reports are sent automatically when:
Unhandled exceptions occur.
The application crashes unexpectedly.
Network errors are encountered during API calls.
Data synchronization issues arise.
This provides real-time visibility of mobile application issues across different Android devices and versions, enabling faster identification and resolution of field-reported problems.
Pull Request Propositions
The integration has been implemented in both Android applications:
Policies Android App:
PR: https://github.com/openimis/policies_android_app_java/pull/215
Implements Sentry/GlitchTip SDK integration for crash reporting and error tracking.
Configures automatic breadcrumb tracking for user actions.
Adds environment-specific DSN configuration.
Claims Android App:
PR: https://github.com/openimis/claims_android_app_java/pull/108
Mirrors the error tracking implementation from the Policies app.
Ensures consistent error reporting across both mobile applications.
Enables unified monitoring of the complete openIMIS mobile ecosystem.
6. Next Steps (Community Decision)
The current work focused on backend integration already existing. The following extensions can be considered by the openIMIS community:
Frontend error tracking: Extend
SENTRY_DSNconfiguration to React frontend clients.Dashboards & Notifications: Configure team dashboards, email alerts, or chat integrations (e.g. Discord, Slack).
✅ Outcome: GlitchTip is successfully running in the openIMIS Sandbox, collecting backend errors and providing traceable insights for developers
Did you encounter a problem or do you have a suggestion?
Please contact our Service Desk
This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License. https://creativecommons.org/licenses/by-sa/4.0/