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

adding fix for cinc upgrade #251

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

cs2209
Copy link

@cs2209 cs2209 commented Jun 21, 2023

There is support available for the cinc in the chef_client_updater cookbook but for mixlib-install it was introduced with chef/mixlib-install#340. The mixlib-install release is 3.12.23, which contains the changes to include cinc in the list of product matrix.

After updating found that the upgrade is still failing which is because chef_client_updater still contains the old release at https://github.com/chef-cookbooks/chef_client_updater/blob/main/providers/default.rb#L32-L37.
So mixlib-install version should be either equal or greater than 3.12.23.

Signed-off-by: chetan <chetansharma.cs6@gmail.com>
@cs2209
Copy link
Author

cs2209 commented Jun 21, 2023

@teknofire @decoyjoe Let me know if any changes required.

@decoyjoe
Copy link
Contributor

@cs2209 Can you provide more specific details on what upgrading the mixlib-install gem achieves? I.e. how does it change someone's usage or behavior of the chef_client_updater resource?

@cs2209
Copy link
Author

cs2209 commented Jun 22, 2023

@decoyjoe While upgrading cinc if you have a version lesser than 3.12.23 of mixlib-install, then it throws the below error:
Mixlib::Install::Options::InvalidOptions: chef_client_updater had an error: Mixlib::Install::Options::InvalidOptions: Unknown product name cinc. Must be one of: analytics, angry-omnibus-toolchain, angrychef, automate, chef, chef-backend, chef-server, chef-server-ha-provisioning, chef-workstation, chefdk, compliance, delivery, ha, harmony, inspec, mac-bootstrapper, manage, marketplace, omnibus-toolchain, omnibus-gcc, private-chef, push-jobs-client, push-jobs-server, reporting, supermarket, sync

The fix is introduced in the 3.12.23 mixlib-install with chef/mixlib-install#340. So in order to support the Cinc upgrade as well with this cookbook, Mixlib-Install greater than 3.12.23 should be used.

@decoyjoe
Copy link
Contributor

@cs2209 Ah I see, mixlib-install was updated to be aware of the product it was shipped with, which enables it to recognize the Cinc products when it's shipped with that distribution. You'll need to get the Chef folks to review this PR. Best way is usually to request a review in the #chef-infra-dev channel on their Chef community Slack.

In the meantime, the current version of this cookbook is useable with Cinc if you pass in the product_name and rubygems_url like so:

chef_client_updater 'cinc-client' do
  product_name 'cinc'
  rubygems_url 'https://packagecloud.io/cinc-project/stable'
end

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.

None yet

2 participants