When userdata exits with an error, the error handling checks output and tries to classify the error to print out some helpful message (with content type).
This message is confusing when scripts themselves run into issues that "grok" as exec format errors (intended to help determine issues with the provided userdata script itself, not from errors in the userdata script's execution).
When userdata exits with an error, the error handling checks output and tries to classify the error to print out some helpful message (with content type).
This message is confusing when scripts themselves run into issues that "grok" as exec format errors (intended to help determine issues with the provided userdata script itself, not from errors in the userdata script's execution).
Concerned line:
https://github.com/aws/ec2-macos-init/blob/97875d5249a9b376d86cb263d2687c6dba03b38d/lib/ec2macosinit/userdata.go#L54
Instead, we should only print the helpful message when the userdata itself is found to be an unsuitable format.