Project

knife-swap

0.0
No commit activity in last 3 years
No release in over 3 years
Manages multiple knife.rb configurations for Chef
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 0.7.9
>= 10.0
>= 3.0
>= 0.37.2
>= 0.8

Runtime

>= 0.12.0
 Project Readme

Build Status Coverage Status Code Climate

Knife Swap

Knife Swap was created to manage multiple knife configurations. This functionality exists in knife-block, which I am a huge fan of, but it doesn't seem to have Windows support because of the way it works under the hood.

Needing something that works in both Linux and Windows, I decided to create my own plugin. This currently does not swap the Berkshelf config files. If there's a need for it, please feel free to open an issue.

Installation

chef gem install knife-swap

Requirements

Knife Swap assumes your knife.rb files are set the way knife-block expects them to be with a small difference.

The knife configuration files would still be named knife-name.rb, but knife.rb is no longer a symlink. So, they would be set up like this:

  • knife.rb
  • knife-name.rb
  • knife-another.rb
  • knife-soforth.rb

Usage

command description
knife swap List the current selected knife config as well as the available configurations. For whatever reason you have multiple knife configurations that are exactly the same but just named differently, the console will show you that you've currently selected multiple configs.
knife swap CONFIG Sets your current knife.rb to the desired config.

Authors

License

License: Apache License, Version 2.0

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.