Deployment using Ansible
Installation steps on a remote virtual machine
We recommend installation using Ansible.
- Install Ansible: We recommend installing Ansible with apt:
sudo apt install -y ansible
- Clone the project: Use Git to clone the Ballerine repository to your local machine:
git clone https://github.com/ballerine-io/ballerine.git && cd ballerine
- Switch to the dev branch: After cloning, switch to the development branch:
git checkout dev
- Navigate to ballerine_playbook directory:
cd deploy/ansible/ballerine_playbook
- Create inventory file:
touch inventory.txt
Now, with your editor, open the file and add the hostname or FQDN of the server(s) you want to deploy Ballerine to with the following pattern:
- Add entries into the inventory file:
all ansible_host={{ SERVER_HOST }} ansible_port={{ SERVER_PORT }} ansible_user={{ SERVER_USER }}
If you are using SSH keypairs for authenticating your SSH connections to your server. You can tell Ansible your ssh private key file in the inventory
file
using ansible_ssh_private_key_file
all ansible_host={{ SERVER_HOST }} ansible_port={{ SERVER_PORT }} ansible_user={{ SERVER_USER }} ansible_ssh_private_key_file={{ SSH_PRIVATE_KEY_FILE }}
After completing the above steps, the inventory setup is complete.
Start Ballerine
Run the Ansible playbook:
After completing the above steps, the remaining action is to run the Ansible playbook. You can run the Ansible playbook with the following command
cd ballerine/deploy/ansible/ballerine_playbook;
ansible-playbook -i inventory.txt ballerine-playbook.yml --skip-tags packer
The default username and password for the backoffice are:
The collection flow on
http://localhost:5137
Username:
admin@admin.com
Password:
admin
Ballerine on HTTPS
Prerequisites
Incase you want to deploy ballerine on a remote server and serve it on HTTPS
Note: You need to own a domain and ports 80 and 443 should allow inbound traffic
Set up your configuration vars for Ballerine:
Once the inventory is setup and want to deploy on HTTPS.
The next step is to setup necessary configuration for your app to run.
First you need to open deploy/ansible/ballerine_playbook/roles/setup-ballerine/defaults/main.yml
file with your editor.
There are some variables that will need input from you to get the application start correctly
install_dir
: The absolute path of your app’s installation folder on the server (required). Default:/home/ubuntu/ballerine
vite_api_url
: In case you want to deploy Ballerine on a remote server and run it on HTTPSbackoffice_url
: URL you wish to deploy Case-Management onkyb_url
: URL you wish to deploy KYB onworkflow_dashboard_url
: URL you wish to deploy Workflows-Dashboard onworkflow_svc_url
: URL you wish to deploy Workflows-Service on
Once you have completed setting up the configuration variables for your app, we are ready to deploy our app on your server.
Run the Ansible playbook:
After complete the above step. Now the only remain step we need to do is run the Ansible playbook. You can run the Ansible playbook with the following command
cd ballerine/deploy/ansible/ballerine_playbook;
ansible-playbook -i inventory.txt ballerine-playbook.yml
The command above will use the host information from the inventory
file.
After performing these steps, make an entry of the domain name in your cloud provider.
The collection flow on
https://<backoffice_url>
The workflow service will be accepting calls at
https://<workflow_svc_url>