RHEL/Fedora replicator updates.

The latest RHEL and Fedora Swift packages now include replicator
init scripts.

This updates the swift module to make use of them.

Change-Id: I6d33aa87ebfda390903762e5a3ab45708db27a5e
This commit is contained in:
Dan Prince
2013-04-05 14:48:03 -04:00
parent 2510adebc4
commit 77c17c7d3f
2 changed files with 10 additions and 21 deletions

View File

@@ -28,13 +28,13 @@ class swift::params {
$proxy_service_name = 'openstack-swift-proxy'
$object_package_name = 'openstack-swift-object'
$object_service_name = 'openstack-swift-object'
$object_replicator_service_name = undef
$object_replicator_service_name = 'openstack-swift-object-replicator'
$container_package_name = 'openstack-swift-container'
$container_service_name = 'openstack-swift-container'
$container_replicator_service_name = undef
$container_replicator_service_name = 'openstack-swift-container-replicator'
$account_package_name = 'openstack-swift-account'
$account_service_name = 'openstack-swift-account'
$account_replicator_service_name = undef
$account_replicator_service_name = 'openstack-swift-account-replicator'
$service_provider = undef
$swift3 = 'openstack-swift-plugin-swift3'
}

View File

@@ -51,24 +51,13 @@ define swift::storage::generic(
subscribe => Package["swift-${name}"],
}
if $::osfamily == "RedHat" {
service { "swift-${name}-replicator":
start => "/usr/bin/swift-init ${name}-replicator start",
ensure => running,
enable => true,
hasstatus => true,
provider => base,
subscribe => Package["swift-${name}"],
}
}else{
service { "swift-${name}-replicator":
name => inline_template("<%= scope.lookupvar('::swift::params::${name}_replicator_service_name') %>"),
ensure => running,
enable => true,
hasstatus => true,
provider => $service_provider,
subscribe => Package["swift-${name}"],
}
service { "swift-${name}-replicator":
name => inline_template("<%= scope.lookupvar('::swift::params::${name}_replicator_service_name') %>"),
ensure => running,
enable => true,
hasstatus => true,
provider => $service_provider,
subscribe => Package["swift-${name}"],
}
}