Step 5: Clean up resources
If you no longer need the host-level log collection, remove the following resources to avoid unnecessary charges:
Delete or drain the compute environment that uses the launch template.
Delete the launch template from the Amazon EC2 console or by running
aws ec2 delete-launch-template.Detach and delete the
BatchHostLogsS3AccessIAM policy from your instance role.Empty and delete the Amazon S3 bucket, or remove only the
ecs-logs/andfluent-bit/prefixes if the bucket is shared with other workloads.If you set
minvCpusto a non-zero value for testing, reset it to zero to avoid unnecessary costs.