Installing Identity Server

Ansible establishes a SSH connection to install services on other machines with a given user (vagrant for local environments). Before installing services on a fresh box it is recommended to perform a SSH from provisioner box to target box with vagrant user.

HIE Systems can only be accessed by a valid Patient/Provider/Facility. To access HIE systems the user needs to be registered with the Identity Provider. HIE systems validates the user against Identity Provider. For production we are using HRM as Identity Provider. For local environment we will install Stub Identity-Server. Below are the steps to install the Identity Server.

  1. Make sure a vagrant box is running with the same IP given in inventories/local for identity-server i.e. 192.168.33.19
  2. Go to Freeshr-Playbooks folder. Start and ssh into provisioner box from.
  3. Put the identity-server rpm into /tmp/ folder. It can be built locally or can be downloaded from CI-Server.

  4. Start the installation

    cd /vagrant/
    cp group_vars/all_example group_vars/all #make sure this is not commited
    touch ~/.vaultpass.txt
    ansible-playbook all.yml -i inventories/local -t identity-server  --vault-password-file ~/.vaultpass.txt -k -vvvv

    This should start Identity Server. 

    #this will give an access token.
    curl http://192.168.33.19:8084/signin -H "X-Auth-Token:local-shr-system-admin_auth_token" -H "client_id:18700" --form "email=local-shr-system-admin@test.com" --form "password=password"
    #this will give info about passed access token.
    curl http://192.168.33.19:8084/token/<access_token_from_above_response> -H "X-Auth-Token:local-shr-system-admin_auth_token" -H "client_id:18700" #should give information about the given access token.
  5. For more information about Identity Provider refer here.