abiquo-etk 0.4.32 → 0.4.33

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.4.32
1
+ 0.4.33
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{abiquo-etk}
8
- s.version = "0.4.32"
8
+ s.version = "0.4.33"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Sergio Rubio"]
12
- s.date = %q{2010-11-03}
12
+ s.date = %q{2010-11-04}
13
13
  s.description = %q{Tools to troubleshoot and manage your Abiquo installation}
14
14
  s.email = %q{srubio@abiquo.com}
15
15
  s.executables = ["abiquo-check-16-install", "abicli", "abiquo-initenv"]
@@ -5,7 +5,7 @@
5
5
 
6
6
  Summary: Abiquo Elite Toolkit
7
7
  Name: rubygem-%{gemname}
8
- Version: 0.4.32
8
+ Version: 0.4.33
9
9
  Release: 1%{?dist}
10
10
  Group: Development/Languages
11
11
  License: GPLv2+ or Ruby
@@ -55,6 +55,9 @@ rm -rf %{buildroot}
55
55
 
56
56
 
57
57
  %changelog
58
+ * Thu Nov 04 2010 : Sergio Rubio <srubio@abiquo.com> - 0.4.33-1
59
+ - Updated to upstream 0.4.33-1
60
+
58
61
  * Tue Nov 03 2010 : Sergio Rubio <srubio@abiquo.com> - 0.4.32-1
59
62
  - Updated to upstream 0.4.32-1
60
63
 
@@ -86,6 +86,16 @@ if ARGV[0] == 'instant-deploy'
86
86
  class InstantDeployCLI
87
87
  include Mixlib::CLI
88
88
 
89
+ option :target_dir,
90
+ :long => '--target-dir NAME',
91
+ :description => 'Directory where the VM disk and ISO are created',
92
+ :default => "abiquo-instant-deploy-#{Time.now.strftime "%s"}"
93
+
94
+ option :vm_name,
95
+ :long => '--vm-name NAME',
96
+ :description => 'Virtual Machine name',
97
+ :default => "instant-deploy"
98
+
89
99
  option :iso_url,
90
100
  :long => '--iso-url URL',
91
101
  :description => 'Abiquo ISO URL'
@@ -192,6 +202,8 @@ if ARGV[0] == 'instant-deploy'
192
202
  tomcat_port = params[:tomcat_port]
193
203
  ssh_port = params[:ssh_port]
194
204
  graphics = ''
205
+ vm_name = params[:vm_name]
206
+
195
207
  if params[:vnc]
196
208
  graphics = "--vnc :#{params[:vnc_display]}"
197
209
  end
@@ -249,16 +261,16 @@ if ARGV[0] == 'instant-deploy'
249
261
  f.puts "MEM=#{mem}"
250
262
  f.puts "TAP=vtap0"
251
263
  f.puts ""
252
- f.puts "#{SystemCommands.kvm} #{graphics} -m $MEM -drive file=#{File.basename(disk_file)} -net user,hostfwd=tcp:0.0.0.0:#{tomcat_port}-:80,hostfwd=tcp:0.0.0.0:#{ssh_port}-:22 -net nic -boot order=c > /dev/null"
264
+ f.puts "#{SystemCommands.kvm} -name #{vm_name} #{graphics} -m $MEM -drive file=#{File.basename(disk_file)} -net user,hostfwd=tcp:0.0.0.0:#{tomcat_port}-:80,hostfwd=tcp:0.0.0.0:#{ssh_port}-:22 -net nic -boot order=c > /dev/null"
253
265
  f.puts ""
254
266
  f.puts "#"
255
267
  f.puts "# Comment the above line and uncomment this to use bridged networking."
256
268
  f.puts "# You will need to have a working bridge setup in order to use this."
257
269
  f.puts "# Update TAP variable above to fill your needs."
258
270
  f.puts "#"
259
- f.puts "#sudo #{SystemCommands.kvm} #{graphics} -m $MEM -drive file=#{File.basename(disk_file)} -net tap,ifname=$TAP -net nic -boot order=c > /dev/null 2>&1"
271
+ f.puts "#sudo #{SystemCommands.kvm} -name #{vm_name} #{graphics} -m $MEM -drive file=#{File.basename(disk_file)} -net tap,ifname=$TAP -net nic -boot order=c > /dev/null 2>&1"
260
272
  end
261
- output = `#{SystemCommands.kvm} #{graphics} -m 1024 -drive file=#{disk_file} -net user,hostfwd=tcp:0.0.0.0:#{tomcat_port}-:80,hostfwd=tcp:0.0.0.0:#{ssh_port}-:22 -net nic -drive file=#{cdrom},media=cdrom -boot order=cd -boot once=d 2>&1 `
273
+ output = `#{SystemCommands.kvm} -name #{vm_name} #{graphics} -m 1024 -drive file=#{disk_file} -net user,hostfwd=tcp:0.0.0.0:#{tomcat_port}-:80,hostfwd=tcp:0.0.0.0:#{ssh_port}-:22 -net nic -drive file=#{cdrom},media=cdrom -boot order=cd -boot once=d 2>&1 `
262
274
  if $? != 0
263
275
  puts "Error booting the VM: #{output}"
264
276
  end
@@ -270,14 +282,13 @@ if ARGV[0] == 'instant-deploy'
270
282
  version
271
283
  end
272
284
 
273
- target_dir = "abiquo-instant-deploy-#{Time.now.strftime "%s"}"
274
-
275
285
  trap("INT") { puts "\n\nCleaning Environment..."; exit }
276
286
 
277
287
  preflight_check
278
288
 
279
289
  cli = InstantDeployCLI.new
280
290
  cli.parse_options
291
+ target_dir = cli.config[:target_dir]
281
292
  url = cli.config[:iso_url]
282
293
  if url.nil?
283
294
  $stderr.puts "\n--iso-url argument is mandatory.\n\n"
@@ -290,6 +301,7 @@ if ARGV[0] == 'instant-deploy'
290
301
  puts "Building the cloud into #{target_dir.bold} directory..."
291
302
  install_iso(:target_dir => target_dir, :iso_url => url, :mem => cli.config[:mem],
292
303
  :tomcat_port => cli.config[:tomcat_port],
304
+ :vm_name => cli.config[:vm_name],
293
305
  :ssh_port => cli.config[:ssh_port],
294
306
  :vnc => cli.config[:vnc],
295
307
  :vnc_display => cli.config[:vnc_display]
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: abiquo-etk
3
3
  version: !ruby/object:Gem::Version
4
- hash: 79
4
+ hash: 77
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 4
9
- - 32
10
- version: 0.4.32
9
+ - 33
10
+ version: 0.4.33
11
11
  platform: ruby
12
12
  authors:
13
13
  - Sergio Rubio
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-11-03 00:00:00 +01:00
18
+ date: 2010-11-04 00:00:00 +01:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency