Skip to content
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

fix amazon linux1 platform and version detection #394

Merged
merged 1 commit into from
Feb 14, 2024
Merged

Conversation

siddhu208
Copy link
Contributor

The case statement for platform detections seems to have a string for wildcard (*) which fails to fetch metadata for amazon linux 1 during chef install. Fixing this.

Description

We encountered many instances running Amazon Linux 1 throwing the following output, it looks like the platform and version are not correctly updated because of the wildcard being a string in the case statement.
amazon linux ami 2018.03 x86_64
Getting information for chef stable for amazon linux ami...
downloading https://omnitruck.chef.io/stable/chef/metadata?v=&p=amazon linux ami&pv=2018.03&m=x86_64
to file /tmp/install.sh.27900/metadata.txt
trying wget...
trying curl...
cat: /tmp/install.sh.27900/metadata.txt: No such file or directory

grep: /tmp/install.sh.27900/metadata.txt: No such file or directory
downloaded metadata file is corrupted or an uncaught error was encountered in downloading the file...
Version:

Please file a Bug Report at https://github.com/chef/omnitruck/issues/new
Alternatively, feel free to open a Support Ticket at https://www.chef.io/support/tickets
More Chef support resources can be found at https://www.chef.io/support

Please include as many details about the problem as possible i.e., how to reproduce
the problem (if possible), type of the Operating System and its version, etc.,
and any other relevant details that might help us with troubleshooting.

Related Issue

#393

Types of changes

  • Bug fix (non-breaking change which fixes an issue)

Checklist:

  • I have read the CONTRIBUTING document.
  • I have run the pre-merge tests locally and they pass.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • If Gemfile.lock has changed, I have used --conservative to do it and included the full output in the Description above.
  • All new and existing tests passed.
  • All commits have been signed-off for the Developer Certificate of Origin.

The case statement for platform detections seems to have a string for wildcard (*) which fails to fetch metadata for amazon linux 1 during chef install. Fixing this.

Signed-off-by: siddhu208 <siddhu_to@yahoo.com>
Copy link

Quality Gate Passed Quality Gate passed

Issues
0 New issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

@sean-simmons-progress sean-simmons-progress self-assigned this Feb 13, 2024
@sean-simmons-progress
Copy link

We are looking at this now and will get back to you soon. cc @anandhapadmanabhan

@muthuja muthuja merged commit 04184a9 into chef:main Feb 14, 2024
4 checks passed
@muthuja muthuja mentioned this pull request Feb 14, 2024
11 tasks
@sean-simmons-progress
Copy link

@siddhu208 this PR has been merged and pushed to our production environment. Please let us know if you have any other issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants