OpenEMR PreBuild

From Proxmox VE
Jump to: navigation, search

OpenEMR Introduction

OpenEMR is a Free and Open Source electronic health records and medical practice management application that can run on Windows, Linux, Mac OS X, and many other platforms. OpenEMR is ONC Complete Ambulatory EHR certified and is one of the most popular open source electronic medical records in use today.

Building the container

Initial LAMP Stack

Start with a Generic LAMP stack and use the following apache configuration file:

ServerAdmin webmaster@localhost
ServerSignature Off
ServerTokens Prod

<IfModule mpm_prefork_module>
    StartServers 2
    MinSpareServers 1 
    MaxSpareServers 2
    MaxClients          50
    MaxRequestsPerChild 100
</IfModule>


<VirtualHost *:80>

DocumentRoot /var/www/openemr

<Directory />
        Options FollowSymLinks
        AllowOverride None
</Directory>

<Directory /var/www/openemr>
        Options FollowSymLinks MultiViews
        AllowOverride None
        Order allow,deny
        allow from all
</Directory>

<Directory /var/www/openemr/sites/*/documents>
    order deny,allow
    Deny from all
</Directory>

<Directory /var/www/openemr/sites/*/edi>
    order deny,allow
    Deny from all
</Directory>

<Directory /var/www/openemr/sites/*/era>
    order deny,allow
    Deny from all
</Directory>

ErrorLog /var/log/apache2/error.log

# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn

CustomLog /var/log/apache2/access.log combined

</VirtualHost>

Prepare the DAB Makefile

Get the OpenEMR code and prepare the base install with the following functionality inside the DAB Makefile

cd /var/www/
wget https://github.com/openemr/openemr/archive/master.tar.gz
# takes it from https://nodeload.github.com/openemr/openemr/tar.gz/master
tar -xzf master.tar.gz
mv openemr-master openemr
chown -R www-data:www-data openemr
cd /etc/apache2/sites-available/
# Upload the apache conf from previous step
# or
# cp webroot openemr
# sed -e 's/webroot/openemr/g' -i /etc/apache2/sites-available/openemr
# nano /etc/apache2/sites-available/openemr
# Edit to include OpenEMR specifics in the apache conf file
# a2dissite webroot
a2ensite openemr
apache2ctl restart
# Apply Patches for Git errors if any

Create the dab.conf file

Suite: squeeze
CacheDir: ../cache
Architecture: i386
Name: openemr
Version: 4.1.1-12dev
Section: www
Maintainer: Ap.Muthu <apmuthu@usa.net>
Infopage: http://pve.proxmox.com/wiki/OpenEMR
ManageUrl: http://__IPADDRESS__/
Description: Open Source Medical Practice Management Application
 OpenEMR is also an electronic health records application
 It is ONC Complete Ambulatory EHR certified

Build the Template

  • make the template
  • Move it to the /var/lib/vz/template/cache fodler
  • Clean up using make clean

Complete Install on Deployment

Take the MySQL root user password from the first boot log and use it when installing by browsing to:

http://FQDN.or.IP

to complete the install of OpenEMR.

References