Triển khai ứng dụng

Triển khai ứng dụng lên EKS cluster

  1. Deploy một static Website lên EKS Cluster mình vừa tạo. Để deploy, đầu tiên chúng ta sẽ chạy command sau:
kubectl create deployment fcj-workshop --image=awsfcj/000062

Deploywebsite

awsfcj/00062 là image được build sẵn để sử dụng trong bài lab này

Deploywebsite

  1. Để có thể truy cập Website từ bên ngoài EKS cluster, chúng ta sẽ phải deploy một LoadBalancer Service vào cluster bằng command sau:
kubectl expose deployments/fcj-workshop --type=LoadBalancer --port=80

Deploywebsite

  1. Để xem thông tin về LoadBalancer trên, mình sẽ chạy command sau:
kubectl get svc

Deploywebsite

  1. Copy và dán link trong EXTERNAL-IP vào trình duyệt sẽ truy cập được website

Deploywebsite

  1. Truy cập vào website (nhớ truy cập bằng http thay vì https)

Deploywebsite