Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more

This walkthrough deploys a sample application to Amazon EKS, verifies that its Pods and service are working, and shows why the service is not public by default. It uses a standard EKS cluster with managed nodes—not EKS Auto Mode—and assumes you have AWS credentials and permission to create the required resources. For a first cluster, AWS describes eksctl as the simpler getting-started route; the console-and-CLI route exposes more of the underlying resource setup.

Choose the cluster setup route

The application steps are the same whichever supported cluster setup route you choose. Pick one of these before the demo, and follow its current AWS instructions for creating and deleting the cluster.

This walkthrough does not use Auto Mode. AWS maintains separate guidance for that cluster mode; do not mix its instructions with the standard managed-node-group path.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Prepare credentials, networking, and tools

For a cluster-creation demo, have an AWS identity authorized to create and manage the cluster resources, a compatible VPC and subnets, AWS CLI, and kubectl. The AWS eksctl example requires at least two subnet IDs. See AWS: Create an Amazon EKS cluster and AWS: Set up to use Amazon EKS for account and networking preparation.

Install versions supported by the cluster you intend to create. EKS and its tools change over time, so check AWS’s current kubectl and eksctl setup guidance immediately before the demo rather than treating an old version number as a permanent requirement.

If a cluster already exists, confirm it has at least one node and that your AWS identity can access it. The sample deployment guide assumes both a reachable cluster and a working kubectl connection.

Create or select the cluster, then connect kubectl

Complete cluster creation using the route you selected above, including its compute setup. If you are connecting to an existing cluster, skip creation and use its AWS region and exact cluster name in the command below.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  1. Configure the kubeconfig context for the target cluster. Replace the example values with the cluster’s region and name:
    aws eks update-kubeconfig --region REGION --name CLUSTER_NAME
    AWS documents this process in Connect kubectl to an EKS cluster by creating a kubeconfig file.
  2. Check that the active context can reach the cluster:
    kubectl get svc
    A response listing services confirms a connection to a Kubernetes API. If the command fails, verify the selected AWS credentials, region, cluster name, kubeconfig context, and access permissions before applying the app manifest.

Deploy the sample application

AWS’s Linux sample creates a namespace, deploys three replicas of its sample application, and exposes them through a ClusterIP service. Apply the sample manifest using the official steps at Deploy a sample application on Linux. The commands are:

kubectl create namespace eks-sample-app
kubectl apply -f https://raw.githubusercontent.com/kubernetes/website/main/content/en/examples/service/load-balancer-example.yaml -n eks-sample-app

The manifest creates the deployment and service in the eks-sample-app namespace. The deployment’s desired replica count is three; Kubernetes must schedule those Pods onto available cluster compute and report them ready.

Verify the Pods, deployment, and service

Inspect the resources in the namespace and check that the intended Pods are ready:

kubectl get all -n eks-sample-app

Then inspect the service details and its selector:

kubectl describe service eks-sample-service -n eks-sample-app

Confirm that the service selector corresponds to the sample Pods and that the deployment has its three replicas ready. If Pods are pending or not ready, inspect their status and events before treating the application as deployed; service creation alone does not prove that the workload is healthy.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Understand whether the service is reachable from the internet

The sample’s ClusterIP service is reachable only from inside the cluster. It does not give the application a public endpoint. To demonstrate external access, add an ingress or load-balancing arrangement and verify that configuration separately. AWS points to the AWS Load Balancer Controller as one option; its installation and configuration are additional steps, not part of the sample deployment commands above.

  • Internal-only demo: Keep ClusterIP and show the workload and service from Kubernetes.
  • External-access demo: Configure an ingress or load balancer appropriate to the cluster, then test the resulting endpoint. Do not present the sample ClusterIP address as internet-facing.

Clean up the demo environment

Delete the resources you created when the demonstration is over. Remove the sample namespace with kubectl delete namespace eks-sample-app. If you created a cluster for the demo, use the cleanup instructions for the exact creation route—eksctl or console and CLI—and remove any separately created load-balancing resources. Deleting Kubernetes objects does not, by itself, delete the EKS cluster or every AWS resource associated with it.

AWS describes its example materials as intended for learning and testing, not production use: Learn Amazon EKS by example.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.