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

setting up chef_version doesn't seems to be working #580

Open
munusamymp opened this issue May 11, 2017 · 2 comments
Open

setting up chef_version doesn't seems to be working #580

munusamymp opened this issue May 11, 2017 · 2 comments

Comments

@munusamymp
Copy link

munusamymp commented May 11, 2017

I am trying to force my chef-client version to be < 13.

I tried adding it to the with_machine_options() but it doesn't seems to be working.

with_machine_options({
  convergence_options: {
    chef_version: "12.19.36"
 },
  transport_address_location: :private_ip,
  aws_tags: { 'UAI' => 'xxxxxxxx' },
  ssh_username: ubuntu,
  bootstrap_options: {
    block_device_mappings: [
  ....
  ....
  ....

Machines provisions perfectly fine but it still installs the latest version of chef-client.

Here is my versions of chefdk and chef-client.

Chef Development Kit Version: 0.15.15
chef-client version: 12.11.18
delivery version: 0.0.23 (bf89a6b776b55b89a46bbd57fcaa615c143a09a0)
berks version: 4.3.5
kitchen version: 1.10.0

and

provisioner gem versions::

chef-provisioning-aws (1.10.0, 1.9.0)
@stanislav-zaprudskiy
Copy link

What fails for install_sh, is https://github.com/chef/chef-provisioning/blob/cd6f582f0e2cbe63e4dc6f2b25cbc1b3c24744b2/lib/chef/provisioning/convergence_strategy/install_sh.rb#L12-L15.

chef-provisioning-aws passes version specification properly inside Cheffish::MergedConfig object, where it is then processed by initialize method, but improperly. Supposedly, due to chef/cheffish@846079b.

I can't judge if that is Cheffish::MergedConfig or Chef::Mash which does things wrong, but in case of our internal cloud driver which inherits from chef-provisioning-aws we were able to work around the issue by converting convergence_options to_hash (here) before passing it to Chef::Provisioning::ConvergenceStrategy.

Another workaround might be to downgrade cheffish to some older version.

@robertomoutinho
Copy link

Same issue here... using chef-provisioning and chef-provisionin-aws is becoming a nightmare.

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

No branches or pull requests

3 participants