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

Update yum config for CentOS Stream 9 #172

Merged
merged 1 commit into from
Mar 1, 2024

Conversation

pdohertybcov
Copy link
Contributor

Description

The Powertools repo doesn't exist for CentOS Stream 9. The equivalent packages are in the CRB repo. This adds a second conditional statement to enable the CRB repo if the platform_version is 9 and changes the conditional for the powertools repo from >= 8 to == 8

When trying to use this cookbook on CentOS Stream 9 is resulted in an error like below:

         * ruby_build_install[] action install
           * dnf_package[yum-utils] action install (up to date)
           * execute[yum-config-manager --enable powertools] action run

             ================================================================================
             Error executing action `run` on resource 'execute[yum-config-manager --enable powertools]'
             ================================================================================

             Mixlib::ShellOut::ShellCommandFailed
             ------------------------------------
             Expected process to exit with [0], but received '1'
             ---- Begin output of yum-config-manager --enable powertools ----
             STDOUT:
             STDERR: Error: No matching repo to modify: powertools.
             ---- End output of yum-config-manager --enable powertools ----
             Ran yum-config-manager --enable powertools returned 1

             Cookbook Trace: (most recent call first)
             ----------------------------------------
             /tmp/kitchen/cache/cookbooks/ruby_build/resources/install.rb:16:in `block in class_from_file'

             Resource Declaration:
             ---------------------
             # In /tmp/kitchen/cache/cookbooks/ruby_build/resources/install.rb

       16:       execute 'yum-config-manager --enable powertools' do
       17:         not_if 'yum-config-manager --dump powertools | grep -q "enabled = 1"'
       18:       end
       19:     end

Issues Resolved

List any existing issues this PR resolves

Check List

  • A summary of changes made is included in the CHANGELOG under ## Unreleased
  • New functionality includes testing.
  • New functionality has been documented in the README if applicable.

@pdohertybcov pdohertybcov requested a review from a team as a code owner February 29, 2024 15:57
The Powertools repo doesn't exist for CentOS Stream 9.  The equivalent
packages are in the CRB repo.
@damacus damacus added the Release: Patch Release to Chef Supermarket as a version patch when merged label Mar 1, 2024
@damacus
Copy link
Member

damacus commented Mar 1, 2024

Excellent thank you for this!

@damacus damacus merged commit 9ccbf3e into sous-chefs:main Mar 1, 2024
19 of 20 checks passed
@kitchen-porter
Copy link
Contributor

Released as: 2.5.6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Release: Patch Release to Chef Supermarket as a version patch when merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants