New to Kestra?
Use blueprints to kickstart your first workflows.
Audits AWS CloudWatch NAT Gateway metrics to detect ErrorPortAllocation events and outbound internet connectivity drops.
This workflow connects to Amazon CloudWatch via the AWS CLI plugin to sample the ErrorPortAllocation metric across AWS NAT Gateways in the target region. When workloads in private subnets open thousands of concurrent outbound connections to the same destination IP and port, the NAT Gateway exhausts its 55,000 available ephemeral source ports. When errors exceed zero, an urgent Slack alert is dispatched with error totals and mitigation instructions.
io.kestra.plugin.aws.cli.AwsCLI.cloudwatch:GetMetricData permissions.AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, and SLACK_WEBHOOK configured in Kestra.aws ec2 describe-nat-gateways) to include specific gateway IDs in the alert.