tugboat 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +0 -1
- data/CHANGELOG.md +30 -0
- data/README.md +6 -4
- data/Rakefile +6 -0
- data/lib/tugboat/cli.rb +30 -7
- data/lib/tugboat/config.rb +16 -8
- data/lib/tugboat/middleware.rb +22 -10
- data/lib/tugboat/middleware/ask_for_credentials.rb +2 -1
- data/lib/tugboat/middleware/check_credentials.rb +1 -1
- data/lib/tugboat/middleware/confirm_action.rb +9 -5
- data/lib/tugboat/middleware/create_droplet.rb +2 -1
- data/lib/tugboat/middleware/find_droplet.rb +2 -2
- data/lib/tugboat/middleware/inject_configuration.rb +0 -1
- data/lib/tugboat/middleware/list_ssh_keys.rb +18 -0
- data/lib/tugboat/middleware/snapshot_droplet.rb +4 -1
- data/lib/tugboat/middleware/ssh_droplet.rb +8 -0
- data/lib/tugboat/version.rb +1 -1
- data/spec/cli/authorize_cli_spec.rb +37 -0
- data/spec/cli/create_cli_spec.rb +40 -0
- data/spec/cli/destroy_cli_spec.rb +93 -0
- data/spec/cli/droplets_cli_spec.rb +28 -0
- data/spec/cli/halt_cli_spec.rb +70 -0
- data/spec/cli/images_cli_spec.rb +53 -0
- data/spec/cli/info_cli_spec.rb +93 -0
- data/spec/cli/keys_cli_spec.rb +27 -0
- data/spec/cli/restart_cli_spec.rb +70 -0
- data/spec/cli/snapshot_cli_spec.rb +75 -0
- data/spec/cli/version_cli_spec.rb +20 -0
- data/spec/config_spec.rb +8 -15
- data/spec/fixtures/create_droplet.json +0 -0
- data/spec/fixtures/show_droplet.json +13 -0
- data/spec/fixtures/show_droplets.json +35 -0
- data/spec/fixtures/show_images.json +15 -0
- data/spec/fixtures/show_images_global.json +20 -0
- data/spec/fixtures/show_keys.json +13 -0
- data/spec/middleware/base_spec.rb +15 -0
- data/spec/middleware/inject_configuration_spec.rb +19 -0
- data/spec/shared/environment.rb +43 -0
- data/spec/spec_helper.rb +7 -0
- data/tmp/.gitkeep +0 -0
- data/tugboat.gemspec +7 -0
- metadata +141 -2
@@ -0,0 +1,70 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe Tugboat::CLI do
|
4
|
+
include_context "spec"
|
5
|
+
|
6
|
+
before :each do
|
7
|
+
@cli = Tugboat::CLI.new
|
8
|
+
end
|
9
|
+
|
10
|
+
describe "restarts a droplet" do
|
11
|
+
it "with a fuzzy name" do
|
12
|
+
stub_request(:get, "https://api.digitalocean.com/droplets?api_key=#{api_key}&client_id=#{client_key}").
|
13
|
+
to_return(:status => 200, :body => fixture("show_droplets"))
|
14
|
+
|
15
|
+
stub_request(:put, "https://api.digitalocean.com/droplets/100823/reboot?api_key=#{api_key}&client_id=#{client_key}").
|
16
|
+
to_return(:status => 200, :body => fixture("show_droplet"))
|
17
|
+
|
18
|
+
@cli.restart("foo")
|
19
|
+
|
20
|
+
expect($stdout.string).to eq <<-eos
|
21
|
+
Droplet fuzzy name provided. Finding droplet ID...done\e[0m, 100823 (foo)
|
22
|
+
Queuing restart for 100823 (foo)...done
|
23
|
+
eos
|
24
|
+
|
25
|
+
expect(a_request(:get, "https://api.digitalocean.com/droplets?api_key=#{api_key}&client_id=#{client_key}")).to have_been_made
|
26
|
+
expect(a_request(:put, "https://api.digitalocean.com/droplets/100823/reboot?api_key=#{api_key}&client_id=#{client_key}")).to have_been_made
|
27
|
+
end
|
28
|
+
|
29
|
+
it "with an id" do
|
30
|
+
stub_request(:get, "https://api.digitalocean.com/droplets/#{droplet_id}?api_key=#{api_key}&client_id=#{client_key}").
|
31
|
+
to_return(:status => 200, :body => fixture("show_droplet"))
|
32
|
+
|
33
|
+
stub_request(:put, "https://api.digitalocean.com/droplets/100823/reboot?api_key=#{api_key}&client_id=#{client_key}").
|
34
|
+
to_return(:status => 200, :body => fixture("show_droplet"))
|
35
|
+
|
36
|
+
@cli.options = @cli.options.merge(:id => droplet_id)
|
37
|
+
@cli.restart
|
38
|
+
|
39
|
+
expect($stdout.string).to eq <<-eos
|
40
|
+
Droplet id provided. Finding Droplet...done\e[0m, 100823 (foo)
|
41
|
+
Queuing restart for 100823 (foo)...done
|
42
|
+
eos
|
43
|
+
|
44
|
+
expect(a_request(:get, "https://api.digitalocean.com/droplets/#{droplet_id}?api_key=#{api_key}&client_id=#{client_key}")).to have_been_made
|
45
|
+
expect(a_request(:put, "https://api.digitalocean.com/droplets/100823/reboot?api_key=#{api_key}&client_id=#{client_key}")).to have_been_made
|
46
|
+
end
|
47
|
+
|
48
|
+
|
49
|
+
it "with a name" do
|
50
|
+
stub_request(:get, "https://api.digitalocean.com/droplets?api_key=#{api_key}&client_id=#{client_key}").
|
51
|
+
to_return(:status => 200, :body => fixture("show_droplets"))
|
52
|
+
|
53
|
+
stub_request(:put, "https://api.digitalocean.com/droplets/100823/reboot?api_key=#{api_key}&client_id=#{client_key}").
|
54
|
+
to_return(:status => 200, :body => fixture("show_droplet"))
|
55
|
+
|
56
|
+
@cli.options = @cli.options.merge(:name => droplet_name)
|
57
|
+
@cli.restart
|
58
|
+
|
59
|
+
expect($stdout.string).to eq <<-eos
|
60
|
+
Droplet name provided. Finding droplet ID...done\e[0m, 100823 (foo)
|
61
|
+
Queuing restart for 100823 (foo)...done
|
62
|
+
eos
|
63
|
+
|
64
|
+
expect(a_request(:get, "https://api.digitalocean.com/droplets?api_key=#{api_key}&client_id=#{client_key}")).to have_been_made
|
65
|
+
expect(a_request(:put, "https://api.digitalocean.com/droplets/100823/reboot?api_key=#{api_key}&client_id=#{client_key}")).to have_been_made
|
66
|
+
end
|
67
|
+
|
68
|
+
end
|
69
|
+
|
70
|
+
end
|
@@ -0,0 +1,75 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe Tugboat::CLI do
|
4
|
+
include_context "spec"
|
5
|
+
|
6
|
+
let(:snapshot_name) { "foo-snapshot" }
|
7
|
+
|
8
|
+
before :each do
|
9
|
+
@cli = Tugboat::CLI.new
|
10
|
+
end
|
11
|
+
|
12
|
+
describe "snapshots a droplet" do
|
13
|
+
it "with a fuzzy name" do
|
14
|
+
stub_request(:get, "https://api.digitalocean.com/droplets?api_key=#{api_key}&client_id=#{client_key}").
|
15
|
+
to_return(:status => 200, :body => fixture("show_droplets"))
|
16
|
+
|
17
|
+
stub_request(:get, "https://api.digitalocean.com/droplets/100823/snapshot?api_key=#{api_key}&client_id=#{client_key}&name=#{snapshot_name}").
|
18
|
+
to_return(:status => 200, :body => fixture("show_droplet"))
|
19
|
+
|
20
|
+
@cli.snapshot(snapshot_name, "foo")
|
21
|
+
|
22
|
+
expect($stdout.string).to eq <<-eos
|
23
|
+
Droplet fuzzy name provided. Finding droplet ID...done\e[0m, 100823 (foo)
|
24
|
+
Warning: Droplet must be in a powered off state for snapshot to be successful
|
25
|
+
Queuing snapshot 'foo-snapshot' for 100823 (foo)...done
|
26
|
+
eos
|
27
|
+
|
28
|
+
expect(a_request(:get, "https://api.digitalocean.com/droplets?api_key=#{api_key}&client_id=#{client_key}")).to have_been_made
|
29
|
+
expect(a_request(:get, "https://api.digitalocean.com/droplets/100823/snapshot?api_key=#{api_key}&client_id=#{client_key}&name=#{snapshot_name}")).to have_been_made
|
30
|
+
end
|
31
|
+
|
32
|
+
it "with an id" do
|
33
|
+
stub_request(:get, "https://api.digitalocean.com/droplets/#{droplet_id}?api_key=#{api_key}&client_id=#{client_key}").
|
34
|
+
to_return(:status => 200, :body => fixture("show_droplet"))
|
35
|
+
|
36
|
+
stub_request(:get, "https://api.digitalocean.com/droplets/100823/snapshot?api_key=#{api_key}&client_id=#{client_key}&name=#{snapshot_name}").
|
37
|
+
to_return(:status => 200, :body => fixture("show_droplet"))
|
38
|
+
|
39
|
+
@cli.options = @cli.options.merge(:id => droplet_id)
|
40
|
+
@cli.snapshot(snapshot_name)
|
41
|
+
|
42
|
+
expect($stdout.string).to eq <<-eos
|
43
|
+
Droplet id provided. Finding Droplet...done\e[0m, 100823 (foo)
|
44
|
+
Warning: Droplet must be in a powered off state for snapshot to be successful
|
45
|
+
Queuing snapshot 'foo-snapshot' for 100823 (foo)...done
|
46
|
+
eos
|
47
|
+
|
48
|
+
expect(a_request(:get, "https://api.digitalocean.com/droplets/#{droplet_id}?api_key=#{api_key}&client_id=#{client_key}")).to have_been_made
|
49
|
+
expect(a_request(:get, "https://api.digitalocean.com/droplets/100823/snapshot?api_key=#{api_key}&client_id=#{client_key}&name=#{snapshot_name}")).to have_been_made
|
50
|
+
end
|
51
|
+
|
52
|
+
|
53
|
+
it "with a name" do
|
54
|
+
stub_request(:get, "https://api.digitalocean.com/droplets?api_key=#{api_key}&client_id=#{client_key}").
|
55
|
+
to_return(:status => 200, :body => fixture("show_droplets"))
|
56
|
+
|
57
|
+
stub_request(:get, "https://api.digitalocean.com/droplets/100823/snapshot?api_key=#{api_key}&client_id=#{client_key}&name=#{snapshot_name}").
|
58
|
+
to_return(:status => 200, :body => fixture("show_droplet"))
|
59
|
+
|
60
|
+
@cli.options = @cli.options.merge(:name => droplet_name)
|
61
|
+
@cli.snapshot(snapshot_name)
|
62
|
+
|
63
|
+
expect($stdout.string).to eq <<-eos
|
64
|
+
Droplet name provided. Finding droplet ID...done\e[0m, 100823 (foo)
|
65
|
+
Warning: Droplet must be in a powered off state for snapshot to be successful
|
66
|
+
Queuing snapshot 'foo-snapshot' for 100823 (foo)...done
|
67
|
+
eos
|
68
|
+
|
69
|
+
expect(a_request(:get, "https://api.digitalocean.com/droplets?api_key=#{api_key}&client_id=#{client_key}")).to have_been_made
|
70
|
+
expect(a_request(:get, "https://api.digitalocean.com/droplets/100823/snapshot?api_key=#{api_key}&client_id=#{client_key}&name=#{snapshot_name}")).to have_been_made
|
71
|
+
end
|
72
|
+
|
73
|
+
end
|
74
|
+
|
75
|
+
end
|
@@ -0,0 +1,20 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe Tugboat::CLI do
|
4
|
+
include_context "spec"
|
5
|
+
|
6
|
+
before :each do
|
7
|
+
@cli = Tugboat::CLI.new
|
8
|
+
end
|
9
|
+
|
10
|
+
describe "version" do
|
11
|
+
it "shows the correct version" do
|
12
|
+
|
13
|
+
@cli.options = @cli.options.merge(:version => true)
|
14
|
+
@cli.version
|
15
|
+
|
16
|
+
expect($stdout.string.chomp).to eq("Tugboat #{Tugboat::VERSION.to_s}")
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
20
|
+
|
data/spec/config_spec.rb
CHANGED
@@ -20,31 +20,19 @@ describe Tugboat::Configuration do
|
|
20
20
|
expect(config.data).to be
|
21
21
|
end
|
22
22
|
|
23
|
-
it "can set a path" do
|
24
|
-
config = Tugboat::Configuration.instance
|
25
|
-
config.path = tmp_path
|
26
|
-
expect(config.path).to equal(tmp_path)
|
27
|
-
end
|
28
|
-
|
29
|
-
it "properly resets path" do
|
30
|
-
config = Tugboat::Configuration.instance
|
31
|
-
config.path = tmp_path
|
32
|
-
config.reset!
|
33
|
-
expect(config.path).to eq(File.join(File.expand_path("~"), '.tugboat'))
|
34
|
-
end
|
35
|
-
|
36
23
|
describe "the file" do
|
37
24
|
let(:client_key) { "foo" }
|
38
25
|
let(:api_key) { "bar" }
|
39
26
|
let(:ssh_user) { "baz" }
|
27
|
+
let(:ssh_key_path) { "~/.ssh/id_rsa2" }
|
40
28
|
let(:ssh_key_path) { "~/.ssh/id_rsa2.pub" }
|
29
|
+
let(:ssh_port) { "22" }
|
41
30
|
|
42
31
|
let(:config) { config = Tugboat::Configuration.instance }
|
43
32
|
|
44
33
|
before :each do
|
45
34
|
# Create a temporary file
|
46
|
-
config.
|
47
|
-
config.create_config_file(client_key, api_key, ssh_key_path, ssh_user)
|
35
|
+
config.create_config_file(client_key, api_key, ssh_key_path, ssh_user, ssh_port)
|
48
36
|
end
|
49
37
|
|
50
38
|
it "can be created" do
|
@@ -86,5 +74,10 @@ describe Tugboat::Configuration do
|
|
86
74
|
ssh = data["ssh"]
|
87
75
|
expect(ssh).to have_key("ssh_user")
|
88
76
|
end
|
77
|
+
|
78
|
+
it "should have an ssh port" do
|
79
|
+
ssh = data["ssh"]
|
80
|
+
expect(ssh).to have_key("ssh_port")
|
81
|
+
end
|
89
82
|
end
|
90
83
|
end
|
File without changes
|
@@ -0,0 +1,35 @@
|
|
1
|
+
{
|
2
|
+
"status": "OK",
|
3
|
+
"droplets": [
|
4
|
+
{
|
5
|
+
"ip_address": "33.33.33.10",
|
6
|
+
"backups_active": null,
|
7
|
+
"id": 100823,
|
8
|
+
"image_id": 420,
|
9
|
+
"name": "test222",
|
10
|
+
"region_id": 1,
|
11
|
+
"size_id": 33,
|
12
|
+
"status": "active"
|
13
|
+
},
|
14
|
+
{
|
15
|
+
"ip_address": "33.33.33.10",
|
16
|
+
"backups_active": null,
|
17
|
+
"id": 100823,
|
18
|
+
"image_id": 420,
|
19
|
+
"name": "test223",
|
20
|
+
"region_id": 1,
|
21
|
+
"size_id": 33,
|
22
|
+
"status": "active"
|
23
|
+
},
|
24
|
+
{
|
25
|
+
"ip_address": "33.33.33.10",
|
26
|
+
"backups_active": null,
|
27
|
+
"id": 100823,
|
28
|
+
"image_id": 420,
|
29
|
+
"name": "foo",
|
30
|
+
"region_id": 1,
|
31
|
+
"size_id": 33,
|
32
|
+
"status": "off"
|
33
|
+
}
|
34
|
+
]
|
35
|
+
}
|
@@ -0,0 +1,20 @@
|
|
1
|
+
{
|
2
|
+
"status": "OK",
|
3
|
+
"images": [
|
4
|
+
{
|
5
|
+
"id": 466,
|
6
|
+
"name": "NYTD Backup 1-18-2012",
|
7
|
+
"distribution": "Ubuntu"
|
8
|
+
},
|
9
|
+
{
|
10
|
+
"id": 478,
|
11
|
+
"name": "NLP Final",
|
12
|
+
"distribution": "Ubuntu"
|
13
|
+
},
|
14
|
+
{
|
15
|
+
"id": 479,
|
16
|
+
"name": "Global Final",
|
17
|
+
"distribution": "Ubuntu"
|
18
|
+
}
|
19
|
+
]
|
20
|
+
}
|
@@ -0,0 +1,15 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe Tugboat::Middleware::Base do
|
4
|
+
include_context "spec"
|
5
|
+
|
6
|
+
let(:klass) { described_class }
|
7
|
+
|
8
|
+
describe ".initialize" do
|
9
|
+
it "prints a clear line" do
|
10
|
+
$stdout.should_receive(:print).with("")
|
11
|
+
klass.new({})
|
12
|
+
end
|
13
|
+
end
|
14
|
+
|
15
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe Tugboat::Middleware::InjectConfiguration do
|
4
|
+
include_context "spec"
|
5
|
+
|
6
|
+
let(:app) { lambda { |env| } }
|
7
|
+
let(:env) { {} }
|
8
|
+
|
9
|
+
describe ".call" do
|
10
|
+
|
11
|
+
it "loads the configuration into the environment" do
|
12
|
+
described_class.new(app).call(env)
|
13
|
+
|
14
|
+
env["config"].should == config
|
15
|
+
end
|
16
|
+
|
17
|
+
end
|
18
|
+
|
19
|
+
end
|
@@ -0,0 +1,43 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
shared_context "spec" do
|
4
|
+
# Default configuration and
|
5
|
+
let(:config) { Tugboat::Configuration.instance }
|
6
|
+
let(:client_key) { "foo" }
|
7
|
+
let(:api_key) { "bar" }
|
8
|
+
let(:ssh_user) { "baz" }
|
9
|
+
let(:ssh_port) { "22" }
|
10
|
+
let(:ssh_key_path) { "~/.ssh/id_rsa2" }
|
11
|
+
let(:droplet_name) { "foo" }
|
12
|
+
let(:droplet_id) { 1234 }
|
13
|
+
|
14
|
+
|
15
|
+
before(:each) do
|
16
|
+
$stdout.sync = true
|
17
|
+
$stderr.sync = true
|
18
|
+
|
19
|
+
# Set a temprary project path and create fake config.
|
20
|
+
config.create_config_file(client_key, api_key, ssh_user, ssh_key_path, ssh_port)
|
21
|
+
config.reload!
|
22
|
+
|
23
|
+
# Keep track of the old stderr / out
|
24
|
+
@orig_stderr = $stderr
|
25
|
+
@orig_stdout = $stdout
|
26
|
+
|
27
|
+
# Make them strings so we can manipulate and compare.
|
28
|
+
$stderr = StringIO.new
|
29
|
+
$stdout = StringIO.new
|
30
|
+
end
|
31
|
+
|
32
|
+
after(:each) do
|
33
|
+
# Reassign the stderr / out so rspec can have it back.
|
34
|
+
$stderr = @orig_stderr
|
35
|
+
$stdout = @orig_stdout
|
36
|
+
end
|
37
|
+
|
38
|
+
after(:each) do
|
39
|
+
# Delete the temporary configuration file if it exists.
|
40
|
+
File.delete(project_path + "/tmp/tugboat") if File.exist?(project_path + "/tmp/tugboat")
|
41
|
+
end
|
42
|
+
|
43
|
+
end
|
data/spec/spec_helper.rb
CHANGED
@@ -1,4 +1,6 @@
|
|
1
1
|
require 'tugboat'
|
2
|
+
require 'webmock/rspec'
|
3
|
+
require "shared/environment"
|
2
4
|
|
3
5
|
RSpec.configure do |config|
|
4
6
|
# Pretty tests
|
@@ -9,3 +11,8 @@ def project_path
|
|
9
11
|
File.expand_path("../..", __FILE__)
|
10
12
|
end
|
11
13
|
|
14
|
+
def fixture(fixture_name)
|
15
|
+
File.new(project_path + "/spec/fixtures/#{fixture_name}.json")
|
16
|
+
end
|
17
|
+
|
18
|
+
ENV["TUGBOAT_CONFIG_PATH"] = project_path + "/tmp/tugboat"
|
data/tmp/.gitkeep
ADDED
File without changes
|
data/tugboat.gemspec
CHANGED
@@ -20,4 +20,11 @@ Gem::Specification.new do |gem|
|
|
20
20
|
gem.add_dependency "thor", "~> 0.18.1"
|
21
21
|
gem.add_dependency "digital_ocean", "~> 1.0.1"
|
22
22
|
gem.add_dependency "middleware" , "~> 0.1.0"
|
23
|
+
|
24
|
+
gem.add_development_dependency "rake"
|
25
|
+
gem.add_development_dependency "rspec-core", "~> 2.13.0"
|
26
|
+
gem.add_development_dependency "rspec-expectations", "~> 2.13.0"
|
27
|
+
gem.add_development_dependency "rspec-mocks", "~> 2.13.0"
|
28
|
+
gem.add_development_dependency "webmock", "~> 1.11.0"
|
29
|
+
gem.add_development_dependency "debugger", "~> 1.5.0"
|
23
30
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tugboat
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-04-
|
12
|
+
date: 2013-04-23 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: thor
|
@@ -59,6 +59,102 @@ dependencies:
|
|
59
59
|
- - ~>
|
60
60
|
- !ruby/object:Gem::Version
|
61
61
|
version: 0.1.0
|
62
|
+
- !ruby/object:Gem::Dependency
|
63
|
+
name: rake
|
64
|
+
requirement: !ruby/object:Gem::Requirement
|
65
|
+
none: false
|
66
|
+
requirements:
|
67
|
+
- - ! '>='
|
68
|
+
- !ruby/object:Gem::Version
|
69
|
+
version: '0'
|
70
|
+
type: :development
|
71
|
+
prerelease: false
|
72
|
+
version_requirements: !ruby/object:Gem::Requirement
|
73
|
+
none: false
|
74
|
+
requirements:
|
75
|
+
- - ! '>='
|
76
|
+
- !ruby/object:Gem::Version
|
77
|
+
version: '0'
|
78
|
+
- !ruby/object:Gem::Dependency
|
79
|
+
name: rspec-core
|
80
|
+
requirement: !ruby/object:Gem::Requirement
|
81
|
+
none: false
|
82
|
+
requirements:
|
83
|
+
- - ~>
|
84
|
+
- !ruby/object:Gem::Version
|
85
|
+
version: 2.13.0
|
86
|
+
type: :development
|
87
|
+
prerelease: false
|
88
|
+
version_requirements: !ruby/object:Gem::Requirement
|
89
|
+
none: false
|
90
|
+
requirements:
|
91
|
+
- - ~>
|
92
|
+
- !ruby/object:Gem::Version
|
93
|
+
version: 2.13.0
|
94
|
+
- !ruby/object:Gem::Dependency
|
95
|
+
name: rspec-expectations
|
96
|
+
requirement: !ruby/object:Gem::Requirement
|
97
|
+
none: false
|
98
|
+
requirements:
|
99
|
+
- - ~>
|
100
|
+
- !ruby/object:Gem::Version
|
101
|
+
version: 2.13.0
|
102
|
+
type: :development
|
103
|
+
prerelease: false
|
104
|
+
version_requirements: !ruby/object:Gem::Requirement
|
105
|
+
none: false
|
106
|
+
requirements:
|
107
|
+
- - ~>
|
108
|
+
- !ruby/object:Gem::Version
|
109
|
+
version: 2.13.0
|
110
|
+
- !ruby/object:Gem::Dependency
|
111
|
+
name: rspec-mocks
|
112
|
+
requirement: !ruby/object:Gem::Requirement
|
113
|
+
none: false
|
114
|
+
requirements:
|
115
|
+
- - ~>
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: 2.13.0
|
118
|
+
type: :development
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
none: false
|
122
|
+
requirements:
|
123
|
+
- - ~>
|
124
|
+
- !ruby/object:Gem::Version
|
125
|
+
version: 2.13.0
|
126
|
+
- !ruby/object:Gem::Dependency
|
127
|
+
name: webmock
|
128
|
+
requirement: !ruby/object:Gem::Requirement
|
129
|
+
none: false
|
130
|
+
requirements:
|
131
|
+
- - ~>
|
132
|
+
- !ruby/object:Gem::Version
|
133
|
+
version: 1.11.0
|
134
|
+
type: :development
|
135
|
+
prerelease: false
|
136
|
+
version_requirements: !ruby/object:Gem::Requirement
|
137
|
+
none: false
|
138
|
+
requirements:
|
139
|
+
- - ~>
|
140
|
+
- !ruby/object:Gem::Version
|
141
|
+
version: 1.11.0
|
142
|
+
- !ruby/object:Gem::Dependency
|
143
|
+
name: debugger
|
144
|
+
requirement: !ruby/object:Gem::Requirement
|
145
|
+
none: false
|
146
|
+
requirements:
|
147
|
+
- - ~>
|
148
|
+
- !ruby/object:Gem::Version
|
149
|
+
version: 1.5.0
|
150
|
+
type: :development
|
151
|
+
prerelease: false
|
152
|
+
version_requirements: !ruby/object:Gem::Requirement
|
153
|
+
none: false
|
154
|
+
requirements:
|
155
|
+
- - ~>
|
156
|
+
- !ruby/object:Gem::Version
|
157
|
+
version: 1.5.0
|
62
158
|
description: A command line tool for interacting with your DigitalOcean droplets.
|
63
159
|
email:
|
64
160
|
- jackpearkes@gmail.com
|
@@ -68,6 +164,7 @@ extensions: []
|
|
68
164
|
extra_rdoc_files: []
|
69
165
|
files:
|
70
166
|
- .gitignore
|
167
|
+
- CHANGELOG.md
|
71
168
|
- CONTRIBUTING.md
|
72
169
|
- Gemfile
|
73
170
|
- LICENSE.md
|
@@ -92,12 +189,34 @@ files:
|
|
92
189
|
- lib/tugboat/middleware/inject_configuration.rb
|
93
190
|
- lib/tugboat/middleware/list_droplets.rb
|
94
191
|
- lib/tugboat/middleware/list_images.rb
|
192
|
+
- lib/tugboat/middleware/list_ssh_keys.rb
|
95
193
|
- lib/tugboat/middleware/restart_droplet.rb
|
96
194
|
- lib/tugboat/middleware/snapshot_droplet.rb
|
97
195
|
- lib/tugboat/middleware/ssh_droplet.rb
|
98
196
|
- lib/tugboat/version.rb
|
197
|
+
- spec/cli/authorize_cli_spec.rb
|
198
|
+
- spec/cli/create_cli_spec.rb
|
199
|
+
- spec/cli/destroy_cli_spec.rb
|
200
|
+
- spec/cli/droplets_cli_spec.rb
|
201
|
+
- spec/cli/halt_cli_spec.rb
|
202
|
+
- spec/cli/images_cli_spec.rb
|
203
|
+
- spec/cli/info_cli_spec.rb
|
204
|
+
- spec/cli/keys_cli_spec.rb
|
205
|
+
- spec/cli/restart_cli_spec.rb
|
206
|
+
- spec/cli/snapshot_cli_spec.rb
|
207
|
+
- spec/cli/version_cli_spec.rb
|
99
208
|
- spec/config_spec.rb
|
209
|
+
- spec/fixtures/create_droplet.json
|
210
|
+
- spec/fixtures/show_droplet.json
|
211
|
+
- spec/fixtures/show_droplets.json
|
212
|
+
- spec/fixtures/show_images.json
|
213
|
+
- spec/fixtures/show_images_global.json
|
214
|
+
- spec/fixtures/show_keys.json
|
215
|
+
- spec/middleware/base_spec.rb
|
216
|
+
- spec/middleware/inject_configuration_spec.rb
|
217
|
+
- spec/shared/environment.rb
|
100
218
|
- spec/spec_helper.rb
|
219
|
+
- tmp/.gitkeep
|
101
220
|
- tugboat.gemspec
|
102
221
|
homepage: https://github.com/pearkes/tugboat
|
103
222
|
licenses: []
|
@@ -124,5 +243,25 @@ signing_key:
|
|
124
243
|
specification_version: 3
|
125
244
|
summary: A command line tool for interacting with your DigitalOcean droplets.
|
126
245
|
test_files:
|
246
|
+
- spec/cli/authorize_cli_spec.rb
|
247
|
+
- spec/cli/create_cli_spec.rb
|
248
|
+
- spec/cli/destroy_cli_spec.rb
|
249
|
+
- spec/cli/droplets_cli_spec.rb
|
250
|
+
- spec/cli/halt_cli_spec.rb
|
251
|
+
- spec/cli/images_cli_spec.rb
|
252
|
+
- spec/cli/info_cli_spec.rb
|
253
|
+
- spec/cli/keys_cli_spec.rb
|
254
|
+
- spec/cli/restart_cli_spec.rb
|
255
|
+
- spec/cli/snapshot_cli_spec.rb
|
256
|
+
- spec/cli/version_cli_spec.rb
|
127
257
|
- spec/config_spec.rb
|
258
|
+
- spec/fixtures/create_droplet.json
|
259
|
+
- spec/fixtures/show_droplet.json
|
260
|
+
- spec/fixtures/show_droplets.json
|
261
|
+
- spec/fixtures/show_images.json
|
262
|
+
- spec/fixtures/show_images_global.json
|
263
|
+
- spec/fixtures/show_keys.json
|
264
|
+
- spec/middleware/base_spec.rb
|
265
|
+
- spec/middleware/inject_configuration_spec.rb
|
266
|
+
- spec/shared/environment.rb
|
128
267
|
- spec/spec_helper.rb
|