Rev 2 of new qmf console
by Jason Guiditta
[PATCH conductor] Initial version of qmf console for v2 factory.
Directions for install and test run are now in the README. Note there
are also some directions there for the wrapper service that I have
not sent yet, as it is still rather static and needs cleanup.
Also, at the current time, I expect one test to fail, due to a bug
in the agent. Once that bug is fixed, test should passed here. Likely
this will be Scott doing testing, as he has pre-reqs installed already
and I woudl rather not see others broken until we can flip the switch
over to the new qmf/factory.
For testing, the error you should expect to see is somthing like:
Spec::Mocks::MockExpectationError in 'ImageFactoryConsole needs a real agent running#push_image should return a build-adaptor with uuid'
#<BaseHandler:0x7f05feaa8830> expected :handle_failed with (#<Qmf2::Data:0x7f05fea5eb68 @impl=#<Cqmf2::Data:0x7f05fea5ebe0>, @schema=#<Qmf2::Schema:0x7f05fea5dd08 @impl=#<Cqmf2::Schema:0x7f05fea5dd80>>>) 0 times, but received it once
./spec/image_factory/console_spec.rb:41:
-j
12 years, 9 months
[PATCH aeolus 1/3] Updated Views for new HWP
by Martyn Taylor
From: Martyn Taylor <mtaylor(a)redhat.com>
---
.../admin/hardware_profiles_controller.rb | 26 +-----
src/app/views/admin/hardware_profiles/_form.haml | 20 +----
src/app/views/admin/hardware_profiles/_list.haml | 5 +-
.../views/admin/hardware_profiles/_properties.haml | 13 +---
src/features/hardware_profile.feature | 86 ++++++++++----------
5 files changed, 56 insertions(+), 94 deletions(-)
diff --git a/src/app/controllers/admin/hardware_profiles_controller.rb b/src/app/controllers/admin/hardware_profiles_controller.rb
index 75c6ab1..04e291f 100644
--- a/src/app/controllers/admin/hardware_profiles_controller.rb
+++ b/src/app/controllers/admin/hardware_profiles_controller.rb
@@ -133,13 +133,8 @@ class Admin::HardwareProfilesController < ApplicationController
def properties
@properties_header = [
{ :name => "Name", :sort_attr => :name},
- { :name => "Kind", :sort_attr => :kind },
- { :name => "Range First", :sort_attr => :range_first},
- { :name => "Range Last", :sort_attr => :range_last },
- { :name => "Enum Entries", :sort_attr => :false },
- { :name => "Default Value", :sort_attr => :value},
- { :name => "Unit", :sort_attr => :unit}
- ]
+ { :name => "Unit", :sort_attr => :unit},
+ { :name => "Minimum Value", :sort_attr => :value}]
@hwp_properties = [@hardware_profile.memory, @hardware_profile.cpu, @hardware_profile.storage, @hardware_profile.architecture]
end
@@ -168,11 +163,7 @@ class Admin::HardwareProfilesController < ApplicationController
@header = [
{ :name => "Name", :sort_attr => :name},
{ :name => "Unit", :sort_attr => :unit},
- { :name => "Kind", :sort_attr => :kind },
- { :name => "Value (Default)", :sort_attr => :value},
- { :name => "Enum Entries", :sort_attr => :false },
- { :name => "Range First", :sort_attr => :range_first},
- { :name => "Range Last", :sort_attr => :range_last }]
+ { :name => "Minimum Value", :sort_attr => :value}]
end
def set_params_and_header
@@ -210,17 +201,10 @@ class Admin::HardwareProfilesController < ApplicationController
hwpp.nil? ? hardwareProfileProperty = HardwareProfileProperty.new : hardwareProfileProperty = hwpp
hardwareProfileProperty.name = params[:name]
- hardwareProfileProperty.kind = params[:kind]
+ hardwareProfileProperty.kind = "fixed"
hardwareProfileProperty.value = params[:value]
hardwareProfileProperty.unit = params[:unit]
- case hardwareProfileProperty.kind
- when "range"
- hardwareProfileProperty.range_first = params[:range_first]
- hardwareProfileProperty.range_last = params[:range_last]
- when "enum"
- hardwareProfileProperty.property_enum_entries = params[:property_enum_entries].split(%r{,\s*}).map { |value| PropertyEnumEntry.new(:value => value, :hardware_profile_property => hardwareProfileProperty) }
- end
- hardwareProfileProperty
+ return hardwareProfileProperty
end
end
diff --git a/src/app/views/admin/hardware_profiles/_form.haml b/src/app/views/admin/hardware_profiles/_form.haml
index 4327007..70c982b 100644
--- a/src/app/views/admin/hardware_profiles/_form.haml
+++ b/src/app/views/admin/hardware_profiles/_form.haml
@@ -10,21 +10,9 @@
%td
=hwpp_form.text_field(:unit, :size => 5, :readonly => "readonly")
%td
- -unless type == :architecture
- =hwpp_form.select("kind", ["fixed", "range", "enum"], {})
+ -if type == :architecture
+ =hwpp_form.select("value", ["i386", "x86_64"], {})
-else
- =hwpp_form.select("kind", ["fixed"], {})
- %td
- =hwpp_form.text_field(:value)
- %td
- -unless type == :architecture
- =hwpp_form.text_field(:property_enum_entries)
- %td
- -unless type == :architecture
- =hwpp_form.text_field(:range_first)
- %td
- -unless type == :architecture
- =hwpp_form.text_field(:range_last)
+ =hwpp_form.text_field(:value)
= hwp_form.submit 'Check Matches', :class => "submit formbutton"
-<!-- Disabled until condor can support new HWP model -->
-<!-- = hwp_form.submit 'Save', :class => 'submit formbutton', :disabled => 'disabled' -->
\ No newline at end of file
+= hwp_form.submit 'Save', :class => 'submit formbutton'
\ No newline at end of file
diff --git a/src/app/views/admin/hardware_profiles/_list.haml b/src/app/views/admin/hardware_profiles/_list.haml
index 621f53b..eee5ff1 100644
--- a/src/app/views/admin/hardware_profiles/_list.haml
+++ b/src/app/views/admin/hardware_profiles/_list.haml
@@ -1,8 +1,7 @@
- form_tag do
#object-actions
- <!-- Disabled until condor can support new HWP model -->
- <!-- = link_to "New Hardware Profile", new_admin_hardware_profile_path, :class => 'button' -->
- <!-- = restful_submit_tag "Delete", "destroy", multi_destroy_admin_hardware_profiles_path -->
+ = link_to "New Hardware Profile", new_admin_hardware_profile_path, :class => 'button'
+ = restful_submit_tag "Delete", 'destroy', multi_destroy_admin_hardware_profiles_path, 'DELETE', :id => 'delete_button'
#selections
%p
Select:
diff --git a/src/app/views/admin/hardware_profiles/_properties.haml b/src/app/views/admin/hardware_profiles/_properties.haml
index 04517bf..0739b84 100644
--- a/src/app/views/admin/hardware_profiles/_properties.haml
+++ b/src/app/views/admin/hardware_profiles/_properties.haml
@@ -1,7 +1,6 @@
%h3
= @hardware_profile.name + "(" + (@hardware_profile.provider_id.nil? ? "Front End" : "Provider" ) + ")"
-<!-- Disabled until condor can support new HWP model -->
-<!-- = link_to 'Edit', edit_admin_hardware_profile_path(@hardware_profile), :class => 'button' -->
+ = link_to 'Edit', edit_admin_hardware_profile_path(@hardware_profile), :class => 'button'
%table
= sortable_table_header @properties_header
- @hwp_properties.each do |hwpp|
@@ -9,14 +8,6 @@
%td
=hwpp.name.nil? ? "n/a" : hwpp.name
%td
- =hwpp.kind.nil? ? "n/a" : hwpp.kind
- %td
- =hwpp.range_first.nil? ? "n/a" : hwpp.range_first
- %td
- =hwpp.range_last.nil? ? "n/a" : hwpp.range_last
- %td
- =hwpp.property_enum_entries.empty? ? "n/a" : (hwpp.property_enum_entries.collect { |enum| enum.value.to_s }).join(", ")
+ =hwpp.unit.nil? ? "n/a" : hwpp.unit
%td
=hwpp.value.nil? ? "n/a" : hwpp.value
- %td
- =hwpp.unit.nil? ? "n/a" : hwpp.unit
diff --git a/src/features/hardware_profile.feature b/src/features/hardware_profile.feature
index ce06e1f..e35e9a3 100644
--- a/src/features/hardware_profile.feature
+++ b/src/features/hardware_profile.feature
@@ -20,7 +20,7 @@ Feature: Manage Pools
| m1-large | 4096 | 4 | 850 | x86_64 |
| m1-xlarge | 8192 | 8 | 1690 | x86_64 |
- Scenario: View a Hardware Profiles Properties
+ Scenario: View a Front End Hardware Profiles Properties
Given there are the following conductor hardware profiles:
| name | memory | cpu |storage | architecture |
| m1-small | 1740 | 2 | 160 | i386 |
@@ -29,11 +29,11 @@ Feature: Manage Pools
And I am on the the hardware profiles page
When I follow "m1-small"
Then I should see the following:
- | Name | Kind | Range First | Range Last | Enum Entries | Default Value | Unit |
- | memory | fixed | n/a | n/a | n/a | 1740 | MB |
- | cpu | fixed | n/a | n/a | n/a | 2 | count |
- | storage | fixed | n/a | n/a | n/a | 160 | GB |
- | architecture | fixed | n/a | n/a | n/a | i386 | label |
+ | Name | Minimum Value | Unit |
+ | memory | 1740 | MB |
+ | cpu | 2 | count |
+ | storage | 160 | GB |
+ | architecture | i386 | label |
Scenario: View a Front End Hardware Profiles Matching Provider Hardware Profiles
Given there are the following conductor hardware profiles:
@@ -84,22 +84,22 @@ Feature: Manage Pools
When I follow "mock1"
Then I should see "mock1(Front End)"
-# Scenario: Create a new Hardware Profile
-# Given I am an authorised user
-# And I am on the hardware profiles page
-# When I follow "New Hardware Profile"
-# Then I should be on the new hardware profile page
-# When I fill in "name" with "Test Hardware Profile"
-# And I enter the following details for the Hardware Profile Properties
-# | name | kind | range_first | range_last | property_enum_entries | value | unit |
-# | memory | fixed | | | | 1740 | MB |
-# | cpu | range | 1 | 4 | | 2 | count |
-# | storage | enum | | | 250, 300, 350 | 300 | GB |
-# | architecture | fixed | | | | i386 | label |
-# And I press "Save"
-# Then I should be on the hardware profiles page
-# And I should see the following:
-# | Test Hardware Profile | 1740 | 1 - 4 | 250, 300, 350 | i386 |
+ Scenario: Create a new Hardware Profile
+ Given I am an authorised user
+ And I am on the hardware profiles page
+ When I follow "New Hardware Profile"
+ Then I should be on the new hardware profile page
+ When I fill in "name" with "Test Hardware Profile"
+ And I enter the following details for the Hardware Profile Properties
+ | name | value | unit |
+ | memory | 1740 | MB |
+ | cpu | 2 | count |
+ | storage | 250 | GB |
+ | architecture | i386 | label |
+ And I press "Save"
+ Then I should be on the hardware profiles page
+ And I should see the following:
+ | Test Hardware Profile | 1740 | 2 | 250 | i386 |
# Scenario: Check New Hardware Profile matching Provider Hardware Profiles
# Given I am an authorised user
@@ -122,24 +122,24 @@ Feature: Manage Pools
# | m1-small | 1740 | 1 | 250 | i386 |
# | m1-medium | 1740 | 2 | 500 | i386 |
-# Scenario: Update a HardwareProfile
-# Given I am an authorised user
-# And there are the following aggregator hardware profiles:
-# | name | memory | cpu |storage | architecture |
-# | m1-small | 1740 | 2 | 160 | i386 |
-# And I am on the hardware profiles page
-# When I follow "m1-small"
-# Then I should see "Properties"
-# When I follow "edit"
-# Then I should be on the edit hardware profiles page
-# When I enter the following details for the Hardware Profile Properties
-# | name | kind | range_first | range_last | property_enum_entries | value |
-# | memory | fixed | | | | 1740 |
-# | cpu | range | 1 | 4 | | 1 |
-# | storage | range | 250 | 500 | | 300 |
-# | architecture | fixed | | | | i386 |
-# And I press "Save"
-# Then I should be on the hardware profiles page
-# Then I should see the following:
-# | Name | Memory | CPU | Storage | Architecture |
-# | m1-small | 1740 | 1 - 4 | 250 - 500 | i386 |
+ Scenario: Update a HardwareProfile
+ Given I am an authorised user
+ And there are the following conductor hardware profiles:
+ | name | memory | cpu |storage | architecture |
+ | m1-small | 2048 | 4 | 160 | x86_64 |
+ And I am on the hardware profiles page
+ When I follow "m1-small"
+ Then I should see "Properties"
+ When I follow "edit"
+ Then I should be on the edit hardware profiles page
+ When I enter the following details for the Hardware Profile Properties
+ | name | value | unit |
+ | memory | 1740 | MB |
+ | cpu | 2 | count |
+ | storage | 250 | GB |
+ | architecture | i386 | label |
+ And I press "Save"
+ Then I should be on the hardware profiles page
+ Then I should see the following:
+ | Name | Memory | CPU | Storage | Architecture |
+ | m1-small | 1740 | 2 | 250 | i386 |
--
1.7.4
12 years, 9 months
[PATCH aeolus 1/2] Removed HardwareProfile Mapping
by Martyn Taylor
From: Martyn Taylor <mtaylor(a)redhat.com>
---
src/app/models/hardware_profile.rb | 27 --------------------
src/app/models/provider.rb | 18 -------------
...110302124928_remove_hardware_profile_mapping.rb | 12 +++++++++
3 files changed, 12 insertions(+), 45 deletions(-)
create mode 100644 src/db/migrate/20110302124928_remove_hardware_profile_mapping.rb
diff --git a/src/app/models/hardware_profile.rb b/src/app/models/hardware_profile.rb
index daa66e7..75a501b 100644
--- a/src/app/models/hardware_profile.rb
+++ b/src/app/models/hardware_profile.rb
@@ -71,18 +71,6 @@ class HardwareProfile < ActiveRecord::Base
accepts_nested_attributes_for :memory, :cpu, :storage, :architecture
- has_and_belongs_to_many :conductor_hardware_profiles,
- :class_name => "HardwareProfile",
- :join_table => "hardware_profile_map",
- :foreign_key => "provider_hardware_profile_id",
- :association_foreign_key => "conductor_hardware_profile_id"
-
- has_and_belongs_to_many :provider_hardware_profiles,
- :class_name => "HardwareProfile",
- :join_table => "hardware_profile_map",
- :foreign_key => "conductor_hardware_profile_id",
- :association_foreign_key => "provider_hardware_profile_id"
-
validates_presence_of :external_key, :if => Proc.new { |hwp| !hwp.provider.nil? }
validates_uniqueness_of :external_key, :scope => [:provider_id], :if => Proc.new { |hwp| !hwp.provider.nil? }
@@ -99,21 +87,6 @@ class HardwareProfile < ActiveRecord::Base
!provider.nil?
end
- # FIXME: what about custom instance profiles?
- def validate
- if provider.nil?
- if !conductor_hardware_profiles.empty?
- errors.add(:conductor_hardware_profiles,
- "Conductor profiles only allowed for provider profiles")
- end
- else
- if !provider_hardware_profiles.empty?
- errors.add(:provider_hardware_profiles,
- "Provider profiles only allowed for conductor profiles")
- end
- end
- end
-
def add_properties(api_profile)
self.memory = new_property(api_profile.memory)
self.storage = new_property(api_profile.storage)
diff --git a/src/app/models/provider.rb b/src/app/models/provider.rb
index dfb94c3..1e6b27c 100644
--- a/src/app/models/provider.rb
+++ b/src/app/models/provider.rb
@@ -116,24 +116,6 @@ class Provider < ActiveRecord::Base
:provider_id => id)
ar_hardware_profile.add_properties(hardware_profile)
ar_hardware_profile.save!
-
- front_hwp = HardwareProfile.new(:external_key =>ar_hardware_profile.external_key,
- :name => ar_hardware_profile.name)
-
- # Omit creation of new front-end hardware profile if
- # hardware profile with same external_key exists
-
- avail_hwp = HardwareProfile.frontend.find(:all, :conditions => { :external_key => front_hwp.external_key })
-
- if avail_hwp.empty?
- front_hwp.add_properties(hardware_profile)
- front_hwp.provider_hardware_profiles << ar_hardware_profile
- front_hwp.save!
- else
- avail_hwp.each do |hwp|
- hwp.provider_hardware_profiles << ar_hardware_profile
- end
- end
end
end
end
diff --git a/src/db/migrate/20110302124928_remove_hardware_profile_mapping.rb b/src/db/migrate/20110302124928_remove_hardware_profile_mapping.rb
new file mode 100644
index 0000000..61b8724
--- /dev/null
+++ b/src/db/migrate/20110302124928_remove_hardware_profile_mapping.rb
@@ -0,0 +1,12 @@
+class RemoveHardwareProfileMapping < ActiveRecord::Migration
+ def self.up
+ drop_table :hardware_profile_map
+ end
+
+ def self.down
+ create_table "hardware_profile_map", :force => true, :id => false do |t|
+ t.column "conductor_hardware_profile_id", :integer
+ t.column "provider_hardware_profile_id", :integer
+ end
+ end
+end
--
1.7.4
12 years, 9 months
v2 factory console
by Jason Guiditta
This patch can be tested by setting up the required deps in the README,
and running:
spec spec/image_factory/console_spec.rb --format nested --color
from the console directory.
[PATCH conductor] Initial version of qmf console for v2 factory.
Still TODO on this are proper pathing for require statements,
gemspec/spec updates, and of course the wrapper service, which should
be out tomorrow.
-j
12 years, 9 months
warehouse integration (rev. 4)
by Jan Provazník
Same as previous revision, but warehouse_sync script is removed - will do
separate patchset with init script for it.
Requires patches: delayed_job, provider type, Image Warehouse API library for
conductor.
12 years, 9 months
[PATCH aeolus 1/2] Removed HardwareProfile Mapping
by Martyn Taylor
From: Martyn Taylor <mtaylor(a)redhat.com>
---
src/app/models/hardware_profile.rb | 27 --------------------
src/app/models/provider.rb | 18 -------------
...110302124928_remove_hardware_profile_mapping.rb | 12 +++++++++
.../step_definitions/hardware_profile_steps.rb | 3 --
src/features/support/custom.rb | 10 -------
src/spec/models/hardware_profile_spec.rb | 24 -----------------
6 files changed, 12 insertions(+), 82 deletions(-)
create mode 100644 src/db/migrate/20110302124928_remove_hardware_profile_mapping.rb
diff --git a/src/app/models/hardware_profile.rb b/src/app/models/hardware_profile.rb
index daa66e7..75a501b 100644
--- a/src/app/models/hardware_profile.rb
+++ b/src/app/models/hardware_profile.rb
@@ -71,18 +71,6 @@ class HardwareProfile < ActiveRecord::Base
accepts_nested_attributes_for :memory, :cpu, :storage, :architecture
- has_and_belongs_to_many :conductor_hardware_profiles,
- :class_name => "HardwareProfile",
- :join_table => "hardware_profile_map",
- :foreign_key => "provider_hardware_profile_id",
- :association_foreign_key => "conductor_hardware_profile_id"
-
- has_and_belongs_to_many :provider_hardware_profiles,
- :class_name => "HardwareProfile",
- :join_table => "hardware_profile_map",
- :foreign_key => "conductor_hardware_profile_id",
- :association_foreign_key => "provider_hardware_profile_id"
-
validates_presence_of :external_key, :if => Proc.new { |hwp| !hwp.provider.nil? }
validates_uniqueness_of :external_key, :scope => [:provider_id], :if => Proc.new { |hwp| !hwp.provider.nil? }
@@ -99,21 +87,6 @@ class HardwareProfile < ActiveRecord::Base
!provider.nil?
end
- # FIXME: what about custom instance profiles?
- def validate
- if provider.nil?
- if !conductor_hardware_profiles.empty?
- errors.add(:conductor_hardware_profiles,
- "Conductor profiles only allowed for provider profiles")
- end
- else
- if !provider_hardware_profiles.empty?
- errors.add(:provider_hardware_profiles,
- "Provider profiles only allowed for conductor profiles")
- end
- end
- end
-
def add_properties(api_profile)
self.memory = new_property(api_profile.memory)
self.storage = new_property(api_profile.storage)
diff --git a/src/app/models/provider.rb b/src/app/models/provider.rb
index dfb94c3..1e6b27c 100644
--- a/src/app/models/provider.rb
+++ b/src/app/models/provider.rb
@@ -116,24 +116,6 @@ class Provider < ActiveRecord::Base
:provider_id => id)
ar_hardware_profile.add_properties(hardware_profile)
ar_hardware_profile.save!
-
- front_hwp = HardwareProfile.new(:external_key =>ar_hardware_profile.external_key,
- :name => ar_hardware_profile.name)
-
- # Omit creation of new front-end hardware profile if
- # hardware profile with same external_key exists
-
- avail_hwp = HardwareProfile.frontend.find(:all, :conditions => { :external_key => front_hwp.external_key })
-
- if avail_hwp.empty?
- front_hwp.add_properties(hardware_profile)
- front_hwp.provider_hardware_profiles << ar_hardware_profile
- front_hwp.save!
- else
- avail_hwp.each do |hwp|
- hwp.provider_hardware_profiles << ar_hardware_profile
- end
- end
end
end
end
diff --git a/src/db/migrate/20110302124928_remove_hardware_profile_mapping.rb b/src/db/migrate/20110302124928_remove_hardware_profile_mapping.rb
new file mode 100644
index 0000000..61b8724
--- /dev/null
+++ b/src/db/migrate/20110302124928_remove_hardware_profile_mapping.rb
@@ -0,0 +1,12 @@
+class RemoveHardwareProfileMapping < ActiveRecord::Migration
+ def self.up
+ drop_table :hardware_profile_map
+ end
+
+ def self.down
+ create_table "hardware_profile_map", :force => true, :id => false do |t|
+ t.column "conductor_hardware_profile_id", :integer
+ t.column "provider_hardware_profile_id", :integer
+ end
+ end
+end
diff --git a/src/features/step_definitions/hardware_profile_steps.rb b/src/features/step_definitions/hardware_profile_steps.rb
index c014cf9..5b9d97a 100644
--- a/src/features/step_definitions/hardware_profile_steps.rb
+++ b/src/features/step_definitions/hardware_profile_steps.rb
@@ -8,9 +8,6 @@ Given /^the Hardare Profile "([^"]*)" has the following Provider Hardware Profil
provider = Factory :mock_provider
front_end_hwp = HardwareProfile.find_by_name(name)
back_end_hwps = table.hashes.collect { |hash| create_hwp(hash, provider) }
-
- front_end_hwp.provider_hardware_profiles = back_end_hwps
- front_end_hwp.save!
end
Given /^there is a "([^"]*)" hardware profile$/ do |arg1|
diff --git a/src/features/support/custom.rb b/src/features/support/custom.rb
index 1bc2c33..a11a133 100644
--- a/src/features/support/custom.rb
+++ b/src/features/support/custom.rb
@@ -7,16 +7,6 @@ Provider.class_eval do
def valid_framework?
true
end
-
- def populate_hardware_profiles
- [[:mock_hwp1, :agg_hwp1], [:mock_hwp2, :agg_hwp2]].each do |mp_name, ap_name|
- mock = Factory(mp_name, :provider_id => self.id)
- agg_mock = Factory(ap_name, :external_key => self.name + Realm::CONDUCTOR_REALM_ACCOUNT_DELIMITER + mock.name)
- agg_mock.provider_hardware_profiles << mock
- end
- return true
- end
-
end
ProviderAccount.class_eval do
diff --git a/src/spec/models/hardware_profile_spec.rb b/src/spec/models/hardware_profile_spec.rb
index 6ca8ca6..6a92b9c 100644
--- a/src/spec/models/hardware_profile_spec.rb
+++ b/src/spec/models/hardware_profile_spec.rb
@@ -56,30 +56,6 @@ describe HardwareProfile do
end
end
- it "should allow Conductor profiles only for provider profiles" do
- @hp.provider = nil
-
- @hp.conductor_hardware_profiles << @hp
- @hp.should have(1).error_on(:conductor_hardware_profiles)
- @hp.errors.on(:conductor_hardware_profiles).should eql(
- "Conductor profiles only allowed for provider profiles")
-
- @hp.conductor_hardware_profiles.clear
- @hp.should be_valid
- end
-
- it "should allow Provider profiles only for conductor profiles" do
- @hp.provider = Provider.new
-
- @hp.conductor_hardware_profiles << @hp
- @hp.should have(1).error_on(:provider_hardware_profiles)
- @hp.errors.on(:provider_hardware_profiles).should eql(
- "Provider profiles only allowed for conductor profiles")
-
- @hp.provider_hardware_profiles.clear
- @hp.should be_valid
- end
-
it "should have 'kind' attribute of hardware profile property set to string (not symbol)" do
api_prop = mock('DeltaCloud::HWP::FloatProperty', :unit => 'MB', :name => 'memory', :kind => :fixed, :value => 12288.0)
@hp.memory =(a)hp.new_property(api_prop)
--
1.7.4
12 years, 9 months
[PATCH configure 1/1] Make httpd start on reboot.
by Mike Orazi
---
recipes/apache/manifests/init.pp | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/recipes/apache/manifests/init.pp b/recipes/apache/manifests/init.pp
index fa8fe53..0df1301 100644
--- a/recipes/apache/manifests/init.pp
+++ b/recipes/apache/manifests/init.pp
@@ -13,7 +13,8 @@ class apache {
ensure => running,
require => Package["httpd"],
hasrestart => true,
- hasstatus => true
+ hasstatus => true,
+ enable => true,
}
exec { "reload-apache":
@@ -32,3 +33,4 @@ define apache::site ( $ensure = 'present', $source = '') {
require => Service['httpd']
}
}
+
--
1.7.4
12 years, 9 months
warehouse integration (rev. 3)
by Jan Provazník
Updated Icicle model and warehouse_sync - now it downloads only icicles
referenced by a provider_image (instead of all icicles)
12 years, 9 months
[PATCH configure 1/1] Update ordering of iwhd_startup_pause deps.
by Mike Orazi
This should make create_buckets more reliable.
---
recipes/aeolus_recipe/manifests/iwhd.pp | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/recipes/aeolus_recipe/manifests/iwhd.pp b/recipes/aeolus_recipe/manifests/iwhd.pp
index 0baa32b..ad80bcd 100644
--- a/recipes/aeolus_recipe/manifests/iwhd.pp
+++ b/recipes/aeolus_recipe/manifests/iwhd.pp
@@ -40,7 +40,7 @@ class aeolus::iwhd inherits aeolus {
command => "/bin/sleep 2",
unless => '/usr/bin/curl http://localhost:9090',
logoutput => true,
- require => Service['mongod']}
+ require => Service['iwhd']}
}
class aeolus::iwhd::disabled {
--
1.7.4
12 years, 9 months
warehosue integration (rev. 2)
by Jan Provazník
Hi, sending updated version.
Requires patches: delayed_job, provider type, Image Warehouse API library for
conductor.
This revision updates build and push methods to be compatible with current stable
image_builder_service. When user requests image build, Image object skeleton is
created and build method is called on background. This build method is empty for
now (we use older image_builder_service which checks new Image objects).
When image_builder_service updates status of image to 'complete', image pushing
process is triggered: ProviderImage for each available provider is created and
push is called on background (this method is empty), but
image_builder_service updates ProviderImage for us automatically.
12 years, 9 months