AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud...

22
AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9 th 2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services

Transcript of AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud...

Page 1: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

AWS Fargate platform version 1.4

AWS Cloud Containers ConferenceJuly 9th 2020

Massimo Re FerrèDeveloper Advocate @ Amazon Web Services

Page 2: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

What is Fargate?“AWS Fargate is a serverless compute engine for containers” Read: you don’t have to run (and manage) VMs to run containers

Fargate works with both ECS and EKS You can deploy both ECS tasks and Kubernetes pods on Fargate

https://aws.amazon.com/blogs/containers/the-role-of-aws-fargate-in-the-container-world/

Page 3: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

Why Fargate?Task and Pod isolation (1 task/pod : 1 VM)

No EC2 instance to manage, patch, scale, deploy, etc.

You can focus on the application Vs the infrastructure details

Page 4: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

The EC2 flow at 33,000 feet

Amazon EC2

Customer AccountAWS

VPC

TaskService

You have to manage this capacity (e.g., with ASGs)

Run a task on EC2for me, please

EC2

ENIAmazon ECS

Page 5: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

The Fargate flow at 33,000 feetCustomer AccountAWS

VPC

AWS Fargate

Run a container on FARGATE for me, please

You don’t have tomanage capacity

FARGATE

TaskService

ENIAmazon ECS

Page 6: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

What are Fargate platform versions?It represents a combination of OS and container runtime componentsFargate platform versions provide a consistent behavior

A new platform version is released when there is a substantial stack changeAvoid impacting customers with changes in the underlying OS or container runtime

Fargate ”platform versions” only apply when using ECS EKS has its own notion of platform versions (which includes Fargate-related features)

https://aws.amazon.com/blogs/containers/aws-fargate-platform-versions-primer/

Page 7: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

Do all new features require a new platform version?New individual features do not require a brand new platform version New features are added to existing platform versions progressively

Page 8: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

Demo(s)

Fargate in action

Page 9: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

Fargate platform version 1.4: new featuresEFS integration

20GB ephemeral volume

New task ENI flows

Network performance in CloudWatch Container Insights

Support for the CAP_SYS_PTRACE Linux capability

Network stats available in task metadata v4

AZ attribute now available in all task metadata

Containerd is replacing Docker as the container runtime

https://aws.amazon.com/blogs/containers/aws-fargate-launches-platform-version-1-4/

Page 10: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

EFS consumption (pre-integration)

Task

Container 1

Container 2

Amazon ECS

Amazon EC2 AWS FargateAmazon EFS

File system

XExplicit configurations

dockerVolumeConfiguration

Page 11: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

EFS integration

Task

Container 1

Container 2

Amazon ECS

Amazon EC2 AWS Fargate

EFSVolumeConfiguration

Amazon EFS

File system

Page 12: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

EFS integration

https://aws.amazon.com/blogs/containers/developers-guide-to-using-amazon-efs-with-amazon-ecs-and-aws-fargate-part-3/

Page 13: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

20GB ephemeral volumeUp to PV 1.3: 10GB for Docker storage + 4GB for volume mountsThese two storage spaces have hard boundaries

With PV 1.4: 20GB of flat storage (for Docker + volume mounts)Just restart your task with the new PV to take advantage of the additional storage

https://docs.amazonaws.cn/en_us/AmazonECS/latest/developerguide/fargate-task-storage.html

Page 14: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

New task ENI flows

https://docs.amazonaws.cn/en_us/AmazonECS/latest/developerguide/fargate-task-storage.html

Page 15: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

New task ENI flows – diagram

Page 16: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

Network performance in Container InsightsUp until platform version 1.3 Fargate tasks net stats were not available Only CPU, Memory and Disk metrics were available

With Fargate PV 1.4 Container Insights can monitor all subsystemsFargate tasks can be monitored for CPU, Memory, Disk and Network

Page 17: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

Support for the CAP_SYS_PTRACE Linux capability

https://sysdig.com/blog/falco-support-on-aws-fargate/

Page 18: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

New and richer task metadata (net stats and AZ) With PV 1.4, network stats are available with task metadata v4This complements Container Insights and allows our partners to have access to the same data

With PV 1.4, AZ placement is available with task metadata v4You can now introspect which AZ the Fargate task has been deployed to

Page 19: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

Example of a partner leveraging Fargate net stats

https://www.datadoghq.com/blog/monitor-aws-fargate/

Page 20: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

Containerd is replacing Docker

https://aws.amazon.com/blogs/containers/under-the-hood-fargate-data-plane/

Page 21: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

RecapFargate is a serverless platform to run containers Available to both ECS and EKS

Fargate uses the notion of “platform versions”This helps with substantial changes in the Fargate stack

Fargate platform version 1.4 introduces a number of new featuresFor example, the EFS integration for stateful workloads

Page 22: AWS Fargate platform version 1 · 8/21/2020  · AWS Fargate platform version 1.4 AWS Cloud Containers Conference July 9th2020 Massimo Re Ferrè Developer Advocate @ Amazon Web Services.

Thanks for watching and keep in touch!

Massimo Re FerrèMail: [email protected]

Twitter: @mreferreGitHub: github.com/mreferre