How to use s3 for ec2 user-data for sending system log to cloudwatch?

Doc provides a user data script (at the bottom of this posting) for sending system logs to cloudwatch (https://docs.aws.amazon.com/AmazonECS/latest/developerguide/using_cloudwatch_logs.html) I’d like to change it to as a file downloadable from s3 #!/bin/bash yum install -y aws-cli aws s3 cp s3://your_bucket_name/ecs.config /etc/ecs/ecs.config How do I change the following to put into s3://your_bucket_name/ecs.config ? Content-Type: multipart/mixed; boundary=”==BOUNDARY==”…