0
0
AWScloud~10 mins

Why managed Kubernetes matters in AWS - Test Your Understanding

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to create a managed Kubernetes cluster using AWS EKS CLI.

AWS
aws eks create-cluster --name my-cluster --role-arn [1] --resources-vpc-config subnetIds=subnet-12345,subnet-67890
Drag options to blanks, or click blank then click option'
Aarn:aws:iam::123456789012:role/LambdaExecutionRole
Barn:aws:iam::123456789012:role/EKSClusterRole
Carn:aws:iam::123456789012:role/S3AccessRole
Darn:aws:iam::123456789012:role/EC2InstanceRole
Attempts:
3 left
💡 Hint
Common Mistakes
Using a role meant for EC2 instances instead of the cluster role.
2fill in blank
medium

Complete the command to update kubeconfig for accessing the managed EKS cluster.

AWS
aws eks update-kubeconfig --name [1]
Drag options to blanks, or click blank then click option'
Amy-cluster
Bmy-old-cluster
Ctest-cluster
Ddev-cluster
Attempts:
3 left
💡 Hint
Common Mistakes
Using a different cluster name that does not exist.
3fill in blank
hard

Fix the error in the command to create a node group for the EKS cluster.

AWS
aws eks create-nodegroup --cluster-name my-cluster --nodegroup-name [1] --subnets subnet-12345 subnet-67890 --node-role arn:aws:iam::123456789012:role/EKSNodeRole
Drag options to blanks, or click blank then click option'
Adefault node group
Bnode group 1
Cnodegroup1
Ddefault-node-group
Attempts:
3 left
💡 Hint
Common Mistakes
Including spaces in the node group name causing syntax errors.
4fill in blank
hard

Fill both blanks to define a Kubernetes deployment YAML snippet for a managed cluster.

AWS
apiVersion: apps/v1
kind: Deployment
metadata:
  name: nginx-deployment
spec:
  replicas: 3
  selector:
    matchLabels:
      app: nginx
  template:
    metadata:
      labels:
        app: nginx
    spec:
      containers:
      - name: nginx
        image: nginx:[1]
        ports:
        - containerPort: [2]
Drag options to blanks, or click blank then click option'
Alatest
B80
C8080
Dstable
Attempts:
3 left
💡 Hint
Common Mistakes
Using invalid image tags or wrong port numbers.
5fill in blank
hard

Fill all three blanks to create a Kubernetes service YAML snippet exposing the deployment.

AWS
apiVersion: v1
kind: Service
metadata:
  name: nginx-service
spec:
  type: [1]
  selector:
    app: [2]
  ports:
  - protocol: TCP
    port: [3]
    targetPort: 80
Drag options to blanks, or click blank then click option'
ALoadBalancer
Bnginx
C80
DClusterIP
Attempts:
3 left
💡 Hint
Common Mistakes
Using wrong service type or mismatched selector labels.