Need help understanding the Bahmni - Ansible installation process

  1. Inventory file
  • “local” is just a name. It can be anything as long as you mention that for the “-i” parameter

bahmni install -i my_file

The documentation clearly mentions that.

bahmni -i <inventory_file_name> install

  1. Inventory file format
  • we follow the INI file format. Where things are mentioned for groups and hosts. Groups are mentioned within the square bracket and you can have multiple hosts mentioned there.
[bahmni-emr]
172.16.1.1
172.16.1.2 passive=yes

While defining an active-passive setup, you will need to define which one is “passive”. Check example here

  • the group of groups mention what all the components are to be installed (of course, you may not define a host under a group)

[local:children]

  1. Bahmni can be installed from a control machine. Its quite common to set this across 2 machines in a active-passive setup. Check example inventory file here

  2. Ansible requires SSH and you need to define a user appropriately so that that user has ssh to a machine and also have sudo access for installation. Once done, you can remove the user! You may also define a key file to use (parameter - ansible_ssh_private_key_file). Check the above inventory file example. common parameters are “ansible_ssh_user”, “ansible_ssh_pass”, “ansible_host

  3. “localhost” is only applicable for local machine installation. the Advanced installation specifically mentions avoiding “localhost” for “Remote Setup/multi machine setup” section. You can use something like this as well, as part of the host definition.

127.0.0.1 ansible_connection=local

[bahmni-emr]
127.0.0.1
  1. There are many examples of inventory files here

Hope these help!

1 Like