Skip to content
This repository has been archived by the owner on Sep 10, 2019. It is now read-only.

Kubectl usage

Sumanth edited this page Mar 2, 2017 · 1 revision

Install Kubectl. Follow the steps in this - https://kubernetes.io/docs/user-guide/prereqs/

  1. Load the kube-config for the dev cluster, in your ~/.kube/config

  2. Run the below command to check if you are able to use kubectl to get a list of nodes in dev cluster kubectl get nodes Now, you are ready to use kubectl to deploy your containers.

  3. Ex: To deploy a egovio/pgr-rest:v1.1 container, kubectl set image deployments/pgr-rest pgr-rest=egovio/pgr-rest:v1.1 --namespace=pgr

  4. To check the status of deployment, kubectl rollout status deployments/pgr-rest —namespace=pgr

  5. To access kubernetes dashboard, run a proxy server locally. kubectl proxy This should a proxy server at localhost:8001 You can hit the dashboard at http://localhost:8001/ui and check your pod status, logs etc.