I am currently creating a launch template using terraform aws_launch_template
resource. I need to pass in user data and i do so using
user_data =filebase64("file_path/file_name.sh")
. I need to have variables inside my userdata file (file_name.sh
). What is the best way to accomplish this ?
using variables in aws launch template userdata (terraform)
4.4k views Asked by Choolai Raj At
2
You're using templatefile to pass variable, then you'll need the function base64encode to provide user_data required by launch_teamplate. Try this: