Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Depend on knife instead of chef #206

Merged
merged 3 commits into from
Jun 17, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 0 additions & 19 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,8 @@ source "https://rubygems.org"

gemspec

group :docs do
gem "yard"
gem "redcarpet"
gem "github-markup"
end

group :test do
gem "chefstyle"
gem "rspec", "~> 3.1"
gem "rake"
if Gem::Version.new(RUBY_VERSION) < Gem::Version.new("2.7")
gem "chef-zero", "~> 15"
gem "chef", "~> 15"
else
gem "chef", "~> 16"
end
end

group :development do
gem "pry"
gem "pry-byebug"
gem "pry-stack_explorer"
gem "rb-readline"
end
21 changes: 6 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,11 @@

## Overview

This is the official Chef [Knife](http://docs.chef.io/knife.html) plugin for
[Google Compute Engine](https://cloud.google.com/products/compute-engine).
This plugin gives knife the ability to create, bootstrap, and manage
Google Compute Engine (GCE) instances.
This is the official Chef [Knife](https://docs.chef.io/workstation/knife/) plugin for [Google Compute Engine](https://cloud.google.com/compute). This plugin gives knife the ability to create, bootstrap, and manage Google Compute Engine (GCE) instances.

## Compatibility

This plugin has been tested with Chef 12.x and uses the [Google API Ruby Client](https://github.com/google/google-api-ruby-client).
This plugin has been tested with Chef 17 and uses the [Google API Ruby Client](https://github.com/google/google-api-ruby-client).

# Getting Started

Expand All @@ -32,12 +29,6 @@ Install the gem with:
gem install knife-google
```

Or, even better, if you're using the ChefDK:

```sh
chef gem install knife-google
```

If you're using Bundler, simply add it to your Gemfile:

```ruby
Expand Down Expand Up @@ -70,7 +61,7 @@ The easiest way to create this is to download and install the [Google Cloud SDK]
If you already have a file you'd like to use that is in a different location, set the
`GOOGLE_APPLICATION_CREDENTIALS` environment variable with the full path to that file.

## Configuration
## Configuration

All knife-google commands require a project name, and most commands require zone name to be supplied.
You can supply these on the command line:
Expand Down Expand Up @@ -284,7 +275,7 @@ WinRM is used by Chef to bootstrap Windows nodes. The default settings of the GC
All documentation is written using YARD. You can generate a by running:

```
rake docs
yard
```

## Contributing
Expand All @@ -295,7 +286,7 @@ For information on contributing to this project please see our [Contributing Doc

Version 3.0.0 of knife-google was rewritten by Chef Partner Engineering but is largely inspired by initial versions of knife-google, thanks to the work of the great folks at Google.

- Copyright:: Copyright (c) 2016-2018 Chef Software, Inc.
- Copyright:: Chef Software, Inc.
- License:: Apache License, Version 2.0

```text
Expand All @@ -310,4 +301,4 @@ 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.
```
```
14 changes: 0 additions & 14 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,4 @@ rescue LoadError
puts "chefstyle gem is not installed. bundle install first to make sure all dependencies are installed."
end

begin
require "yard" unless defined?(YARD)
YARD::Rake::YardocTask.new(:docs)
rescue LoadError
puts "yard is not available. bundle install first to make sure all dependencies are installed."
end

task :console do
require "irb"
require "irb/completion"
ARGV.clear
IRB.start
end

task default: %i{spec style}
2 changes: 1 addition & 1 deletion knife-google.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Gem::Specification.new do |s|
s.require_paths = ["lib"]
s.required_ruby_version = ">= 2.7"

s.add_dependency "chef", ">= 15.11"
s.add_dependency "knife"
s.add_dependency "knife-cloud", ">= 4.0.0"
s.add_dependency "google-api-client", ">= 0.23.9", "< 0.53.0" # each version introduces breaking changes which we need to validate
s.add_dependency "gcewinpass", "~> 1.1"
Expand Down