bosh_aws_cpi 0.7.0 → 1.5.0.pre.1113

Sign up to get free protection for your applications and to get access to all the features.
Files changed (41) hide show
  1. data/README.md +22 -19
  2. data/bin/bosh_aws_console +1 -13
  3. data/lib/bosh_aws_cpi.rb +1 -1
  4. data/lib/cloud/aws/aki_picker.rb +7 -7
  5. data/lib/cloud/aws/availability_zone_selector.rb +40 -0
  6. data/lib/cloud/aws/cloud.rb +359 -476
  7. data/lib/cloud/aws/dynamic_network.rb +0 -6
  8. data/lib/cloud/aws/helpers.rb +10 -68
  9. data/lib/cloud/aws/instance_manager.rb +171 -0
  10. data/lib/cloud/aws/manual_network.rb +26 -0
  11. data/lib/cloud/aws/network_configurator.rb +33 -62
  12. data/lib/cloud/aws/resource_wait.rb +189 -0
  13. data/lib/cloud/aws/stemcell.rb +68 -0
  14. data/lib/cloud/aws/stemcell_creator.rb +114 -0
  15. data/lib/cloud/aws/tag_manager.rb +30 -0
  16. data/lib/cloud/aws/version.rb +1 -1
  17. data/lib/cloud/aws/vip_network.rb +9 -7
  18. data/lib/cloud/aws.rb +11 -2
  19. data/scripts/stemcell-copy.sh +37 -0
  20. metadata +45 -81
  21. data/Rakefile +0 -50
  22. data/lib/cloud/aws/registry_client.rb +0 -109
  23. data/spec/assets/stemcell-copy +0 -31
  24. data/spec/integration/cpi_test.rb +0 -78
  25. data/spec/spec_helper.rb +0 -121
  26. data/spec/unit/aki_picker_spec.rb +0 -29
  27. data/spec/unit/attach_disk_spec.rb +0 -143
  28. data/spec/unit/cloud_spec.rb +0 -32
  29. data/spec/unit/configure_networks_spec.rb +0 -113
  30. data/spec/unit/create_disk_spec.rb +0 -73
  31. data/spec/unit/create_stemcell_spec.rb +0 -113
  32. data/spec/unit/create_vm_spec.rb +0 -249
  33. data/spec/unit/delete_disk_spec.rb +0 -34
  34. data/spec/unit/delete_stemcell_spec.rb +0 -29
  35. data/spec/unit/delete_vm_spec.rb +0 -25
  36. data/spec/unit/detach_disk_spec.rb +0 -63
  37. data/spec/unit/helpers_spec.rb +0 -64
  38. data/spec/unit/network_configurator_spec.rb +0 -57
  39. data/spec/unit/reboot_vm_spec.rb +0 -38
  40. data/spec/unit/set_vm_metadata_spec.rb +0 -30
  41. data/spec/unit/validate_deployment_spec.rb +0 -16
@@ -1,30 +0,0 @@
1
- # Copyright (c) 2009-2012 VMware, Inc.
2
-
3
- require "spec_helper"
4
-
5
- describe Bosh::AwsCloud::Cloud, "#set_vm_metadata" do
6
- before :each do
7
- @instance = double("instance", :id => "i-foobar")
8
-
9
- @cloud = mock_cloud(mock_cloud_options) do |ec2|
10
- ec2.instances.stub(:[]).with("i-foobar").and_return(@instance)
11
- end
12
- end
13
-
14
- it "should add new tags" do
15
- metadata = {:job => "job", :index => "index"}
16
- @cloud.should_receive(:tag).with(@instance, :job, "job")
17
- @cloud.should_receive(:tag).with(@instance, :index, "index")
18
- @cloud.should_receive(:tag).with(@instance, "Name", "job/index")
19
- @cloud.set_vm_metadata("i-foobar", metadata)
20
- end
21
-
22
- it "should trim key and value length" do
23
- metadata = {"x"*128 => "y"*256}
24
- @instance.should_receive(:add_tag) do |key, options|
25
- key.size.should == 127
26
- options[:value].size.should == 255
27
- end
28
- @cloud.set_vm_metadata("i-foobar", metadata)
29
- end
30
- end
@@ -1,16 +0,0 @@
1
- # Copyright (c) 2009-2012 VMware, Inc.
2
-
3
- require File.expand_path("../../spec_helper", __FILE__)
4
-
5
- describe Bosh::AwsCloud::Cloud do
6
-
7
- it "doesn't implement `validate_deployment'" do
8
- cloud = make_cloud
9
- expect {
10
- cloud.validate_deployment({}, {})
11
- }.to raise_error(Bosh::Clouds::NotImplemented,
12
- "`validate_deployment' is not implemented "\
13
- "by Bosh::AwsCloud::Cloud")
14
- end
15
-
16
- end