Key Concepts Flashcards

1
Q

What is ECS?

A

Elastic container service is a fully managed cloud container orchestration service. It runs multiple containers using EC2 instances OR Fargate

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

ECS Cluster

A

a logical grouping of EC2 instances or Fargate resources are run

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Task

A

a single instance of running a container or a group of containers that define how a containerized application should be deployed

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Task Definition

A

a template that describes the source of the application image, resources required in the terms of CPU and memory units container, and host port mapping, and other critical info

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Why use ECS over EC2?

A

Although from a high level they appear to host workloads and are pretty similar, on a deeper level they are suited for different types of workloads and are different.

ECS (Elastic Container Service):
1. Container Orchestration: Manages and scales containers automatically.
2. Simplified Management: No need to manage underlying EC2 instances if using Fargate.
3. Optimized Scaling: Easily scales containers up or down based on demand.
4. Integration: Built-in support for AWS services (e.g., IAM, CloudWatch).
5. Cost Efficiency: Pay only for resources used (compute & memory), especially with Fargate.

EC2 (Elastic Compute Cloud):
1. Full Control: Offers more flexibility with instance types and configurations.
2. Custom Configurations: Ideal for custom environments that need full OS control.
3. Persistent Workloads: Better suited for applications needing long-running processes or custom networking.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Availability Zone (AZ)

A

a distinct location within an AWS Region. Each AWS Region consists of multiple Availability Zones, which are designed to be isolated from failures in other zones. This provides redundancy and fault tolerance.
1. physical locations
2. high availability
3. low latency
4. Redundancy and Disaster Recovery
5. Usage in AWS Services

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is an ECS service?

A

A long-running ECS task that can be managed, scaled, and monitored ensuring the desired number of tasks are always running

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

How does ECS manage access control?

A

Through IAM roles and policies

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Which service integrates with ECS for secrets management?

A

AWS Secrets Manager or Systems Manager Parameter Store for managing sensitive data

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is ECR?

A

A fully managed container image registry service that allows you to store, manage, and deploy Docker container images

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

How does ECR integrate with ECS?

A

ECR stores container images that ECS pulls to deploy and run tasks

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Target group

A

a set of registered targets (ECS tasks) to which a load balancer distributes traffic. It contains health check settings for monitoring targets

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Load Balancer

A

distributes incoming application traffic across multiple tasks or containers to ensure high availability and reliability

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Service Directory

A

a feature that enables ECS tasks to automatically register with DNS. This makes it easy to find and connect to tasks across clusters

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

capacity provider

A

defines the infrastructure capacity available for the tasks in your cluster. ECS uses capacity providers to determine where to place tasks

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

IAM Roles for ECS

A
  1. Task Role: Permissions for the tasks to interact with AWS services
  2. Execution Role: Permissions for ECS to pull images, write logs, etc
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

ECS Service Auto Scaling

A

Adjusts the number of tasks in your service based on demand, helping manage scaling automatically

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Placement Strategies and Contraints

A

Defines rules for task placement, such as balancing tasks across availability zones or restricting placement to specific instances

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

ECS Agent

A

A component that runs on container instances and communicates with ECS API to handle task operations

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

Task Definition Revision

A

Every time a task definition is updated, a new revision is created. ECS uses these revisions to run tasks, so you can revert to previous versions if needed

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

Container Defintion

A

Part of a task definition where that specifies individual container configurations, such as image, port mappings, environment variables, logging, and storage

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

Port Mapping

A

specifies which ports are open to the external network and which are connected to the container within the task definition

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

Environment Variables

A

variables passed to the containers, often used to configure containerized applications, such as database connection strings or API keys

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

Log configuration

A

defines how logs from containers are managed. ECS can send logs to AWS services like CloudWatch or to a local file

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Volumes
Specifies data volumes used by containers, defining where data is stored and shared between containers within the same task
24
Network Mode
defines how the container's networking is configured. Options include bridge, host, awsvpc, and none
25
Task Placement Strategy
Rules that determine where tasks s are placed within a cluster, such as binpack, random, or spread strategies for balancing resources
26
Task Placement Contraints
Defines specific conditions that must be met for tasks to be placed on container instances, such as instance attributes or availability zones
27
CPU and Memory Reservations and Limits
Specifies minimum (reservation) and maximum (limit) CPU and memory resources a container can use, controlling it's performance
28
Task Lifecycle States
States a task be in, such as pending, running, stopping, stopped
29
Desired Count
The number of task instances ECS attempts to maintain for a service. Auto scaling adjusts this automatically
30
Service Scheduler
A component responsible for managing and scheduling the tasks within a service. Ensures desired count and placement constraints are met
31
Primary and Active Service Deployments
In deployments, the primary service is the one actively serving traffic, while active deployments are transition or rolling out
32
Service Discovery Namespace
Provides a DNS name for your service, allowing it to be discoverable within a namespace
33
Health Check Grace Period
The period to wait after a task starts before checking its health status, allowing time for start up processes
34
Service Event
An event related to the service lifecycle, like service updates, task state changes, or scaling activities
35
Elastic Network Interface (ENI)
a virtual network interface attached to tasks in awsvpc mode, allowing them to have their own IP addresses within a VPC
36
ECS Service Security Groups
Controls inbound and outbound traffic for tasks, applied at the network interface level
37
Elastic Load Balancing Health Checks
Checks the health of tasks behind a load balancer. Tasks that fail health checks are automatically terminated and replaced
38
Task Role Policy
A specific IAM policy attached to a task role that defines what resources and actions the tasks can access
39
CloudWatch Alarms for ECS
Monitors the performance of tasks and services, triggering actions based on conditions like CPU usage or task count
40
Autoscaling Policies for ECS Services
Policies that define scaling thresholds for services, such as scaling up when CPU usage exceeds a certain percentage
41
Subnet
a segment within a VPC that divides the IP address range into smaller, manageable segments, allowing for organized resource isolation
42
What are the two main types of subnets in ECS?
1. Private- are not directly accessible and usually access the internet through a NAT Gateway 2. Public- accessible from the internet
43
What is a NAT Gateway?
A managed service that allows instances in private subnets to connect to the internet or AWS services for outbound traffic, while blocking inbound internet connections for added security
44
What is the purpose of subnets in ECS task networking?
Subnets define where the task run within a VPC, determining their network reachability and security level (internet access or internal only)
45
How do you specify subnets for ECS tasks?
You assign subnets to tasks in the networking configuration of a task or service determining if they are public or private subnets
46
Why are security groups important in subnet configuration?
Security groups act as virtual firewalls, defining inbound and outbound rules for tasks in awsvpc mode, providing another layer of security in addition to subnet ACLs
47
Why should ECS tasks be deployed across multiple subnets in different Availability Zones?
To ensure high availability and redundancy, as this setup provides fault tolerance in case one availability zone goes down
48
How does subnet selection affect load balance placement in ECS?
For public-facing services, load balancers should be in public subnets, for internal services, load balancers can be in private subnets
49
What is the advantage of enabling IPv4 and IPv6 for ECS subnets
Dual-stack networking allows tasks to support both IPv4 and IPv6, accommodating modern internet protocol standards and expanding address availability
50
How do VPC peering and subnets interact?
Subnets within peered VPCs can communicate based on route table configurations, enabling ECS tasks to access resources across VPCs
51
What role do route tables play in subnet configuration?
Route tables define traffic routes for subnets, directing traffic within the VPC or to external resources like the internet via an Internet Gateway
52
What is VPC Peering in AWS?
A network connection between 2 VPCs that enable them to route traffic between each other privately, as if they were within the same network. It allows resources in different VPCs to communicate without using the internet
53
What is route configuration in aws?
Involves setting rules within a route table that specify how traffic is directed within a VPC, including routes to subnets, internet gateways, NAT gateways, and other VPCs
54
what is an Elastic Network Interface?
a virtual network interface that can be attached to tasks in awsvpc networking mode, providing network connectivity and flexible IP configurations
55
What are ECS Placement Constraints?
Rules that limit task placement based on factors like instance attributes or availability zones, ensuring tasks run on appropriate resources
56
What is the service scheduler in ECS?
Responsible for managing task placement and maintaining the desired count of tasks for service, ensuring they remain running and healthy
57
what are task environment variables in ECS?
user-defined variables that can be passed to containers within a task, allowing configuration customization for different environments
58
What is a FireLens Log Router in ECS?
A log router that enables advanced log forwarding capabilities for ECS tasks, allowing logs to be sent to multiple destinations, including S3, CloudWatch, and third-party logging service
59
What is an ECS Deployment Controller?
Manages how service updates are deployed, with options like rolling update (default) and blue/green deployments for updating containers with minimal downtime
60
What is ECS Anywhere feature?
allows you to run and manage ECS tasks on non-aws infrastructure, including on-premises servers and other cloud providers, extending ECS management capabilities beyond aws
61
Target Group
a logical grouping of ECS tasks that a load balancer directs traffic to. Each task within a service is registered as a target in the target group
62
Load Balancer Listener
a process that checks for connection requests on a specified protocol and port, directing traffic to registered targets based on listener rules
63
What is blue/green deployment in ECS?
A release strategy that allows you to deploy a new version of service(green), alongside the current version(blue), switching traffic only once the new version is confirmed to be working
64
What is the primary benefit of blue/green deployment?
It minimizes downtime and reduces risk by allowing testing of the new version in production before fully switching traffic from the old version, enabling quick rollback if need be
65
How does traffic shifting work in blue/green deployment?
Traffic is gradually or immediately redirected from the blue environment to the green environment through a load balancer, allowing a controlled transition
66
What is the role of target groups in blue/green deployment?
First target group is for the blue environment and the second for the green environment. Traffic is directed to the appropriate target group based on deployment status
67
What is Amazon Route 53?
Amazon Route 53 is a scalable and highly available Domain Name System (DNS) web service that provides domain registration, DNS management, and health checking, allowing routing of end-user requests to AWS services and external resources.
68
What are the key features of Amazon Route 53?
Domain Registration: Purchase and manage domain names. DNS Management: Route traffic to AWS services and external endpoints. Health Checks: Monitor the health of resources and route traffic accordingly. Traffic Routing: Supports various routing policies (e.g., simple, failover, geolocation, etc.). Highly Scalable and Available: Ensures quick and reliable DNS resolution for global traffic.
69
What is the role of DNS in AWS ECS?
Service Discovery: Allows containers to discover and communicate using service names. Amazon Route 53 Private DNS: Provides private DNS resolution for ECS services within a VPC. Internal Load Balancing: Routes traffic using the DNS of Application Load Balancers (ALBs) or Network Load Balancers (NLBs). Networking Mode (awsvpc): Provides DNS names for tasks to communicate using ENIs and private IPs. External Communication: Resolves external domain names for internet access.