Code Monkey home page Code Monkey logo

Comments (2)

jerenkrantz avatar jerenkrantz commented on August 23, 2024

I would need to know more about when this error occurs - it's not obvious to me where the error is. Since this script is run on your local machine, it probably is best that you define EDITOR yourself.

from chef-bcpc.

cbaenziger avatar cbaenziger commented on August 23, 2024

This happens when a Chef knife edit command has the EDITOR return false and knife does not update the object requested. In cluster-assign-roles.sh this can happen on a re-run when it goes to ensure the node is an administrator. E.g.:

vagrant@bcpc-bootstrap:~/chef-bcpc$ knife client show bcpc-vm1.local.lan|grep admin:
admin:       false
vagrant@bcpc-bootstrap:~/chef-bcpc$ printf "/\"admin\": false\ns/false/true\nw\nq\n" | EDITOR=ed knife client edit bcpc-vm1.local.lan|grep admin
615
614
  "admin": false,
  "admin": true,
vagrant@bcpc-bootstrap:~/chef-bcpc$ knife client show bcpc-vm1.local.lan|grep admin:
admin:       true
vagrant@bcpc-bootstrap:~/chef-bcpc$ printf "/\"admin\": false\ns/false/true\nw\nq\n" | EDITOR=ed knife client edit bcpc-vm1.local.lan|grep admin
614
?
?
614
ERROR: RuntimeError: Please set EDITOR environment variable

Or one can see this behavior with the following:

vagrant@bcpc-bootstrap:~/chef-bcpc$ EDITOR=true knife client edit bcpc-vm1.local.lan|grep admin
vagrant@bcpc-bootstrap:~/chef-bcpc$ EDITOR=false knife client edit bcpc-vm1.local.lan|grep admin
ERROR: RuntimeError: Please set EDITOR environment variable

from chef-bcpc.

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.