Chef-server-ctl issue

Hi,

(For those of you having deja vu I realised I sent the original email with
the wrong subject)

I’m trying to configure a Chef server but I’m running into this problem
when adding a key to a client:

chef-server-ctl add-client-key <client_name> <path_to_pub_key_file>
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/chef-12.0.3/lib/chef/http.rb:125:in
post': wrong number of arguments (0 for 2..3) (ArgumentError) from /opt/opscode/embedded/service/omnibus-ctl/helpers/key_ctl_helper.rb:43:inpost_rest’
from (eval):74:in block (2 levels) in load_files' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:incall’
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:in
block in add_command_under_category' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:566:inrun’
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/bin/omnibus-ctl:31:in
<top (required)>' from /opt/opscode/embedded/bin/omnibus-ctl:23:inload’
from /opt/opscode/embedded/bin/omnibus-ctl:23:in `’

Chef server version is the latest installed by the chef-server cookbook,
looks like 12.0.3 from the gem and like this from yum:

chef-server-core.x86_64 12.0.8-1.el6
@chef_stable_

Is this a bug or a usage problem?


Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025
Email: yoshi.spendiff@indochino.com

Hi Yoshi,

The version you see in the gem is the version of the Chef Client gem that’s vendored with the Chef Server. The version there is correct. Chef Server 12.0.8 vendors Chef Client 12.0.3 for internal usage (reconfigure / client library access). I’m doublechecking the usage right now for that command and we’ll get back shortly.

Cheers!


Stephen Delano - Engineering Lead, Chef

On Thu, Apr 23, 2015 at 9:02 AM, Yoshi Spendiff
yoshi.spendiff@indochino.com wrote:

Hi,
(For those of you having deja vu I realised I sent the original email with
the wrong subject)
I'm trying to configure a Chef server but I'm running into this problem
when adding a key to a client:
chef-server-ctl add-client-key <client_name> <path_to_pub_key_file>
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/chef-12.0.3/lib/chef/http.rb:125:in
post': wrong number of arguments (0 for 2..3) (ArgumentError) from /opt/opscode/embedded/service/omnibus-ctl/helpers/key_ctl_helper.rb:43:in post_rest'
from (eval):74:in block (2 levels) in load_files' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:in call'
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:in
block in add_command_under_category' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:566:in run'
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/bin/omnibus-ctl:31:in
<top (required)>' from /opt/opscode/embedded/bin/omnibus-ctl:23:in load'
from /opt/opscode/embedded/bin/omnibus-ctl:23:in `'
Chef server version is the latest installed by the chef-server cookbook,
looks like 12.0.3 from the gem and like this from yum:
chef-server-core.x86_64 12.0.8-1.el6
@chef_stable_
Is this a bug or a usage problem?

Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025
Email: yoshi.spendiff@indochino.com

Hey Yoshi,

It is indeed a bug, thanks for posting! We will be shipping a new version
of the server that fixes the bug soon, but if you just want to get
unblocked right now:

  1. Open the
    file /opt/opscode/embedded/service/omnibus-ctl/helpers/key_ctl_helper.rb in
    the text editor of your choice.
  2. Go to line 43. It should currently look like this: @chef_rest.post_rest
  3. Edit line 43 to be this instead: @chef_rest.post_rest(url, body)
  4. Save and exit the file. chef-server-ctl add-client-key should now be
    functional.

Thanks and we'll have a new build with a fix out shortly!

Tyler

On Thu, Apr 23, 2015 at 9:07 AM, Stephen Delano stephen@opscode.com wrote:

Hi Yoshi,

The version you see in the gem is the version of the Chef Client gem
that’s vendored with the Chef Server. The version there is correct. Chef
Server 12.0.8 vendors Chef Client 12.0.3 for internal usage (reconfigure /
client library access). I’m doublechecking the usage right now for that
command and we’ll get back shortly.

Cheers!


Stephen Delano - Engineering Lead, Chef

On Thu, Apr 23, 2015 at 9:02 AM, Yoshi Spendiff <
yoshi.spendiff@indochino.com> wrote:

Hi,

(For those of you having deja vu I realised I sent the original email
with the wrong subject)

I'm trying to configure a Chef server but I'm running into this problem
when adding a key to a client:

chef-server-ctl add-client-key <client_name>
<path_to_pub_key_file>

/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/chef-12.0.3/lib/chef/http.rb:125:in
post': wrong number of arguments (0 for 2..3) (ArgumentError) from /opt/opscode/embedded/service/omnibus-ctl/helpers/key_ctl_helper.rb:43:in post_rest'
from (eval):74:in block (2 levels) in load_files' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:in call'
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:in
block in add_command_under_category' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:566:in run'
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/bin/omnibus-ctl:31:in
<top (required)>' from /opt/opscode/embedded/bin/omnibus-ctl:23:in load'
from /opt/opscode/embedded/bin/omnibus-ctl:23:in `'

Chef server version is the latest installed by the chef-server cookbook,
looks like 12.0.3 from the gem and like this from yum:

chef-server-core.x86_64 12.0.8-1.el6
@chef_stable_

Is this a bug or a usage problem?

--
Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025
Email: yoshi.spendiff@indochino.com

Thanks, worked a treat.

On Thu, Apr 23, 2015 at 11:13 AM, Tyler Cloke tyler@chef.io wrote:

Hey Yoshi,

It is indeed a bug, thanks for posting! We will be shipping a new version
of the server that fixes the bug soon, but if you just want to get
unblocked right now:

  1. Open the
    file /opt/opscode/embedded/service/omnibus-ctl/helpers/key_ctl_helper.rb in
    the text editor of your choice.
  2. Go to line 43. It should currently look like this: @chef_rest.post_rest
  3. Edit line 43 to be this instead: @chef_rest.post_rest(url, body)
  4. Save and exit the file. chef-server-ctl add-client-key should now be
    functional.

Thanks and we'll have a new build with a fix out shortly!

Tyler

On Thu, Apr 23, 2015 at 9:07 AM, Stephen Delano stephen@opscode.com
wrote:

Hi Yoshi,

The version you see in the gem is the version of the Chef Client gem
that’s vendored with the Chef Server. The version there is correct. Chef
Server 12.0.8 vendors Chef Client 12.0.3 for internal usage (reconfigure /
client library access). I’m doublechecking the usage right now for that
command and we’ll get back shortly.

Cheers!


Stephen Delano - Engineering Lead, Chef

On Thu, Apr 23, 2015 at 9:02 AM, Yoshi Spendiff <
yoshi.spendiff@indochino.com> wrote:

Hi,

(For those of you having deja vu I realised I sent the original email
with the wrong subject)

I'm trying to configure a Chef server but I'm running into this problem
when adding a key to a client:

chef-server-ctl add-client-key <client_name>
<path_to_pub_key_file>

/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/chef-12.0.3/lib/chef/http.rb:125:in
post': wrong number of arguments (0 for 2..3) (ArgumentError) from /opt/opscode/embedded/service/omnibus-ctl/helpers/key_ctl_helper.rb:43:in post_rest'
from (eval):74:in block (2 levels) in load_files' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:in call'
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:in
block in add_command_under_category' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:566:in run'
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/bin/omnibus-ctl:31:in
<top (required)>' from /opt/opscode/embedded/bin/omnibus-ctl:23:in load'
from /opt/opscode/embedded/bin/omnibus-ctl:23:in `'

Chef server version is the latest installed by the chef-server
cookbook, looks like 12.0.3 from the gem and like this from yum:

chef-server-core.x86_64 12.0.8-1.el6
@chef_stable_

Is this a bug or a usage problem?

--
Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025
Email: yoshi.spendiff@indochino.com

--
Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025
Email: yoshi.spendiff@indochino.com

Was a fix ever put out for this? Is this going in the next chef-server
version release that's pending?

On Thu, Apr 23, 2015 at 12:50 PM, Yoshi Spendiff <
yoshi.spendiff@indochino.com> wrote:

Thanks, worked a treat.

On Thu, Apr 23, 2015 at 11:13 AM, Tyler Cloke tyler@chef.io wrote:

Hey Yoshi,

It is indeed a bug, thanks for posting! We will be shipping a new version
of the server that fixes the bug soon, but if you just want to get
unblocked right now:

  1. Open the
    file /opt/opscode/embedded/service/omnibus-ctl/helpers/key_ctl_helper.rb in
    the text editor of your choice.
  2. Go to line 43. It should currently look like this: @chef_rest.post_rest
  3. Edit line 43 to be this instead: @chef_rest.post_rest(url, body)
  4. Save and exit the file. chef-server-ctl add-client-key should now be
    functional.

Thanks and we'll have a new build with a fix out shortly!

Tyler

On Thu, Apr 23, 2015 at 9:07 AM, Stephen Delano stephen@opscode.com
wrote:

Hi Yoshi,

The version you see in the gem is the version of the Chef Client gem
that’s vendored with the Chef Server. The version there is correct. Chef
Server 12.0.8 vendors Chef Client 12.0.3 for internal usage (reconfigure /
client library access). I’m doublechecking the usage right now for that
command and we’ll get back shortly.

Cheers!


Stephen Delano - Engineering Lead, Chef

On Thu, Apr 23, 2015 at 9:02 AM, Yoshi Spendiff <
yoshi.spendiff@indochino.com> wrote:

Hi,

(For those of you having deja vu I realised I sent the original email
with the wrong subject)

I'm trying to configure a Chef server but I'm running into this problem
when adding a key to a client:

chef-server-ctl add-client-key <client_name>
<path_to_pub_key_file>

/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/chef-12.0.3/lib/chef/http.rb:125:in
post': wrong number of arguments (0 for 2..3) (ArgumentError) from /opt/opscode/embedded/service/omnibus-ctl/helpers/key_ctl_helper.rb:43:in post_rest'
from (eval):74:in block (2 levels) in load_files' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:in call'
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:in
block in add_command_under_category' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:566:in run'
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/bin/omnibus-ctl:31:in
<top (required)>' from /opt/opscode/embedded/bin/omnibus-ctl:23:in load'
from /opt/opscode/embedded/bin/omnibus-ctl:23:in `'

Chef server version is the latest installed by the chef-server
cookbook, looks like 12.0.3 from the gem and like this from yum:

chef-server-core.x86_64 12.0.8-1.el6
@chef_stable_

Is this a bug or a usage problem?

--
Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025
Email: yoshi.spendiff@indochino.com

--
Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025
Email: yoshi.spendiff@indochino.com

--
Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025
Email: yoshi.spendiff@indochino.com

Hi Yoshi,

I believe this should be fixed in the 12.1 RC.

Cheers,

Steven

On Fri, Jun 5, 2015 at 2:15 AM, Yoshi Spendiff
yoshi.spendiff@indochino.com wrote:

Was a fix ever put out for this? Is this going in the next chef-server
version release that's pending?

On Thu, Apr 23, 2015 at 12:50 PM, Yoshi Spendiff
yoshi.spendiff@indochino.com wrote:

Thanks, worked a treat.

On Thu, Apr 23, 2015 at 11:13 AM, Tyler Cloke tyler@chef.io wrote:

Hey Yoshi,

It is indeed a bug, thanks for posting! We will be shipping a new version
of the server that fixes the bug soon, but if you just want to get unblocked
right now:

  1. Open the file
    /opt/opscode/embedded/service/omnibus-ctl/helpers/key_ctl_helper.rb in the
    text editor of your choice.
  2. Go to line 43. It should currently look like this:
    @chef_rest.post_rest
  3. Edit line 43 to be this instead: @chef_rest.post_rest(url, body)
  4. Save and exit the file. chef-server-ctl add-client-key should now be
    functional.

Thanks and we'll have a new build with a fix out shortly!

Tyler

On Thu, Apr 23, 2015 at 9:07 AM, Stephen Delano stephen@opscode.com
wrote:

Hi Yoshi,

The version you see in the gem is the version of the Chef Client gem
that’s vendored with the Chef Server. The version there is correct. Chef
Server 12.0.8 vendors Chef Client 12.0.3 for internal usage (reconfigure /
client library access). I’m doublechecking the usage right now for that
command and we’ll get back shortly.

Cheers!


Stephen Delano - Engineering Lead, Chef

On Thu, Apr 23, 2015 at 9:02 AM, Yoshi Spendiff
yoshi.spendiff@indochino.com wrote:

Hi,

(For those of you having deja vu I realised I sent the original email
with the wrong subject)

I'm trying to configure a Chef server but I'm running into this problem
when adding a key to a client:

chef-server-ctl add-client-key <client_name>
<path_to_pub_key_file>

/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/chef-12.0.3/lib/chef/http.rb:125:in
post': wrong number of arguments (0 for 2..3) (ArgumentError) from /opt/opscode/embedded/service/omnibus-ctl/helpers/key_ctl_helper.rb:43:in post_rest'
from (eval):74:in block (2 levels) in load_files' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:in call'
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:177:in
block in add_command_under_category' from /opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/lib/omnibus-ctl.rb:566:in run'
from
/opt/opscode/embedded/lib/ruby/gems/2.1.0/gems/omnibus-ctl-0.3.4/bin/omnibus-ctl:31:in
<top (required)>' from /opt/opscode/embedded/bin/omnibus-ctl:23:in load'
from /opt/opscode/embedded/bin/omnibus-ctl:23:in `'

Chef server version is the latest installed by the chef-server
cookbook, looks like 12.0.3 from the gem and like this from yum:

chef-server-core.x86_64 12.0.8-1.el6
@chef_stable_

Is this a bug or a usage problem?

--
Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025
Email: yoshi.spendiff@indochino.com

--
Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025
Email: yoshi.spendiff@indochino.com

--
Yoshi Spendiff
Ops Engineer
Indochino
Mobile: +1 778 952 2025
Email: yoshi.spendiff@indochino.com