Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I ran knife solo bootstrap [myserverssh] to initially install recipes on my server. Everything got installed correctly.

I then made changes the recipes. I ran knife solo cook [myserverssh] to update my server. Chef however doesn't seem to find the changes/update the server. The output is:

Checking Chef version...
Starting Chef Client, version 11.4.4
Compiling Cookbooks...
Converging 0 resources
Chef Client finished, 0 resources updated

Is there something I need to do to let chef know what changed and what it needs to update ont the server?


The change I made was adding the following to the site-cookbooks/nginx/recipes/main_conf.rb:

# Make Secure Site
template "#{node['nginx']['dir']}/sites-available/default-secure" do
  source "cakephp-secure-site.erb"
  owner "root"
  group "root"
  mode 00644
  notifies :reload, 'service[nginx]'
end

# Enable Secure Site
nginx_site 'default-secure' do
  enable true
end

Side note: I'm also using librarian. Not sure if it makes a difference. I tried running librarian-chef clean but it didn't help.

share|improve this question

1 Answer 1

up vote 1 down vote accepted

Ah ha! Figured it out.

First time I did knife solo bootstrap [ec2's public address]. Second time I did knife solo cook [ip address of my server].

The second time it created a new nodes file (in the nodes/ folder). It was empty and didn't have any recipes/roles assigned to the host.

I copied the content of the first node file into the second.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.