bosh-deployer 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 1cb7473685ca4ed4537ebbb9d5375f3afc34852d
4
+ data.tar.gz: 9afdb609e5166d969c627ebb5877670b0a2e7639
5
+ SHA512:
6
+ metadata.gz: 4db05f2a01f56fe739c13adceeb517d3e390a02b50084b5019b67408ca5b4c6e2ad12c383e617efed08fbbc3164d777d59b571430760a58b1da0c75c7b97ea64
7
+ data.tar.gz: a152d6b19616384688f5174a0825d3cb1b3e30e1ec9ff6a7765a18cf39797be7ff99bf6f3a2a06d434b2b6f6b45f6e51bab45964e407fb6a4a7516cbf62c086d
data/Gemfile.lock CHANGED
@@ -1,11 +1,10 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- bosh-deployer (0.1.0)
4
+ bosh-deployer (0.1.1)
5
5
  cancun
6
6
  readwritesettings
7
7
  recursive-open-struct
8
- redcard
9
8
  thor (~> 0.18)
10
9
 
11
10
  GEM
@@ -96,7 +95,6 @@ GEM
96
95
  rake (10.3.2)
97
96
  readwritesettings (3.0.1)
98
97
  recursive-open-struct (0.5.0)
99
- redcard (1.1.0)
100
98
  rspec (3.1.0)
101
99
  rspec-core (~> 3.1.0)
102
100
  rspec-expectations (~> 3.1.0)
data/lib/bosh-deployer.rb CHANGED
@@ -1,6 +1,6 @@
1
1
  module Bosh
2
2
  module Deployer
3
- VERSION = '0.1.0'
3
+ VERSION = '0.1.1'
4
4
  end
5
5
  end
6
6
 
@@ -10,7 +10,7 @@ class Bosh::Deployer::Cli::Commands::Deployment
10
10
  end
11
11
 
12
12
  def target
13
- `bosh target #{address}`
13
+ puts `bosh target #{address}`
14
14
  end
15
15
 
16
16
  def address
@@ -30,9 +30,9 @@ class Bosh::Deployer::Cli::Commands::Deployment
30
30
  return @filepath if @filepath
31
31
  @filepath = case name
32
32
  when 'microbosh'
33
- '~/.microbosh/settings.yml'
33
+ "#{ENV['HOME']}/.microbosh/settings.yml"
34
34
  when 'bosh'
35
- '~/.deployer/stubs/bosh.yml'
35
+ "#{ENV['HOME']}/.deployer/stubs/bosh.yml"
36
36
  end
37
37
  end
38
38
  end
@@ -2,25 +2,37 @@
2
2
  require 'bosh-deployer/cli/commands/deployment'
3
3
 
4
4
  describe Bosh::Deployer::Cli::Commands::Deployment do
5
- let(:deployment){ described_class.new(name, filepath) }
5
+ describe '#target' do
6
+ [{
7
+ name: 'bosh',
8
+ ip: '10.230.12.11',
9
+ filepath: 'spec/fixtures/manifests/bosh.yml',
10
+ default_filepath: "#{ENV['HOME']}/.deployer/stubs/bosh.yml"
11
+ },{
12
+ name: 'microbosh',
13
+ ip: 'IP',
14
+ filepath: 'spec/fixtures/bosh-bootstrap/settings.yml',
15
+ default_filepath: "#{ENV['HOME']}/.microbosh/settings.yml"
16
+ }].each do |dep|
17
+ describe "when targeting #{dep[:name]} providing yml \
18
+ source #{dep[:filepath]}" do
19
+ let(:name){ dep[:name] }
20
+ let(:filepath){ dep[:filepath] }
21
+ let(:deployment){ described_class.new(name, filepath) }
6
22
 
7
- [{
8
- name: 'bosh',
9
- ip: '10.230.12.11',
10
- filepath: 'spec/fixtures/manifests/bosh.yml'
11
- },{
12
- name: 'microbosh',
13
- ip: 'IP',
14
- filepath: 'spec/fixtures/bosh-bootstrap/settings.yml'
15
- }].each do |dep|
16
- describe "#target #{dep[:name]}" do
17
- let(:name){ dep[:name] }
18
- let(:filepath){ dep[:filepath] }
19
-
20
- it 'should target to the correct ip' do
21
- expect(deployment).to receive(:`)
23
+ it 'should target to the correct address' do
24
+ expect(deployment).to receive(:`)
22
25
  .with("bosh target #{dep[:ip]}")
23
- deployment.target
26
+ deployment.target
27
+ end
28
+ end
29
+
30
+ describe 'when using default sources' do
31
+ let(:name){ dep[:name] }
32
+ let(:filepath){ dep[:filepath] }
33
+ let(:deployment){ described_class.new(name) }
34
+
35
+ it{ expect(deployment.filepath).to eq(dep[:default_filepath]) }
24
36
  end
25
37
  end
26
38
  end
metadata CHANGED
@@ -1,113 +1,100 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bosh-deployer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
5
- prerelease:
4
+ version: 0.1.1
6
5
  platform: ruby
7
6
  authors:
8
7
  - Alan Moran
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2014-10-01 00:00:00.000000000 Z
11
+ date: 2014-10-02 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: thor
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
- - - ~>
17
+ - - "~>"
20
18
  - !ruby/object:Gem::Version
21
19
  version: '0.18'
22
20
  type: :runtime
23
21
  prerelease: false
24
22
  version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
23
  requirements:
27
- - - ~>
24
+ - - "~>"
28
25
  - !ruby/object:Gem::Version
29
26
  version: '0.18'
30
27
  - !ruby/object:Gem::Dependency
31
28
  name: readwritesettings
32
29
  requirement: !ruby/object:Gem::Requirement
33
- none: false
34
30
  requirements:
35
- - - ! '>='
31
+ - - ">="
36
32
  - !ruby/object:Gem::Version
37
33
  version: '0'
38
34
  type: :runtime
39
35
  prerelease: false
40
36
  version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
37
  requirements:
43
- - - ! '>='
38
+ - - ">="
44
39
  - !ruby/object:Gem::Version
45
40
  version: '0'
46
41
  - !ruby/object:Gem::Dependency
47
42
  name: cancun
48
43
  requirement: !ruby/object:Gem::Requirement
49
- none: false
50
44
  requirements:
51
- - - ! '>='
45
+ - - ">="
52
46
  - !ruby/object:Gem::Version
53
47
  version: '0'
54
48
  type: :runtime
55
49
  prerelease: false
56
50
  version_requirements: !ruby/object:Gem::Requirement
57
- none: false
58
51
  requirements:
59
- - - ! '>='
52
+ - - ">="
60
53
  - !ruby/object:Gem::Version
61
54
  version: '0'
62
55
  - !ruby/object:Gem::Dependency
63
56
  name: recursive-open-struct
64
57
  requirement: !ruby/object:Gem::Requirement
65
- none: false
66
58
  requirements:
67
- - - ! '>='
59
+ - - ">="
68
60
  - !ruby/object:Gem::Version
69
61
  version: '0'
70
62
  type: :runtime
71
63
  prerelease: false
72
64
  version_requirements: !ruby/object:Gem::Requirement
73
- none: false
74
65
  requirements:
75
- - - ! '>='
66
+ - - ">="
76
67
  - !ruby/object:Gem::Version
77
68
  version: '0'
78
69
  - !ruby/object:Gem::Dependency
79
70
  name: rake
80
71
  requirement: !ruby/object:Gem::Requirement
81
- none: false
82
72
  requirements:
83
- - - ! '>='
73
+ - - ">="
84
74
  - !ruby/object:Gem::Version
85
75
  version: '0'
86
76
  type: :development
87
77
  prerelease: false
88
78
  version_requirements: !ruby/object:Gem::Requirement
89
- none: false
90
79
  requirements:
91
- - - ! '>='
80
+ - - ">="
92
81
  - !ruby/object:Gem::Version
93
82
  version: '0'
94
83
  - !ruby/object:Gem::Dependency
95
84
  name: rspec
96
85
  requirement: !ruby/object:Gem::Requirement
97
- none: false
98
86
  requirements:
99
- - - ! '>='
87
+ - - ">="
100
88
  - !ruby/object:Gem::Version
101
89
  version: '0'
102
90
  type: :development
103
91
  prerelease: false
104
92
  version_requirements: !ruby/object:Gem::Requirement
105
- none: false
106
93
  requirements:
107
- - - ! '>='
94
+ - - ">="
108
95
  - !ruby/object:Gem::Version
109
96
  version: '0'
110
- description: ! ' CLI plugin for bosh to perform different deploying tasks'
97
+ description: " CLI plugin for bosh to perform different deploying tasks"
111
98
  email:
112
99
  - bonzofenix@gmail.com
113
100
  executables:
@@ -115,9 +102,9 @@ executables:
115
102
  extensions: []
116
103
  extra_rdoc_files: []
117
104
  files:
118
- - .gitignore
119
- - .rspec
120
- - .travis.yml
105
+ - ".gitignore"
106
+ - ".rspec"
107
+ - ".travis.yml"
121
108
  - Gemfile
122
109
  - Gemfile.lock
123
110
  - README.md
@@ -156,28 +143,27 @@ files:
156
143
  - stubs/cloudfoundry.yml.erb
157
144
  homepage: https://github.com/bonzofenix/bosh-deployer
158
145
  licenses: []
146
+ metadata: {}
159
147
  post_install_message:
160
148
  rdoc_options: []
161
149
  require_paths:
162
150
  - lib
163
151
  required_ruby_version: !ruby/object:Gem::Requirement
164
- none: false
165
152
  requirements:
166
- - - ! '>='
153
+ - - ">="
167
154
  - !ruby/object:Gem::Version
168
155
  version: '1.9'
169
156
  required_rubygems_version: !ruby/object:Gem::Requirement
170
- none: false
171
157
  requirements:
172
- - - ! '>='
158
+ - - ">="
173
159
  - !ruby/object:Gem::Version
174
160
  version: '0'
175
161
  requirements: []
176
162
  rubyforge_project:
177
- rubygems_version: 1.8.23.2
163
+ rubygems_version: 2.2.2
178
164
  signing_key:
179
- specification_version: 3
180
- summary: ! 'bosh-deployer can: - downloads and upload stemcells specifies on a manifest
165
+ specification_version: 4
166
+ summary: 'bosh-deployer can: - downloads and upload stemcells specifies on a manifest
181
167
  pending: - deploy Bosh - deploy CF'
182
168
  test_files:
183
169
  - spec/bosh_stub_spec.rb