-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(codedeploy) invalid package name causing yum failures for CentOS 8 and presumably RHEL 8 #16655
Comments
Thanks for opening the issue @GregThoen. I agree with all of your points. It seems that actually always installing the AWS CLI might not be a great idea - perhaps we should first run a To unblock your migration to a newer CDK, you can turn off the automatic CodeDeploy agent installing with the Thanks, |
Yeah - I think that will work too. In particular, it should work for us, since we have it installed in the AMI already. I think in general, for other people, though, one of the two things I mentioned might end up being better, so that it can work with RHEL & CentOS when not already installed -- just a suggestion. :) |
Yep, agreed - after |
This issue has not received any attention in 1 year. If you want to keep this issue open, please leave a comment below and auto-close will be canceled. |
The Issue
We have been using an older version of the CDK (1.84.0, I believe), and want to now upgrade to the latest, but the roadblock we've hit is that the UserData script CDK creates for autoscaling groups using codedeploy has changed and is now causing failures that keep instances from launching.
The fixes for issues #13654 and #13755, while apparently working for Amazon linux, break it for CentOS 8 (and presumably RHEL 8, off which CentOS 8 is based). The only mainstream yum repository I'm aware of for CentOS/RHEL that contains the aws cli is the EPEL (Extra Packages for Enterprise Linux) repository. When this repository is being used (set up as documented at https://aws.amazon.com/premiumsupport/knowledge-center/ec2-enable-epel/), the name of the aws cli package is awscli, not aws-cli.
Environment
Other information
In the past, since we're using a CentOS AMI we've set up, we actually installed the AWS CLI tools the way Amazon recommends (https://docs.aws.amazon.com/cli/latest/userguide/install-cliv2-linux.html or https://docs.aws.amazon.com/cli/latest/userguide/install-linux.html), which is downloading the package directly from AWS and installing it, rather than using non-Amazon-created packages in a non-AWS package repository. The UserData script generated by the version of CDK we've been using (1.84.0) also would try to do a "yum install awscli" similar to what 1.124.0 does (but obviously awscli instead of aws-cli), and even though we hadn't configured our instances to use the EPEL repository (so this yum command failed), it didn't matter because (a) the script didn't do a "set -e" (like the current one does) so it ignored this error and (b) since the AMI we're using for the autoscaling group instances already has the CLI tools installed (by us manually as recommended by Amazon), the rest of the script (which needed the aws cli tools to download and then install the codedeploy agent) works fine.
For what it's worth, here are some obvious ways of fixing this:
Thanks,
Greg
The text was updated successfully, but these errors were encountered: