0
0
AWScloud~10 mins

Why container services matter on 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 specify the AWS service used to run containers.

AWS
service = "[1]"
Drag options to blanks, or click blank then click option'
AEC2
BLambda
CS3
DECS
Attempts:
3 left
💡 Hint
Common Mistakes
Choosing EC2 which is for virtual machines, not container orchestration.
Selecting S3 which is for storage, not containers.
2fill in blank
medium

Complete the code to define the container orchestration tool AWS offers.

AWS
orchestration_tool = "[1]"
Drag options to blanks, or click blank then click option'
AKubernetes
BEKS
CDocker
DLambda
Attempts:
3 left
💡 Hint
Common Mistakes
Choosing Docker which is a container platform but not AWS's orchestration service.
Selecting Lambda which is for serverless functions.
3fill in blank
hard

Fix the error in the code to correctly launch a container task on AWS.

AWS
task_definition = client.register_task_definition(family='my-task', containerDefinitions=[[1]])
Drag options to blanks, or click blank then click option'
A{'name': 'app', 'image': 'myimage'}
B{'container_name': 'app', 'image': 'myimage'}
C{'name': 'app', 'image_url': 'myimage'}
D{'name': 'app', 'img': 'myimage'}
Attempts:
3 left
💡 Hint
Common Mistakes
Using incorrect keys like 'image_url' or 'img' instead of 'image'.
Naming the container key as 'container_name' instead of 'name'.
4fill in blank
hard

Fill both blanks to create a dictionary that maps container names to their CPU shares and memory limits.

AWS
container_resources = { '[1]': [2] }
Drag options to blanks, or click blank then click option'
Aapp
B{'cpu': 256, 'memory': 512}
Cweb
D{'cpu': 1024, 'memory': 2048}
Attempts:
3 left
💡 Hint
Common Mistakes
Using the wrong container name like 'web'.
Swapping CPU and memory values.
5fill in blank
hard

Fill all three blanks to define a service that runs 3 tasks of a container named 'api' with a load balancer.

AWS
service_config = {
  'serviceName': '[1]',
  'desiredCount': [2],
  'loadBalancers': [[3]]
}
Drag options to blanks, or click blank then click option'
Aapi-service
B3
C{'targetGroupArn': 'arn:aws:elasticloadbalancing:...', 'containerName': 'api', 'containerPort': 80}
D5
Attempts:
3 left
💡 Hint
Common Mistakes
Using wrong service names or counts.
Incorrect load balancer dictionary format.