Navigation Menu |
- Comprehensive Blog on Oracle Kubernetes Engine – getting started
- Configure Network for OKE
- Create 3 Worker Node and 2 Subnets
- Create Kubernetes Cluster
- Enable Cluster access through Command line interface
- Getting onto Kubernetes Dashboard
- Running Ngnix on Load Balancer
- Pod Configuration using a YAML Deployment
Starting Kubernetes Dashboard on Host Machine
oracle@oracle:~$ kubectl proxy error: Error loading config file "/home/oracle/.kube/config": read /home/oracle/.kube/config: is a directory oracle@oracle:~$ export KUBECONFIG=$HOME/kubernetes/kubeconfig3 oracle@oracle:~$ kubectl proxy Starting to serve on 127.0.0.1:8001
the Browser URL will be
http://localhost:8001/api/v1/namespaces/kube-system/services/https:kubernetes-dashboard:/proxy
This will launch login page upload the file that we generated in previous chapter
Login to Kubernetes Dashboard
Deploy Sample Ngnix App on Cluster using Kubectl
oracle@oracle:~/kube/hello$ export KUBECONFIG=$HOME/kubernetes/kubeconfig3 oracle@oracle:~/kube/hello$ kubectl run nginx --image=nginx --port=80 --replicas=3 kubectl run --generator=deployment/apps.v1beta1 is DEPRECATED and will be removed in a future version. Use kubectl create instead. deployment.apps/nginx created oracle@oracle:~/kube/hello$ kubectl get deployments NAME DESIRED CURRENT UP-TO-DATE AVAILABLE AGE nginx 3 3 3 3 37s oracle@oracle:~/kube/hello$ kubectl get pods -o wide NAME READY STATUS RESTARTS AGE IP NODE nginx-6f858d4d45-jmnw5 1/1 Running 0 1m 10.244.2.2 132.145.175.245 nginx-6f858d4d45-whc4k 1/1 Running 0 1m 10.244.1.2 129.213.39.155 nginx-6f858d4d45-xk257 1/1 Running 0 1m 10.244.0.8 129.213.148.25
View the Deployment on Kubernetes Dashboard
Running on Load Balancer
oracle@oracle:~/kube/hello$ kubectl expose deployment nginx --port=80 --type=LoadBalancer service/nginx exposed oracle@oracle:~/kube/hello$
Check the Load Balancer tab under Networking Menu
Check the Public IP of Load balancer to view Nginx home page
What Next >> 07 Pod Configuration using a YAML Deployment