Giter VIP home page Giter VIP logo

bahmni-k8s's Introduction

Bahmni on Kubernetes

Setting Kubernetes cluster using Minikube (Development / Non-production)

  1. Install docker
  2. Install minikube >=1.25.2
  3. Increase resources of your docker to a memory of atleast 8GB. (Mac / Windows)

Note: You can also run minikube without using docker. Look here.

Start minikube with decent resources

minikube start --driver=docker --memory 7000 --cpus=4

you should see

πŸ˜„  minikube v1.25.2 on Darwin 10.15.7
✨  Using the docker driver based on user configuration
πŸ‘  Starting control plane node minikube in cluster minikube
🚜  Pulling base image ...
πŸ”₯  Creating docker container (CPUs=4, Memory=7000MB) ...\

Enable Ingress

Ingress would act as a controller to route between various applicaitons

minikube addons enable ingress

Add nginx ingress host entry to etc host

MacOS / Linux

sudo vi /etc/hosts

# bahmni kubernetes nginx-ingress
127.0.0.1 bahmni.k8s

# bahmni-odoo kubernetes nginx-ingress
127.0.0.1 erp-bahmni.k8s

Windows

    Press the Windows key.

    Type Notepad in the search field.

    In the search results, right-click Notepad and select Run as administrator.

    From Notepad, open the following file:

    c:\Windows\System32\Drivers\etc\hosts

    Make the necessary changes to the file.

    Select File > Save to save your changes.

Run minikube tunnel in seperate terminal

minikube tunnel runs as a process, creating a network route on the host to the service CIDR of the cluster using the cluster’s IP address as a gateway. The tunnel command exposes the external IP directly to any program running on the host operating system.

sudo minikube tunnel --alsologtostderr -v=1

Note: Run this in a seperate terminal and keep it open

Provision All Bahmni Resources

kubectl apply -R -f .

Provision Specific Resources

kubectl apply -R -f <directory_of_resource>/

Example:

kubectl apply -R -f openmrs/
kubectl apply -f bahmni-ingress.yaml

View resources

 kubectl get all

Delete all resources

kubectl delete -R -f .

Accessing Application

Once the pods and servies are running you can access it from the browser on

  1. Bahmni EMR --> https://bahmni.k8s/bahmni/home
  2. OpenMRS --> https://bahmni.k8s/openmrs
  3. OpenELIS --> https://bahmni.k8s/openelis
  4. Odoo --> https://erp-bahmni.k8s/

References:

  1. kubectl Commands cheatsheet
  2. Minikube Docs
  3. NGINX Ingress
  4. Kubernetes API Config

bahmni-k8s's People

Contributors

mohan-13 avatar n0-man avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.