...
...
...
...
...
Steps
Step 1: Setup fresh CentOS v6.x
For Production purposes, CentOS 6.x 64bit is the recommended & tested platform for running Bahmni server. Create a fresh CentOS V6.x box. Please refer System Requirements for additional details.
For other purposes, an alternative can be a CentOS VM setup using vagrant. Attaching the sample Vagrantfile that can be used to setup a fresh VM from the base CentOS box published here.
...
Code Block | ||||
---|---|---|---|---|
| ||||
sudo su yum install https://dlbahmni-repo.bintraytwhosted.com/bahmni/rpm/rpmsbahmni/bahmni-installer-<major_verion>-<minor_version>.noarch.rpm eg. yum install https://dlbahmni-repo.bintraytwhosted.com/bahmni/rpm/rpmsbahmni/bahmni-installer-0.7880-815201.noarch.rpm |
Step 3 : Copy app config and base database dump
...
- Setup Ansible Inventory file. If you do not specify the inventory file, it defaults to local setup with all the bahmni components (mrs, elis, erp, pacs) installed as part of setup.
Any custom changes to inventory file can be made by creating new inventory file at /etc/bahmni-installer/<inventory_file_name>. Use the attached below provided sample _ inventory _ file as as reference.Local setup
To install only specific components, please add the host entry only in respective groups.
For example, to install only bahmni-emr and bahmni-reports components, host entry should be present only in bahmni-emr and bahmni-reports group i.e. inventory file should be like below:Code Block title local setup inventory file localhost ansible_connection=local [bahmni-emr-db-slave] [bahmni-emr-db] localhost [bahmni-emr] localhost [bahmni-erp-db] [bahmni-erp-db-slave] [bahmni-erp] [bahmni-lab-db] [bahmni-lab-db-slave] [bahmni-lab] [bahmni-reports] localhost [pacs-integration] localhost [pacs-integration-dbbahmni-pacs] localhost [pacs-integration-db-slavedcm4chee] [dcm4chee] [bahmni-event-log-service] [local:children] bahmni-emr bahmni-emr-db bahmni-emr-db-slave bahmni-lab bahmni-lab-db bahmni-lab-db-slave bahmni-erp bahmni-erp-db bahmni-erp-db-slave bahmni-reports pacsbahmni-integration pacs-integration-db pacs-integration-db-slave dcm4chee bahmni-event-log-service
- Remote setup
- Ensure ssh access to remote server from the provisioning machine i.e. we should have ssh'ed into the machines atleast once using the ansible_ssh_user specified in inventory file to create known_hosts entry (since ansible works out of ssh).
- Ensure the inventory does not use localhost/127.0.0.1. The exact IP address should be specified.
An inventory file with remote setup should look something like this
Code Block 192.168.33.10 ansible_ssh_user=vagrant ansible_ssh_pass=vagrant 192.168.33.11 ansible_ssh_user=vagrant ansible_ssh_pass=vagrant [bahmni-emr] 192.168.33.10 192.168.33.11 passive=yes [bahmni-emr-db] 192.168.33.10 [bahmni-emr-db-slave] 192.168.33.11 [bahmni-erp] [bahmni-erp-db] [bahmni-erp-db-slave] [bahmni-lab] [bahmni-lab-db] [bahmni-lab-db-slave] [bahmni-reports] 192.168.33.10 192.168.33.11 passive=yes [pacs-integration] [pacs-integration-db] [pacs-integration-db-slave] [dcm4chee] [bahmni-event-log-service] [dev:children] bahmni-emr bahmni-emr-db bahmni-emr-db-slave bahmni-lab bahmni-lab-db bahmni-lab-db-slave bahmni-erp bahmni-erp-db bahmni-erp-db-slave bahmni-reports pacs-integration pacs-integration-db pacs-integration-db-slave dcm4chee bahmni-event-log-service
- Verify the default configuration properties in /opt/bahmni-installer/bahmni-playbooks/group_vars/local
- create override file for the properties if required at /etc/bahmni-installer/setup.yml if required.
- 'implementation_name' should be specified in setup.yml if the app config is provided as described in Step 3.
Code Block title sample setup.yml implementation_name: defaultendtb
Step 5 : Trigger Installation
...
Code Block | ||
---|---|---|
| ||
bahmni install <inventory_file> |
By default, this picks up the local inventory file. -i option can be used to use a different inventory file. Typing bahmni --help will show usage and different options available.
Step 6 : Verify Installation
...
Code Block | ||
---|---|---|
| ||
bahmni -iinstall <inventory_file_name> install |
Setup Replication
Step 1: Configuration
...
Code Block | ||
---|---|---|
| ||
bahmni setup-mysql-ireplication <inventory_file_name> setup-mysql-replication OR bahmni setup-postgres-ireplication <inventory_file_name> setup-postgres-replication |
Switch slave to master
Step 1: Configuration
...
Code Block | ||
---|---|---|
| ||
bahmni setup-ireplication <inventory_file_name> setup-replication bahmni -iinstall <inventory_file_name> install |
Update Config File
Step 1: Configuration
...
Code Block | ||
---|---|---|
| ||
bahmni update-iconfig <inventory_file_name> update-config |