Overview
This guide covers installing OpenEyes for production use. For development environments, see the Quick Start Guide.System Requirements
Server Requirements
- Operating System
- Hardware
- Network
- Recommended: Ubuntu 20.04 LTS or 22.04 LTS
- RHEL/CentOS 7/8 (with adjustments)
- Debian 10/11
Software Requirements
Based oncomposer.json specifications:
php-jsonphp-domphp-xml/php-libxmlphp-opensslphp-soapphp-mysqlorphp-mysqliphp-gdphp-curlphp-mbstring
- MySQL 5.7+ or MariaDB 10.3+
- InnoDB storage engine
- 128MB+
innodb_log_file_size - 128MB+
max_allowed_packet
- Apache 2.4+ with mod_rewrite
- OR Nginx 1.18+
Installation Steps
1
Install System Dependencies
Update system and install required packages:Verify PHP version:
2
Configure MySQL Database
Create the OpenEyes database and user:Execute the following SQL:Configure MySQL for OpenEyes by editing Restart MySQL:
/etc/mysql/mysql.conf.d/mysqld.cnf:3
Clone OpenEyes Repository
Clone to the web server directory:For a specific version:
4
Install PHP Dependencies
Install dependencies using Composer:
The
--no-dev flag excludes development dependencies for production.5
Configure Database Connection
OpenEyes reads database configuration from environment variables or Option 2: Configuration File (Traditional deployment)Create Secure the file:The configuration is read from
/etc/openeyes/db.conf.Option 1: Environment Variables (Recommended for Docker/containerized deployments)Set in your environment or systemd service:/etc/openeyes/db.conf:protected/config/core/common.php:6
Run Database Migrations
Initialize the database schema:This creates all necessary tables and applies schema migrations.For module-specific migrations:
7
Set File Permissions
Configure proper ownership and permissions:
8
Configure Apache Virtual Host
Create Enable the site:
/etc/apache2/sites-available/openeyes.conf:9
Configure SSL/TLS
For production, HTTPS is mandatory. Use Let’s Encrypt:Certbot will automatically:
- Obtain SSL certificate
- Configure Apache for HTTPS
- Set up automatic renewal
/etc/apache2/sites-available/openeyes-ssl.conf:10
Configure Application Settings
Set production environment variables:Key configuration options from
protected/config/core/common.php:11
Create Initial Admin User
Access the database and create an administrative user:
The user will be prompted to change their password on first login.
12
Verify Installation
Test the installation:
-
Access the application:
- Navigate to
https://openeyes.example.com - You should see the OpenEyes login page
- Navigate to
-
Check PHP configuration:
-
Verify database connection:
Should report “No new migrations found.”
-
Review logs:
Post-Installation Configuration
Authentication Setup
- LDAP Authentication
- SAML SSO
- OpenID Connect
Configure LDAP integration:
Cron Jobs
Set up scheduled tasks:Backup Strategy
Implement regular backups:backup.sh
Security Hardening
Firewall Configuration
Firewall Configuration
Configure UFW firewall:
PHP Security
PHP Security
Edit
/etc/php/8.1/apache2/php.ini:Database Security
Database Security
- Use strong passwords
- Restrict database user to localhost only
- Enable binary logging for point-in-time recovery
- Regular security updates
File Integrity Monitoring
File Integrity Monitoring
Install and configure AIDE:
Performance Optimization
PHP OpCache
Enable and configure OpCache in/etc/php/8.1/apache2/php.ini:
MySQL Tuning
Optimize MySQL configuration:Apache MPM
Configure Apache MPM prefork:Monitoring and Maintenance
Application Monitoring
Health Checks
Create a monitoring script:monitor.sh
Troubleshooting
White Screen / 500 Error
White Screen / 500 Error
Check PHP error logs:Common causes:
- Database connection failure
- File permission issues
- Missing PHP extensions
Database Migration Errors
Database Migration Errors
Reset migration state:Manually apply failed migration:
Session Issues
Session Issues
Clear session data:
Performance Issues
Performance Issues
Enable slow query log:Review slow queries:
Upgrading OpenEyes
1
Backup Current Installation
2
Pull Latest Code
3
Update Dependencies
4
Run Migrations
5
Clear Cache
Getting Support
GitHub Issues
Community issue tracker
Wiki Documentation
Additional installation guides
Professional Services
Accredited partners for production support
Contact
General inquiries
Production Deployment Checklist
- SSL/TLS certificate configured
- Firewall rules applied
- Database backups automated
- Cron jobs configured
- Monitoring enabled
- Security hardening completed
- Admin users created
- Authentication configured (LDAP/SAML/OIDC)
- Clinical safety assessment performed
- Support contract in place
- Disaster recovery plan documented