Coder Social home page Coder Social logo

Comments (22)

ambrons avatar ambrons commented on August 16, 2024 2

I'm looking for this same feature for the purpose of setting up the cloudwatch logging per this documentation:

http://docs.aws.amazon.com/AmazonECS/latest/developerguide/using_cloudwatch_logs.html#cwlogs_user_data

from amazon-ecs-cli.

rms1000watt avatar rms1000watt commented on August 16, 2024 2

+1 Updates?

from amazon-ecs-cli.

deadanon avatar deadanon commented on August 16, 2024 2

This would save me from manually updating the CloudFormation template of the cluster each time I want to make a minor User-Data change.

from amazon-ecs-cli.

danknittle avatar danknittle commented on August 16, 2024 1

+1 Any update on this?

from amazon-ecs-cli.

PettitWesley avatar PettitWesley commented on August 16, 2024 1

@2opremio @vultron81 @kaihendry @ambrons @PospolitaNV @komw @codepushr @djones @amit-bridg @deadanon @rms1000watt @danknittle @kristianpaul @schickling @ambrons download 1.9.0 and check out how to use user data with the CLI in our README 😁💃🏾

from amazon-ecs-cli.

vultron81 avatar vultron81 commented on August 16, 2024

+1

from amazon-ecs-cli.

2opremio avatar 2opremio commented on August 16, 2024

@samuelkarp Would you be open to a PR implementing this?

from amazon-ecs-cli.

samuelkarp avatar samuelkarp commented on August 16, 2024

@2opremio, we're currently looking into how we'd like to support this use-case. If you want to send a PR, we can definitely take a look, but we want to make sure we can support the different types of content that can be set as user data.

from amazon-ecs-cli.

2opremio avatar 2opremio commented on August 16, 2024

@samuelkarp My plan was just to append whatever was provided to a command line flag (e.g. --extra-user-data) to the existing User Data script.

Since you have bigger plans, I will just stay put on this one.

from amazon-ecs-cli.

kaihendry avatar kaihendry commented on August 16, 2024

I'm looking for support for this feature since I don't see another way of setting up monitoring agents like http://docs.datadoghq.com/integrations/ecs/ & persistant mounts otherwise.

Else I guess I would have to create forks of amazon-ecs-optimized images, which is a little annoying to do.

from amazon-ecs-cli.

schickling avatar schickling commented on August 16, 2024

+1

from amazon-ecs-cli.

kristianpaul avatar kristianpaul commented on August 16, 2024

+1

from amazon-ecs-cli.

amit-bridg avatar amit-bridg commented on August 16, 2024

how do i add following to ecs.config for clusters created using ecs-cli up

ECS_ENABLE_CONTAINER_METADATA=true
aws/amazon-ecs-agent#709

It seems like simple use cases are not that easily supported and i have to keep hacking :(

from amazon-ecs-cli.

djones avatar djones commented on August 16, 2024

+1. Specifically need to run this:

echo vm.max_map_count=262144 >> /etc/sysctl.conf

on the host machine to make Elasticsearch happy. https://www.elastic.co/guide/en/elasticsearch/reference/current/vm-max-map-count.html

from amazon-ecs-cli.

codepushr avatar codepushr commented on August 16, 2024

+1 Need this for ECS_ENGINE_TASK_CLEANUP_WAIT_DURATION :/

from amazon-ecs-cli.

komw avatar komw commented on August 16, 2024

+1

from amazon-ecs-cli.

PospolitaNV avatar PospolitaNV commented on August 16, 2024

+1

from amazon-ecs-cli.

allisaurus avatar allisaurus commented on August 16, 2024

Support for providing custom user data was added in 1.9.0. Resolving.

from amazon-ecs-cli.

mailjunze avatar mailjunze commented on August 16, 2024

NOTE : "--extra-user-data" this flag takes a file name as its argument.
Example :
ecs-cli up --instance-role ecsInstanceRole --keypair jhsgsgs --vpc vpc-jshsgsgb --security-group sg-kjhjkhjgjhgj --subnets subnet-jhgjhg --extra-user-data ud.sh --launch-type EC2 --force

from amazon-ecs-cli.

PettitWesley avatar PettitWesley commented on August 16, 2024

@mailjunze yup that's correct. Do you think the README or command help text should be re-worded in any way? Was it unclear from those that a file argument is needed?

from amazon-ecs-cli.

mailjunze avatar mailjunze commented on August 16, 2024

@PettitWesley It's mentioned in the README here but not in the official AWS docs: ecs-cli up - Specifying User Data - https://docs.aws.amazon.com/AmazonECS/latest/developerguide/cmd-ecs-cli-up.html#cmd-ecs-cli-up-userdata. I submitted a feedback to update it.

I understand extra-user-data can be shell scripts or cloud-init directives files. Shell scripts are straightforward, However, I am struggling with cloud-init directives files. May I know what should be the content and file extension for cloud-init directives files. An example file would be great.

from amazon-ecs-cli.

PettitWesley avatar PettitWesley commented on August 16, 2024

@mailjunze I'm not an expert on this myself, but I'll try to help. So the file extension doesn't matter, what matters is the first line in your file, this determines what type of file cloud-init will parse/run it as. Valid first line values are things like #!/bin/sh, #include, #cloud-config, #upstart-job, or #cloud-boothook. See this documentation for a full list and explanation. Note that the ECS CLI always packages all of your user data file into a mime-multipart archive; this means that adding one of the valid values as the first line of your file is required. See here for some examples.

Let me know if you run into any issues.

from amazon-ecs-cli.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.