> For the complete documentation index, see [llms.txt](https://docs-epc.gitbook.io/ncs-documents/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs-epc.gitbook.io/ncs-documents/tutorial/kubernetes-on-nipa-cloud-space-with-rancher/kubernetes/kubernetes-rancher-ui.md).

# การใช้งาน Kubernetes ผ่าน Rancher UI

Rancher สามารถทำหน้าที่เป้น Dashbord ให้ผู้ใช้งานสามารถจัดการ Resource และ Workload ใน Kubernetes ผ่านทาง UI ของ Rancher ได้เลย ทำให้ผู้ใช้งานที่ยังไม่เชี่ยวชาญ สามารถทำงานได้ง่ายขึ้น

โดยเมื่อเช้ามายังภายใน Cluster ของ Kubernetes&#x20;

จะมี Menu ดังรูป จะเห็นว่า เราสามารถ กำหนด Cluster and Project Members ที่สามารถเข้ามาใช้งาน Kubernetes Cluster นี่ได้ด้วย

สามารถจัดการ Project โดยการเพิ่มลบ และจัดการ Namespace ให้ไปอยู่ภายใต้ Project เพื่อการจัดการ Resource ในระบบต่างๆ ที่ต้องการใช้ หลาย Namespace ได้ง่ายยิ่งขึ้น

<figure><img src="/files/RUfJndF4W6rCOWcacczB" alt=""><figcaption></figcaption></figure>

ใน Cluster ของ Kubernetes จะประกอบไปด้วย nodes ที่เป็น infrastructure ให้กับ Kubernets&#x20;

และในแต่ละ Node อาจมี Roles ที่แตกต่างกัน เช่น Control Plane , ETCD, Worker&#x20;

โดย เราสามารถตรวจสอบสถานะความพร้อมใช้งานผ่านหน้านี้ได้ เช่น การใช้งาน  CPU , RAM , POD

<figure><img src="/files/pd5UhxoARaLsDPhalkDl" alt=""><figcaption></figcaption></figure>

เมื่อต้องการนำ Application มา Deploy บน Kubernetes จำเป็นต้องระบุ namespace ให้ถูกต้อง

<figure><img src="/files/Yym2HS7n8ggBJ8AfxfdV" alt=""><figcaption></figcaption></figure>

และสามารถ Create Resouce ต่างๆ ผ่านหน้า UI ของ Rancher ได้ โดยจะมีรายละเอียดแตกต่างกันขึ้นอยู่กับ Resource Type นั้นๆ&#x20;

<figure><img src="/files/ANucnoHPcuoagomXtej1" alt=""><figcaption></figcaption></figure>

และ Rancher ยังรองรับการติดตั้ง Application ผ่าน Helm Chart ซึ่งทำให้เราสามารถ Deploy Workload ที่เตรียมไว้แล้วสู่ Kubernetes Cluster ได้

<figure><img src="/files/R9lIA5kRSXt2bttZtyaw" alt=""><figcaption></figcaption></figure>

ตัวอย่าง Application ที่ติดตั้งผ่าน Helm Chart นั้นคือ Ingress-Nginx ที่จะทำหน้าที่เป็น Ingress Controller ให้กับ Request ที่จะเข้ามายัง Workload ที่รันอยู่บน Kubernetes

<figure><img src="/files/fODQNhhpydPOrmjUlRqQ" alt=""><figcaption></figcaption></figure>

ตัวอย่าง Service ที่เกิดขึ้นบน namespace ingress-nginx โดยใช้ Type เป็น LoadBalancer เพื่อที่ใช้ Resource ของ Cloud ในการทำหน้าที่ Loadbalance ให้กับ Cluster ของ Kubernetes

<figure><img src="/files/Gne3f0CmDG5NRq8JhckD" alt=""><figcaption></figcaption></figure>

ตัวอย่าง Storage Classes ที่มีการ Integrate กับ Cloud ทำให้สามารถใช้ Block Storage นอกเหนือจาก Kubernetes Node มาเก็บข้อมูลที่สำคัญได้

<figure><img src="/files/9YUEFlDif7sYJsaUmXEN" alt=""><figcaption></figcaption></figure>

ตัวอย่าง PersistanceVolumeClaims ที่สร้าขนาด 2Gi&#x20;

<figure><img src="/files/HGWsb8a4GIBUg5TjiZIP" alt=""><figcaption></figcaption></figure>
