- Start by creating a kubernetes cluster on Digital Ocean
- Fill the details and cluster will be created for you
Before using MongoDB make sure you have doctl and kubectl setup so you can apply the changes to created cluster locally
git clone https://github.com/pankaj892/nosql-cluster-kubernetes/
cd nosql-cluster-kubernetes/
kubectl apply -f .
kubectl get all
Depending on your cluster location and proximity to your location it may take a few minutes to show up everything as ready
kubectl exec deployment/mongo-client -it -- /bin/bash
note: make sure to change the credentials in the 'mongodb-secrets.yaml' file
mongo --host mongo-nodeport-svc --port 27017 -u pankaj -p pankaj