boxgrinder-build 0.7.0 → 0.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/CHANGELOG CHANGED
@@ -1,3 +1,7 @@
1
+ v0.7.1
2
+
3
+ * [BGBUILD-124] Guestfs fails while mounting multiple partitions with '_' prefix
4
+ * [BGBUILD-123] Remove RPM database recreation code
1
5
 
2
6
  v0.7.0
3
7
 
data/Manifest CHANGED
@@ -0,0 +1,31 @@
1
+ CHANGELOG
2
+ LICENSE
3
+ Manifest
4
+ README
5
+ Rakefile
6
+ bin/boxgrinder-build
7
+ boxgrinder-build.gemspec
8
+ lib/boxgrinder-build/appliance.rb
9
+ lib/boxgrinder-build/helpers/appliance-customize-helper.rb
10
+ lib/boxgrinder-build/helpers/augeas-helper.rb
11
+ lib/boxgrinder-build/helpers/guestfs-helper.rb
12
+ lib/boxgrinder-build/helpers/image-helper.rb
13
+ lib/boxgrinder-build/helpers/linux-helper.rb
14
+ lib/boxgrinder-build/helpers/package-helper.rb
15
+ lib/boxgrinder-build/helpers/plugin-helper.rb
16
+ lib/boxgrinder-build/managers/plugin-manager.rb
17
+ lib/boxgrinder-build/plugins/base-plugin.rb
18
+ rubygem-boxgrinder-build.spec
19
+ spec/Rakefile
20
+ spec/appliance-spec.rb
21
+ spec/helpers/appliance-customize-helper-spec.rb
22
+ spec/helpers/augeas-helper-spec.rb
23
+ spec/helpers/guestfs-helper-spec.rb
24
+ spec/helpers/image-helper-spec.rb
25
+ spec/helpers/linux-helper-spec.rb
26
+ spec/helpers/package-helper-spec.rb
27
+ spec/helpers/plugin-helper-spec.rb
28
+ spec/managers/plugin-manager-spec.rb
29
+ spec/plugins/base-plugin-spec.rb
30
+ spec/rspec/src/appliances/jeos-f13.appl
31
+ spec/rspec/src/appliances/jeos-f13.ks
data/bin/boxgrinder-build CHANGED
@@ -46,7 +46,7 @@ module Commander
46
46
  end
47
47
 
48
48
  program :name, 'BoxGrinder Build'
49
- program :version, '0.6.5'
49
+ program :version, '0.7.1'
50
50
  program :description, "A tool for building VM images from simple definition files."
51
51
  program :help, 'Homepage', 'http://www.jboss.org/boxgrinder/build.html'
52
52
  program :help, 'Documentation', 'http://community.jboss.org/docs/DOC-14358'
@@ -2,11 +2,11 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{boxgrinder-build}
5
- s.version = "0.7.0"
5
+ s.version = "0.7.1"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Marek Goldmann"]
9
- s.date = %q{2010-12-17}
9
+ s.date = %q{2011-01-03}
10
10
  s.default_executable = %q{boxgrinder-build}
11
11
  s.description = %q{A tool for creating appliances from simple plain text files for various virtual environments.}
12
12
  s.email = %q{info@boxgrinder.org}
@@ -219,14 +219,6 @@ module BoxGrinder
219
219
  @log.trace "Partition mounted."
220
220
  end
221
221
 
222
- # TODO this is shitty, I know... https://bugzilla.redhat.com/show_bug.cgi?id=507188
223
- def rebuild_rpm_database
224
- @log.debug "Cleaning RPM database..."
225
- @guestfs.sh("rm -f /var/lib/rpm/__db.*")
226
- @guestfs.sh("rpm --rebuilddb")
227
- @log.debug "Cleaning RPM database finished."
228
- end
229
-
230
222
  def mount_partitions
231
223
  root_partition = nil
232
224
 
@@ -245,7 +237,7 @@ module BoxGrinder
245
237
 
246
238
  @guestfs.list_partitions.each do |partition|
247
239
  next if partition == root_partition
248
- mount_partition(partition, @guestfs.sh("/sbin/e2label #{partition}").chomp.strip)
240
+ mount_partition(partition, @guestfs.sh("/sbin/e2label #{partition}").strip.chomp.gsub('_', ''))
249
241
  end
250
242
  end
251
243
 
@@ -5,7 +5,7 @@
5
5
 
6
6
  Summary: A tool for creating appliances from simple plain text files
7
7
  Name: rubygem-%{gemname}
8
- Version: 0.7.0
8
+ Version: 0.7.1
9
9
  Release: 1%{?dist}
10
10
  Group: Development/Languages
11
11
  License: LGPLv3+
@@ -85,6 +85,11 @@ popd
85
85
  %{gemdir}/doc/%{gemname}-%{version}
86
86
 
87
87
  %changelog
88
+ * Mon Dec 20 2010 <mgoldman@redhat.com> - 0.7.1-1
89
+ - Upstream release: 0.7.1
90
+ - [BGBUILD-123] Remove RPM database recreation code
91
+ - [BGBUILD-124] Guestfs fails while mounting multiple partitions with '_' prefix
92
+
88
93
  * Fri Dec 17 2010 <mgoldman@redhat.com> - 0.7.0-1
89
94
  - Updated to upstream version: 0.7.0
90
95
  - [BGBUILD-113] Allow to specify supported file formats for operating system plugin
@@ -98,17 +98,26 @@ module BoxGrinder
98
98
  @helper.mount_partition("/dev/sda", "/")
99
99
  end
100
100
 
101
- it "should rebuild RPM database for Fedora" do
101
+ it "should mount partitions" do
102
102
  guestfs = mock('Guestfs')
103
103
 
104
- guestfs.should_receive(:sh).with("rm -f /var/lib/rpm/__db.*")
105
- guestfs.should_receive(:sh).with("rpm --rebuilddb")
104
+ guestfs.should_receive(:list_partitions).and_return(['/boot', '/'])
105
+
106
+ @helper.should_receive(:mount_partition).with('/boot', '/')
107
+ guestfs.should_receive(:exists).with('/sbin/e2label').and_return(0)
108
+ guestfs.should_receive(:umount).with('/boot')
109
+ @helper.should_receive(:mount_partition).with('/', '/')
110
+ guestfs.should_receive(:exists).with('/sbin/e2label').and_return(1)
111
+
112
+ guestfs.should_receive(:list_partitions).and_return(['/boot', '/'])
113
+ guestfs.should_receive(:sh).with('/sbin/e2label /boot').and_return('/boot')
114
+ @helper.should_receive(:mount_partition).with('/boot', '/boot')
106
115
 
107
116
  @helper.instance_variable_set(:@guestfs, guestfs)
108
- @helper.rebuild_rpm_database
117
+ @helper.mount_partitions
109
118
  end
110
119
 
111
- it "should mount partitions" do
120
+ it "should mount partitions with new type of labels" do
112
121
  guestfs = mock('Guestfs')
113
122
 
114
123
  guestfs.should_receive(:list_partitions).and_return(['/boot', '/'])
@@ -120,7 +129,7 @@ module BoxGrinder
120
129
  guestfs.should_receive(:exists).with('/sbin/e2label').and_return(1)
121
130
 
122
131
  guestfs.should_receive(:list_partitions).and_return(['/boot', '/'])
123
- guestfs.should_receive(:sh).with('/sbin/e2label /boot').and_return('/boot')
132
+ guestfs.should_receive(:sh).with('/sbin/e2label /boot').and_return('_/boot')
124
133
  @helper.should_receive(:mount_partition).with('/boot', '/boot')
125
134
 
126
135
  @helper.instance_variable_set(:@guestfs, guestfs)
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: boxgrinder-build
3
3
  version: !ruby/object:Gem::Version
4
- hash: 3
4
+ hash: 1
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 7
9
- - 0
10
- version: 0.7.0
9
+ - 1
10
+ version: 0.7.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Marek Goldmann
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-12-17 00:00:00 +01:00
18
+ date: 2011-01-03 00:00:00 +01:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency