Coder Social home page Coder Social logo

Not found returned for all roles about chef-zero HOT 8 CLOSED

chef avatar chef commented on July 27, 2024
Not found returned for all roles

from chef-zero.

Comments (8)

jkeiser avatar jkeiser commented on July 27, 2024

What is the chef_repo_path for that instance? Can you look in that directory and say whether the roles directory contains the json it is supposed to?

from chef-zero.

claco avatar claco commented on July 27, 2024

Given a failed kitchen run, how do I find that out? This might be a test-kitchen issue, but I honestly have no clue.

If I clone the chef-zero repo, drop ./roles/*rb in playground, start a zero instance and upload, knife role list returns them and knife role show returns the role.

The zero provisioner says home is /tmp/kitchen-chef-zero and inspecting that directory, the roles do exist in the roles folder. Of course, after the fail, /var/folders/nf/zwnznxhj35n_143061ppg9rr0000gn/T/default-centos-64-sandbox-20130912-15374-1qapxn7 is gone so I can't see what it looked like at the time.

from chef-zero.

claco avatar claco commented on July 27, 2024

So, through some tinkering, here's what I've found.

If I have a ./roles/foop.rb file using the ruby dsl, it gets uploaded, but the chef-zero run fails with the error above.
If I have a ./roles/foop.json file, it gets uploaded, the run_list expands, chef-zero converges successfully.

So, it appears in disk mode where we're not uploading things using knife to the in memory server, there must be some assumption that the role files are in json. I have to assume the same might be true for the environment files as well.

from chef-zero.

jkeiser avatar jkeiser commented on July 27, 2024

Oh! .rb files are not supported in knife upload or chef-zero (I really need to lock that down some time). Only json. The exception is cookbooks, of course. Everything else has to be json. Sorry about that, supporting .rb is a non-trivial thing that I haven't had time to add (though thankfully, once it's added to knife upload, chef-zero gets it free).

from chef-zero.

claco avatar claco commented on July 27, 2024

<-- rabbit holed yak shaver. :-)

from chef-zero.

mattray avatar mattray commented on July 27, 2024

I ran into this too, @jkeiser is this feature in progress or should we familiarize ourselves with the code and look into fixing it?

from chef-zero.

jkeiser avatar jkeiser commented on July 27, 2024

It's not in progress at the moment. The fix needs to be in knife-essentials (well, chef at this point since that's where knife upload lives). This issue has a bit more information: jkeiser/knife-essentials#67

from chef-zero.

sethvargo avatar sethvargo commented on July 27, 2024

I'm going to close this, since the issue actually lies in knife-essentials. Please track jkeiser/knife-essentials#67 for more information.

from chef-zero.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.