Code Monkey home page Code Monkey logo

nksdemo's Introduction

Using Cloud Volumes ONTAP as persistant storage in a NKS Kubernetes Cluster

Objectives

This exercise focuses on enabling you to do the following:

  • Create a simple service in a NKS deployed Kubernetes Cluster. As an example, this K8s deployment will create a simple Webservice, using nginx.
export KUBECONFIG=kubeconfig.txt

before connecting CVO Workspace with K8s Cluster

kubectl get sc

kubectl get pv

kubectl get pods --all-namespaces

After K8S with connected with CVO in OCCM

mac$ kubectl get sc

mac$ kubectl get pv

mac$ kubectl create -f NKSDemoPVCforNAS.yaml

mac$ kubectl get pvc

mac$ kubectl create -f NKSDemo_mynginx.yaml
deployment.apps "my-nginx” created

mac$ kubectl get pods

mac$ kubectl expose deployment my-nginx --type=LoadBalancer --name=my-service
service "my-service” exposed

mac$ kubectl describe service my-service

mac$ kubectl get pods


mac$ kubectl exec -it my-nginx-b7b56756c-qdrhr sh
# cd /usr/share/nginx/html

# mount | grep trident
172.23.1.254:/netyrsrzfh_trident_default_persistent_volume_claim_nas_8b126 on /usr/share/nginx/html type nfs4 (rw,relatime,vers=4.1,rsize=65536,wsize=65536,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,clientaddr=172.23.1.226,local_lock=none,addr=172.23.1.254)

# echo "<h1>the quick brown fox jumps over the lazy dog on host $HOSTNAME </h1>" > index.html

mac$ kubectl get pods

nksdemo's People

Contributors

macmurph42 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.