Fargate
Definition
AWS Fargate is a serverless compute engine for containers that works with both Amazon Elastic Container Service (ECS) and Amazon Elastic Kubernetes Service (EKS). It allows developers to run containers without managing the underlying infrastructure, automatically scaling and allocating the necessary compute resources. Fargate abstracts the server management, enabling users to focus on application development and deployment.
Secure Settings Example
{
"containerDefinitions": [
{
"name": "my-secure-container",
"image": "my-image:latest",
"essential": true,
"memory": 512,
"cpu": 256,
"logConfiguration": {
"logDriver": "awslogs",
"options": {
"awslogs-group": "/ecs/my-secure-container",
"awslogs-region": "us-west-2",
"awslogs-stream-prefix": "ecs"
}
},
"environment": [
{
"name": "ENV_VAR",
"value": "secure_value"
}
],
"secrets": [
{
"name": "SECRET_ENV_VAR",
"valueFrom": "arn:aws:ssm:us-west-2:123456789012:parameter/my-secret"
}
]
}
]
}
Insecure Settings Example
{
"containerDefinitions": [
{
"name": "my-insecure-container",
"image": "my-image:latest",
"essential": true,
"memory": 512,
"cpu": 256,
"logConfiguration": {
"logDriver": "awslogs",
"options": {
"awslogs-group": "/ecs/my-insecure-container",
"awslogs-region": "us-west-2",
"awslogs-stream-prefix": "ecs"
}
},
"environment": [
{
"name": "ENV_VAR",
"value": "insecure_value"
}
],
"secrets": [
{
"name": "SECRET_ENV_VAR",
"valueFrom": "plaintext_secret_value"
}
]
}
]
}