-
Notifications
You must be signed in to change notification settings - Fork 125
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
committed the code that was moved from openstack
- also added nova::db
- Loading branch information
Dan Bode
committed
May 26, 2011
1 parent
a441a53
commit 845ba25
Showing
18 changed files
with
312 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
h1. Prerequisites | ||
|
||
The openstack repo should be made available: | ||
see: http://docs.openstack.org/cactus/openstack-compute/admin/content/installing-the-cloud-controller.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
class nova::all( | ||
$xenapi_connection_url, | ||
$xenapi_connection_username, | ||
$xenapi_connection_password, | ||
$sql_connection, | ||
$network_manager, | ||
$image_service, | ||
$verbose = 'undef', | ||
$nodaemon = 'undef', | ||
$flat_network_bridge = 'xenbr0', | ||
$connection_type = 'xenapi', | ||
$xenapi_inject_image = 'false', | ||
$rescue_timeout = '86400', | ||
$allow_admin_api = 'true', | ||
$xenapi_inject_image = 'false', | ||
$use_ipv6 = 'false', | ||
$flat_injected = 'true', | ||
$ipv6_backend = 'account_identifier' | ||
) { | ||
|
||
$novaConfFlags = { | ||
verbose => $verbose, | ||
nodaemon => $nodaemon, | ||
sql_connection => $sql_connetion, | ||
network_manager => $network_manager, | ||
image_service => $image_service, | ||
flat_network_bridge => $flat_network_bridge, | ||
connection_type => $connection_type, | ||
xenapi_connection_url => $xenapi_connection_url, | ||
xenapi_connection_username => $xenapi_connection_username, | ||
xenapi_connection_password => $xenapi_connection_password, | ||
xenapi_inject_image => $xenapi_inject_image, | ||
rescue_timeout => $resuce_timeout, | ||
allow_admin_api => $allow_admin_api, | ||
xenapi_inject_image => $xenapi_inject_image, | ||
use_ipv6 => $use_ipv6, | ||
flat_injected => $flat_injected, | ||
ipv6_backend => $ipv6_backend | ||
} | ||
class { "nova": novaConfHash => $novaConfFlags } | ||
class { "nova::api": isServiceEnabled => false } | ||
class { "nova::compute": isServiceEnabled => false } | ||
class { "nova::network": isServiceEnabled => false } | ||
class { "nova::objectstore": isServiceEnabled => false } | ||
class { "nova::scheduler": isServiceEnabled => false } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
class nova::api($isServiceEnabled=false) inherits nova { | ||
package { "nova-api": | ||
ensure => present, | ||
require => Package["python-greenlet"] | ||
} | ||
service { "nova-api": | ||
ensure => $isServiceEnabled, | ||
require => Package["nova-api"], | ||
subscribe => File["/etc/nova/nova.conf"] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
class nova::compute( $isServiceEnabled=false ) inherits nova { | ||
|
||
package { "nova-compute": | ||
ensure => present, | ||
require => Package["python-greenlet"] | ||
} | ||
|
||
service { "nova-compute": | ||
ensure => $isServiceEnabled, | ||
require => Package["nova-compute"], | ||
subscribe => File["/etc/nova/nova.conf"] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
class nova::db( | ||
$db_pw, | ||
$db_user = 'nova' | ||
$db_name = 'nova', | ||
$db_host => 'localhost' | ||
) { | ||
mysql::db { $db_name: | ||
db_user => $db_user, | ||
db_pw => $db_pw, | ||
db_hostname => $db_hostname, | ||
# I may want to inject some sql | ||
# sql='', | ||
require => Class['mysql::server'] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
class nova::network( $isServiceEnabled=false ) inherits nova { | ||
package { "nova-network": | ||
ensure => present, | ||
require => Package["python-greenlet"] | ||
} | ||
|
||
service { "nova-network": | ||
ensure => $isServiceEnabled, | ||
require => Package["nova-network"], | ||
subscribe => File["/etc/nova/nova.conf"] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
class nova::objectstore( $isServiceEnabled=false ) inherits nova { | ||
package { "nova-objectstore": | ||
ensure => present, | ||
require => Package["python-greenlet"] | ||
} | ||
|
||
service { "nova-objectstore": | ||
ensure => $isServiceEnabled, | ||
require => Package["nova-objectstore"], | ||
subscribe => File["/etc/nova/nova.conf"] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
class nova::scheduler( $isServiceEnabled ) inherits nova { | ||
package { "nova-scheduler": | ||
ensure => present, | ||
require => Package["python-greenlet"] | ||
} | ||
|
||
service { "nova-scheduler": | ||
ensure => $isServiceEnabled, | ||
require => Package["nova-scheduler"], | ||
subscribe => File["/etc/nova/nova.conf"] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<% novaConfHash.each do |key, value| -%> | ||
<% if value != "undef" -%> | ||
--<%= key -%>=<%= value %> | ||
<% else -%> | ||
--<%= key %> | ||
<% end -%> | ||
<% end -%> |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
stage { 'repo-setup': | ||
before => Stage['main'], | ||
} | ||
class { 'apt': | ||
disable_keys => true, | ||
always_apt_update => true, | ||
stage => 'repo-setup', | ||
} | ||
class { 'nova::repo': | ||
stage => 'repo-setup', | ||
} | ||
class { 'nova::all': | ||
verbose => 'undef', | ||
nodaemon => 'undef', | ||
sql_connection => 'mysql://root:<password>@127.0.0.1/nova', | ||
network_manager => 'nova.network.manager.FlatManager', | ||
image_service => 'nova.image.glance.GlanceImageService', | ||
flat_network_bridge => 'xenbr0', | ||
connection_type => 'xenapi', | ||
xenapi_connection_url => 'https://<XenServer IP>', | ||
xenapi_connection_username => 'root', | ||
xenapi_connection_password => 'password', | ||
xenapi_inject_image => 'false', | ||
rescue_timeout => '86400', | ||
allow_admin_api => 'true', | ||
use_ipv6 => 'false', | ||
flat_injected => 'true', | ||
ipv6_backend => 'account_identifier', | ||
} | ||
|
||
# this will probably be on its own machine | ||
class mysql::server { | ||
mysql_root_pw => 'foo', | ||
} | ||
|
||
mysql::db { | ||
db_user, | ||
db_pw, | ||
db_charset = 'utf8', | ||
host = 'localhost', | ||
grant='all', | ||
sql='' | ||
) { | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
class nova-api-test { | ||
$novaConfFlags = { | ||
verbose => 'undef', | ||
nodaemon => 'undef', | ||
sql_connection => 'mysql://root:<password>@127.0.0.1/nova', | ||
network_manager => 'nova.network.manager.FlatManager', | ||
image_service => 'nova.image.glance.GlanceImageService', | ||
flat_network_bridge => 'xenbr0', | ||
connection_type => 'xenapi', | ||
xenapi_connection_url => 'https://<XenServer IP>', | ||
xenapi_connection_username => 'root', | ||
xenapi_connection_password => 'password', | ||
xenapi_inject_image => 'false', | ||
rescue_timeout => '86400', | ||
allow_admin_api => 'true', | ||
xenapi_inject_image => 'false', | ||
use_ipv6 => 'false', | ||
flat_injected => 'true', | ||
ipv6_backend => 'account_identifier', | ||
} | ||
class { "nova": novaConfHash => $novaConfFlags } | ||
class { "nova::api": isServiceEnabled => false } | ||
} | ||
include nova-api-test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#include nova::compute | ||
class nova-compute-test { | ||
$novaConfFlags = { | ||
verbose => 'undef', | ||
nodaemon => 'undef', | ||
sql_connection => 'mysql://root:<password>@127.0.0.1/nova', | ||
network_manager => 'nova.network.manager.FlatManager', | ||
image_service => 'nova.image.glance.GlanceImageService', | ||
flat_network_bridge => 'xenbr0', | ||
connection_type => 'xenapi', | ||
xenapi_connection_url => 'https://<XenServer IP>', | ||
xenapi_connection_username => 'root', | ||
xenapi_connection_password => 'password', | ||
xenapi_inject_image => 'false', | ||
rescue_timeout => '86400', | ||
allow_admin_api => 'true', | ||
xenapi_inject_image => 'false', | ||
use_ipv6 => 'true', | ||
flat_injected => 'true', | ||
ipv6_backend => 'account_identifier', | ||
} | ||
class { "nova": novaConfHash => $novaConfFlags } | ||
class { "nova::compute": isServiceEnabled => false } | ||
} | ||
include nova-compute-test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
class nova-network-test { | ||
$novaConfFlags = { | ||
verbose => 'undef', | ||
nodaemon => 'undef', | ||
sql_connection => 'mysql://root:<password>@127.0.0.1/nova', | ||
network_manager => 'nova.network.manager.FlatManager', | ||
image_service => 'nova.image.glance.GlanceImageService', | ||
flat_network_bridge => 'xenbr0', | ||
connection_type => 'xenapi', | ||
xenapi_connection_url => 'https://<XenServer IP>', | ||
xenapi_connection_username => 'root', | ||
xenapi_connection_password => 'password', | ||
xenapi_inject_image => 'false', | ||
rescue_timeout => '86400', | ||
allow_admin_api => 'true', | ||
xenapi_inject_image => 'false', | ||
use_ipv6 => 'true', | ||
flat_injected => 'true', | ||
ipv6_backend => 'account_identifier', | ||
} | ||
class { "nova": novaConfHash => $novaConfFlags } | ||
class { "nova::network": isServiceEnabled => false } | ||
} | ||
include nova-network-test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
class nova-objectstore-test { | ||
$novaConfFlags = { | ||
verbose => 'undef', | ||
nodaemon => 'undef', | ||
sql_connection => 'mysql://root:<password>@127.0.0.1/nova', | ||
network_manager => 'nova.network.manager.FlatManager', | ||
image_service => 'nova.image.glance.GlanceImageService', | ||
flat_network_bridge => 'xenbr0', | ||
connection_type => 'xenapi', | ||
xenapi_connection_url => 'https://<XenServer IP>', | ||
xenapi_connection_username => 'root', | ||
xenapi_connection_password => 'password', | ||
xenapi_inject_image => 'false', | ||
rescue_timeout => '86400', | ||
allow_admin_api => 'true', | ||
xenapi_inject_image => 'false', | ||
use_ipv6 => 'true', | ||
flat_injected => 'true', | ||
ipv6_backend => 'account_identifier', | ||
} | ||
class { "nova": novaConfHash => $novaConfFlags } | ||
class { "nova::objectstore": isServiceEnabled => false } | ||
} | ||
include nova-objectstore-test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
class nova-scheduler-test { | ||
$novaConfFlags = { | ||
verbose => 'undef', | ||
nodaemon => 'undef', | ||
sql_connection => 'mysql://root:<password>@127.0.0.1/nova', | ||
network_manager => 'nova.network.manager.FlatManager', | ||
image_service => 'nova.image.glance.GlanceImageService', | ||
flat_network_bridge => 'xenbr0', | ||
connection_type => 'xenapi', | ||
xenapi_connection_url => 'https://<XenServer IP>', | ||
xenapi_connection_username => 'root', | ||
xenapi_connection_password => 'password', | ||
xenapi_inject_image => 'false', | ||
rescue_timeout => '86400', | ||
allow_admin_api => 'true', | ||
xenapi_inject_image => 'false', | ||
use_ipv6 => 'true', | ||
flat_injected => 'true', | ||
ipv6_backend => 'account_identifier', | ||
} | ||
class { "nova": novaConfHash => $novaConfFlags } | ||
class { "nova::scheduler": isServiceEnabled => false } | ||
} | ||
include nova-scheduler-test |