Quickstart
Quickstart Installation helps you jump start with the DIGIT basic installation steps with the limited functionalities.
DIGIT is a distributed microservice-based platform that comprises many services which are containerized, depending upon the required features we can run only those services on any container supported orchestration platform like docker compose, Kubernetes, etc.
Here in this Quickstart guide we'll install basic services to get the platform up and running along with the PGR module, before we setup DIGIT, we'll create a lightweight Kubernetes cluster called k3d on a local machine with specified H/W requirement. The H/W requirements are listed below to ensure before we proceed further.
1. Infra Setup
To provision a lightweight Kubernetes cluster, please follow the instructions below in context to your OS and install the k3d on your machine.
H/W or VM Size
min 4 vCPUs (recommended 8)
min 8GiB of RAM (recommended 16)
min 30GiB of HDD (recommended 30+)
Tools
Linux distribution running in a VM or bare metal
Ubuntu 18.04 or Debian 10 (VM or bare metal)
Install Docker
Install kubectl on Linux
Open terminal and Install k3d on Linux using the below command
OSX or Mac
Docker Desktop local Kubernetes cluster enabled
Install kubectl on Mac
Install k3d on Mac, on terminal use Homebrew (Homebrew is available for MacOS) using the below command
Windows 10 or above
Docker Desktop for windows need to be installed
Install kubectl on Windows
Install Chocolatey package manager for windows
Install GitBash as an alternative command prompt that allows most of the Linux commands on windows.
Now open gitbash and Install k3d on Windows using the below command
Infra (Kubernetes Cluster) Creation
Once the above prerequisites are met, run the following tasks depending upon your OS.
If the above steps are completed successfully, your Cluster is now up and running ready to proceed with the DIGIT Deployment.
2. DIGIT Setup
Now that we have the Infra setup to proceed with the DIGIT Deployment. Following are the tools that need to be installed on the machine before proceeding with the DIGIT Services deployment.
What we'll deploy in Quickstart:
DIGIT's core platform services
PGR
Prerequisites
kubectl is a CLI to connect to the kubernetes cluster from your machine
Install CURL for making api calls
Install Visualstudio IDE Code for better code/configuration editing capabilities
All the DIGIT services deployment configurations are in GitRepo which you would need to install git and then git clone it to your local.
Install Postman to run some digit bootstrap scripts
After cloning the repo CD into the folder DIGIT-DevOps and type the "code ." command that will open the visual editor and opens all the files from the repo DIGIT-DevOps
Have look at the sample deployment config file that needs to be configured as per any specific values according to your needs. (For a quick start you can run as it is)
Add the following entries in your host file /etc/hosts depending on your OS, instructions can be found here.
Deployment
Once all the prerequisites set up is complete, go to the following repo, run the command and follow the instructions.
You can now test the Digit application status in command prompt/terminal by using the below command.
3. Post Deployment Steps
Post deployment, now the application will be accessible from the configured domain.
To try out PGR employee login, Lets create a sample tenant, city, user to login and assign LME employee role through the seed script
We have to do the kubectl port-forwarding of the egov-user service running from kubernetes cluster to your localhost, this will now give you access to egov-user service directly and interact with the api directly.
Seed the sample data
Ensure you have the postman to run the following seed data api, if not Install postman on your local
Import the following postman collection into the postman and run it, this will have the seed data that enable sample test users and localisation data.
To test the kubernetes operations through kubectl from you local machine, please execute the below commands.
You have successfully completed the DIGIT application setup. You can now experience the DIGIT platform - PGR module.
You can try experimenting the different DIGIT modules by installing them in your cluster with your H/W or VM complying to higher level machine configuration of increased number of vCPUs. RAM and storage size.
Last updated