v3 - rebased v2 - removed nil cpu from hwp1, was not compatible with rhev
Their profiles are activated by running "aeolus-configure -p ec2" and "aeolus-configure -p mock".
Ensure all provider profiles create a default bucket.
Remove whitespaces. --- conf/ec2 | 13 ++++++ conf/mock | 12 ++++++ recipes/aeolus/manifests/profiles/default.pp | 41 +------------------- recipes/aeolus/manifests/profiles/ec2.pp | 52 ++++++++++++++++++++++++++ recipes/aeolus/manifests/profiles/mock.pp | 51 +++++++++++++++++++++++++ recipes/aeolus/manifests/profiles/rhevm.pp | 4 +- recipes/aeolus/manifests/profiles/vsphere.pp | 4 +- 7 files changed, 135 insertions(+), 42 deletions(-) create mode 100644 conf/ec2 create mode 100644 conf/mock create mode 100644 recipes/aeolus/manifests/profiles/ec2.pp create mode 100644 recipes/aeolus/manifests/profiles/mock.pp
diff --git a/conf/ec2 b/conf/ec2 new file mode 100644 index 0000000..142887f --- /dev/null +++ b/conf/ec2 @@ -0,0 +1,13 @@ +# ec2 setup configuration. +--- +parameters: + enable_https: true + enable_security: false + package_provider: rpm +classes: +- aeolus::conductor +- aeolus::image-factory +- aeolus::iwhd +- aeolus::deltacloud::core +- aeolus::deltacloud::ec2 +- aeolus::profiles::ec2 diff --git a/conf/mock b/conf/mock new file mode 100644 index 0000000..087c329 --- /dev/null +++ b/conf/mock @@ -0,0 +1,12 @@ +# mock setup configuration. +--- +parameters: + enable_https: true + enable_security: false + package_provider: rpm +classes: +- aeolus::conductor +- aeolus::image-factory +- aeolus::iwhd +- aeolus::deltacloud::core +- aeolus::profiles::mock diff --git a/recipes/aeolus/manifests/profiles/default.pp b/recipes/aeolus/manifests/profiles/default.pp index 8bbfb7f..c3a58cd 100644 --- a/recipes/aeolus/manifests/profiles/default.pp +++ b/recipes/aeolus/manifests/profiles/default.pp @@ -13,7 +13,6 @@ # limitations under the License.
class aeolus::profiles::default { - include aeolus::deltacloud::ec2
aeolus::create_bucket{"aeolus":}
@@ -25,31 +24,7 @@ class aeolus::profiles::default {
aeolus::conductor::login{"admin": password => "password", require => Aeolus::Conductor::Site_admin['admin']} - - aeolus::conductor::provider{"mock": - deltacloud_driver => 'mock', - url => 'http://localhost:3002/api', - require => Aeolus::Conductor::Login["admin"] } - - aeolus::conductor::provider::account{"mockuser": - provider => 'mock', - type => 'mock', - username => 'mockuser', - password => 'mockpassword', - require => Aeolus::Conductor::Provider["mock"] } - - aeolus::conductor::provider{"ec2-us-east-1": - deltacloud_driver => 'ec2', - deltacloud_provider => 'us-east-1', - url => 'http://localhost:3002/api', - require => Aeolus::Conductor::Login["admin"] } - - aeolus::conductor::provider{"ec2-us-west-1": - deltacloud_driver => 'ec2', - deltacloud_provider => 'us-west-1', - url => 'http://localhost:3002/api', - require => Aeolus::Conductor::Login["admin"] } - + aeolus::conductor::hwp{"hwp1": memory => "512", cpu => "1", @@ -57,17 +32,7 @@ class aeolus::profiles::default { architecture => "x86_64", require => Aeolus::Conductor::Login["admin"] }
- aeolus::conductor::hwp{"hwp2": - memory => "1", - cpu => "", - storage => "1", - architecture => "x86_64", - require => Aeolus::Conductor::Login["admin"] } - aeolus::conductor::logout{"admin": - require => [Aeolus::Conductor::Provider['mock'], - Aeolus::Conductor::Provider::Account['mockuser'], - Aeolus::Conductor::Provider['ec2-us-east-1'], - Aeolus::Conductor::Provider['ec2-us-west-1'], - Aeolus::Conductor::Hwp['hwp1', 'hwp2']] } + require => Aeolus::Conductor::Hwp['hwp1']} + } diff --git a/recipes/aeolus/manifests/profiles/ec2.pp b/recipes/aeolus/manifests/profiles/ec2.pp new file mode 100644 index 0000000..3dd96e0 --- /dev/null +++ b/recipes/aeolus/manifests/profiles/ec2.pp @@ -0,0 +1,52 @@ +# Copyright 2011 Red Hat, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +class aeolus::profiles::ec2 { + include aeolus::deltacloud::ec2 + + aeolus::create_bucket{"aeolus":} + + aeolus::conductor::site_admin{"admin": + email => 'dcuser@aeolusproject.org', + password => "password", + first_name => 'aeolus', + last_name => 'user'} + + aeolus::conductor::login{"admin": password => "password", + require => Aeolus::Conductor::Site_admin['admin']} + + aeolus::conductor::provider{"ec2-us-east-1": + deltacloud_driver => 'ec2', + deltacloud_provider => 'us-east-1', + url => 'http://localhost:3002/api', + require => Aeolus::Conductor::Login["admin"] } + + aeolus::conductor::provider{"ec2-us-west-1": + deltacloud_driver => 'ec2', + deltacloud_provider => 'us-west-1', + url => 'http://localhost:3002/api', + require => Aeolus::Conductor::Login["admin"] } + + aeolus::conductor::hwp{"hwp1": + memory => "512", + cpu => "1", + storage => "", + architecture => "x86_64", + require => Aeolus::Conductor::Login["admin"] } + + aeolus::conductor::logout{"admin": + require => [Aeolus::Conductor::Provider['ec2-us-east-1'], + Aeolus::Conductor::Provider['ec2-us-west-1'], + Aeolus::Conductor::Hwp['hwp1']] } +} diff --git a/recipes/aeolus/manifests/profiles/mock.pp b/recipes/aeolus/manifests/profiles/mock.pp new file mode 100644 index 0000000..1656815 --- /dev/null +++ b/recipes/aeolus/manifests/profiles/mock.pp @@ -0,0 +1,51 @@ +# Copyright 2011 Red Hat, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +class aeolus::profiles::mock { + + aeolus::create_bucket{"aeolus":} + + aeolus::conductor::site_admin{"admin": + email => 'dcuser@aeolusproject.org', + password => "password", + first_name => 'aeolus', + last_name => 'user'} + + aeolus::conductor::login{"admin": password => "password", + require => Aeolus::Conductor::Site_admin['admin']} + + aeolus::conductor::provider{"mock": + deltacloud_driver => 'mock', + url => 'http://localhost:3002/api', + require => Aeolus::Conductor::Login["admin"] } + + aeolus::conductor::provider::account{"mockuser": + provider => 'mock', + type => 'mock', + username => 'mockuser', + password => 'mockpassword', + require => Aeolus::Conductor::Provider["mock"] } + + aeolus::conductor::hwp{"hwp1": + memory => "512", + cpu => "1", + storage => "", + architecture => "x86_64", + require => Aeolus::Conductor::Login["admin"] } + + aeolus::conductor::logout{"admin": + require => [Aeolus::Conductor::Provider['mock'], + Aeolus::Conductor::Provider::Account['mockuser'], + Aeolus::Conductor::Hwp['hwp1']] } +} diff --git a/recipes/aeolus/manifests/profiles/rhevm.pp b/recipes/aeolus/manifests/profiles/rhevm.pp index 03fef5b..93d8bad 100644 --- a/recipes/aeolus/manifests/profiles/rhevm.pp +++ b/recipes/aeolus/manifests/profiles/rhevm.pp @@ -57,14 +57,14 @@ class aeolus::profiles::rhevm { url => "http://localhost:3002/api", deltacloud_provider => "$rhevm_deltacloud_provider", require => Aeolus::Conductor::Login["admin"] } - + aeolus::conductor::provider::account{"rhevm": provider => 'rhevm', type => 'rhevm', username => '$rhevm_deltacloud_username', password => '$rhevm_deltacloud_password', require => Aeolus::Conductor::Provider["rhevm"] } - + aeolus::conductor::hwp{"hwp1": memory => "512", cpu => "1", diff --git a/recipes/aeolus/manifests/profiles/vsphere.pp b/recipes/aeolus/manifests/profiles/vsphere.pp index 72a3e59..1715181 100644 --- a/recipes/aeolus/manifests/profiles/vsphere.pp +++ b/recipes/aeolus/manifests/profiles/vsphere.pp @@ -34,14 +34,14 @@ class aeolus::profiles::vsphere { url => "http://localhost:3002/api", deltacloud_provider => "$vsphere_deltacloud_provider", require => [Aeolus::Conductor::Login["admin"]] } - + aeolus::conductor::provider::account{"vsphere": provider => 'vsphere', type => 'vsphere', username => '$vsphere_username', password => '$vsphere_password', require => Aeolus::Conductor::Provider["vsphere"] } - + aeolus::conductor::hwp{"hwp1": memory => "512", cpu => "1",
aeolus-devel@lists.fedorahosted.org