Questions tagged [chef-zero]

Questions regarding Chef zero server

Chef zero project made for testing and solo purposes of Chef server

Simple, easy-run, fast-start in-memory Chef server for testing and solo purposes

Github: https://github.com/chef/chef-zero

39 questions
1
vote
2 answers

Can I run chef-client as a daemon in local-mode?

I know how to start chef-client with --local mode, but it takes very long to load local repository and everything. I am wondering if I can run chef-client as a long-running service (chef-zero server?) So I can run chef client without starting…
Zhenkai
  • 318
  • 3
  • 15
1
vote
1 answer

Provisioning a vagrant box takes multiple tries

"Insanity: doing the same thing over and over again and expecting different results." - Albert Einstein I have a vagrant + chef (w/chef-zero Berkshelf) built box that runs a lot of programs, including zend-server-php, mongos, and erlang. I'm…
lostphilosopher
  • 4,361
  • 4
  • 28
  • 39
1
vote
4 answers

Chef run list is empty. Chef-Zero Vagrant Provisioner

I am trying to setup my Chef-Zero provisioner to execute the run list from a nodes JSON file. This is what my Vagrantfile looks like. # -*- mode: ruby -*- # vi: set ft=ruby : # Vagrantfile API/syntax version. Don't touch unless you know what…
PaulM
  • 79
  • 1
  • 8
1
vote
1 answer

`search` not finding nodes by role on dev

I'm working on spinning up a cluster of nodes. In myrepo/cookbooks/mycookbook/.kitchen.yml I have driver: name: vagrant provisioner: name: chef_zero roles_path: '../../roles' environments_path: '../../environments' data_bags_path:…
KeatsKelleher
  • 10,015
  • 4
  • 45
  • 52
0
votes
0 answers

-e:5:in `
': undefined method `[]' for nil:NilClass (NoMethodError)

My objective is to insert one line in a file inside a docker container, sometimes it's working smoothly sometime the docker takes restarts frequently and from the docker logs I am getting this error -e:5:in
': undefined method []' for…
Onik Azad
  • 31
  • 4
0
votes
0 answers

Execution Chef Cookbook using chef-solo

I am trying to execute chef solo on my windows vm locally using Powershell. (I am trying to execute cookbook during provisioning customise Windows VM on cloud) All cookbook recipe dependencies are available within the cookbook. Create solo.rb for…
Its Soni
  • 21
  • 1
  • 6
0
votes
1 answer

How to identify list of cookbooks that are successfully executed, once chef-client ran in local mode?

I executed some cookbooks in chef-client using local mode option. After the run is completed, is there anyway, I can find, what cookbooks are successfully executed?
Ram
  • 221
  • 1
  • 2
  • 7
0
votes
1 answer

Chef-client run half copying cookbooks from site-cookbooks directory into cookbooks directory

I've got a custom cookbook that configures my Jenkins servers. There are 3 recipes in a custom cookbook. I'm using librarian-chef to manage my cookbook dependencies. Chef is being run in local mode and I use terraform to provision my nodes with…
codewizard
  • 1,029
  • 1
  • 13
  • 22
0
votes
1 answer

Chef: WARN: Node has an empty run list

I'm running into an issue with Chef zero; odd thing is that i have been provisioning many nodes this way without actually changing stuff but now it has broken. (python)➜ chef_files git:(develop) ✗ knife node list feeder2 (python)➜ chef_files…
Paul Bormans
  • 1,292
  • 16
  • 22
0
votes
1 answer

Chef: 'kitchen converge' not sourcing new template

I've generated a new template which I will be using to edit a Nginx conf file. The nginx.conf.erb file is created in my cookbook's Templates folder and I have edited it to make it configure Nginx as I want to. In my recipe, I have then added the…
Stephen Walsh
  • 815
  • 4
  • 18
  • 34
0
votes
2 answers

Knife zero existing node discovery

I'm getting acquainted with chef and want to build my workflow without central server (using chef-zero and knife zero). Everything works fine, however, chef-zero stores information about nodes in .json files that are rather big and changed too often…
Etki
  • 2,042
  • 2
  • 17
  • 40
0
votes
1 answer

How do I use chef provisioning with chef zero with recipes that contain dependencies?

I'm very new to Chef and I'm attempting to provision a VM on my vsphere node using "chef provisioning". When I execute the following chef-client -z -o 'my_company::vsphere' 'my_company::test_cluster' I get the following…
Jason Thompson
  • 4,643
  • 5
  • 50
  • 74
0
votes
0 answers

chef integrations tests are not identified by kitchen

I'm trying to write integration tests for chef cookbook using serverspec verifier-name in kitchen using kitchen-ssh driver. below is the directory structure how the files are arranged in my cookbook. |-- recipes | …
0
votes
1 answer

Overriding run list with chef zero

I have a folder "root-folder" which contains two custom cookbooks. - root-folder \ -this-cookbook -that-cookbook I can cd into and run either cookbook directly for example: chef-client -z -o this-cookbook -j ../config.json Really I want…
Paul D'Ambra
  • 7,629
  • 3
  • 51
  • 96
0
votes
2 answers

how to get information about chef provisioner (chef-zero or not) inside a chef recipe?

In my recipe I want to find out the the mode in which chef is running and load from data bag based on that. If it is running chef-zero then I will load the data bag in a specific way and if not in a different way . if Chef::Config[:zero] == 'true' …
Shamik
  • 1,591
  • 2
  • 16
  • 36