Prepare for voxpupuli-puppet-lint-plugins
Fix new lint errors detected when full of the voxpupili lint plugins are enabled. Change-Id: Ifb5b50d7ae23c3e69a70721598e2719dbafa14d5 Signed-off-by: Takashi Kajinami <kajinamit@oss.nttdata.com>
This commit is contained in:

committed by
Tobias Urdin

parent
fe82252e68
commit
73d0dbfb0a
@@ -10,7 +10,6 @@ Exec { logoutput => true }
|
||||
|
||||
package { 'curl': ensure => present }
|
||||
|
||||
|
||||
class { 'memcached':
|
||||
listen_ip => $swift_local_net_ip,
|
||||
}
|
||||
@@ -41,7 +40,7 @@ swift::storage::node { '2':
|
||||
manage_ring => true,
|
||||
zone => '2',
|
||||
storage_local_net_ip => $swift_local_net_ip,
|
||||
require => Swift::Storage::Loopback[2] ,
|
||||
require => Swift::Storage::Loopback[2],
|
||||
}
|
||||
|
||||
class { 'swift::ringbuilder':
|
||||
@@ -51,7 +50,6 @@ class { 'swift::ringbuilder':
|
||||
require => Class['swift'],
|
||||
}
|
||||
|
||||
|
||||
# TODO should I enable swath in the default config?
|
||||
class { 'swift::proxy':
|
||||
proxy_local_net_ip => $swift_local_net_ip,
|
||||
@@ -59,7 +57,8 @@ class { 'swift::proxy':
|
||||
account_autocreate => true,
|
||||
require => Class['swift::ringbuilder'],
|
||||
}
|
||||
class { ['swift::proxy::healthcheck', 'swift::proxy::cache']: }
|
||||
|
||||
class {['swift::proxy::healthcheck', 'swift::proxy::cache']: }
|
||||
|
||||
class { 'swift::proxy::tempauth':
|
||||
account_user_list => [
|
||||
@@ -67,7 +66,7 @@ class { 'swift::proxy::tempauth':
|
||||
'user' => 'admin',
|
||||
'account' => 'admin',
|
||||
'key' => 'admin',
|
||||
'groups' => [ 'admin', 'reseller_admin' ],
|
||||
'groups' => ['admin', 'reseller_admin'],
|
||||
},
|
||||
{
|
||||
'user' => 'tester',
|
||||
|
@@ -21,7 +21,6 @@
|
||||
# this site manifest serves as an example of how to
|
||||
# deploy various swift environments
|
||||
|
||||
|
||||
#$swift_admin_password = 'admin_password'
|
||||
$swift_admin_password = hiera('admin_password', 'admin_password')
|
||||
|
||||
@@ -29,7 +28,6 @@ $swift_admin_password = hiera('admin_password', 'admin_password')
|
||||
#$swift_shared_secret = 'changeme'
|
||||
$swift_shared_secret = hiera('swift_shared_secret', 'changeme')
|
||||
|
||||
|
||||
#$swift_local_net_ip = $ipaddress_eth0
|
||||
$swift_local_net_ip = hiera('swift_local_net_ip', $ipaddress_eth0)
|
||||
|
||||
@@ -67,7 +65,6 @@ $swift_keystone_admin_password = hiera('admin_password', 'ChangeMe')
|
||||
# This service only contains the credentials for authenticating
|
||||
# swift
|
||||
node 'swift-keystone' {
|
||||
|
||||
# set up mysql server
|
||||
class { 'mysql::server':
|
||||
config_hash => {
|
||||
@@ -108,7 +105,6 @@ node 'swift-keystone' {
|
||||
password => $swift_admin_password,
|
||||
public_address => $swift_proxy_node,
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#
|
||||
@@ -120,7 +116,6 @@ node 'swift-keystone' {
|
||||
# partitions
|
||||
#
|
||||
node /swift-storage/ {
|
||||
|
||||
class { 'swift':
|
||||
# not sure how I want to deal with this shared secret
|
||||
swift_hash_path_suffix => $swift_shared_secret,
|
||||
@@ -179,12 +174,9 @@ node /swift-storage/ {
|
||||
|
||||
# collect resources for synchronizing the ring databases
|
||||
Swift::Ringsync<<||>>
|
||||
|
||||
}
|
||||
|
||||
|
||||
node /swift-proxy/ {
|
||||
|
||||
class { 'swift':
|
||||
# not sure how I want to deal with this shared secret
|
||||
swift_hash_path_suffix => $swift_shared_secret,
|
||||
@@ -220,7 +212,7 @@ node /swift-proxy/ {
|
||||
}
|
||||
|
||||
# configure all of the middlewares
|
||||
class { [
|
||||
class {[
|
||||
'swift::proxy::account_quotas',
|
||||
'swift::proxy::catch_errors',
|
||||
'swift::proxy::container_quotas',
|
||||
|
@@ -24,7 +24,6 @@ class swift::auth_file (
|
||||
$admin_user = 'admin',
|
||||
$auth_url = 'http://127.0.0.1:5000/v3/'
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
file { '/root/swiftrc':
|
||||
@@ -33,11 +32,9 @@ class swift::auth_file (
|
||||
group => 'root',
|
||||
mode => '0600',
|
||||
tag => 'swift-file',
|
||||
content =>
|
||||
"
|
||||
export ST_USER=${admin_tenant}:${admin_user}
|
||||
export ST_KEY=${admin_password}
|
||||
export ST_AUTH=${auth_url}
|
||||
",
|
||||
content => "
|
||||
export ST_USER=${admin_tenant}:${admin_user}
|
||||
export ST_KEY=${admin_password}
|
||||
export ST_AUTH=${auth_url}",
|
||||
}
|
||||
}
|
||||
|
@@ -82,8 +82,7 @@ class swift::bench (
|
||||
$num_gets = '10000',
|
||||
$num_containers = '20',
|
||||
$delete = 'yes',
|
||||
){
|
||||
|
||||
) {
|
||||
include swift::deps
|
||||
|
||||
swift_bench_config {
|
||||
|
@@ -11,7 +11,6 @@
|
||||
class swift::client (
|
||||
$ensure = 'present',
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
@@ -20,5 +19,4 @@ class swift::client (
|
||||
name => $swift::params::client_package,
|
||||
tag => 'openstack',
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -54,7 +54,6 @@ class swift::config (
|
||||
Hash $swift_object_config = {},
|
||||
Hash $swift_internal_client_config = {},
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
create_resources('swift_config', $swift_config)
|
||||
|
@@ -82,7 +82,7 @@
|
||||
# (Optional) Prefix used for hiddne auto-created accounts.
|
||||
# Defaults to $facts['os_service_default']
|
||||
#
|
||||
class swift::constraints(
|
||||
class swift::constraints (
|
||||
$max_file_size = $facts['os_service_default'],
|
||||
$max_meta_name_length = $facts['os_service_default'],
|
||||
$max_meta_value_length = $facts['os_service_default'],
|
||||
@@ -98,7 +98,6 @@ class swift::constraints(
|
||||
$valid_api_versions = $facts['os_service_default'],
|
||||
$auto_create_account_prefix = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
|
@@ -112,7 +112,7 @@
|
||||
# in the proxy config.
|
||||
# Defaults to false.
|
||||
#
|
||||
class swift::containerreconciler(
|
||||
class swift::containerreconciler (
|
||||
Boolean $manage_service = true,
|
||||
Boolean $enabled = true,
|
||||
$package_ensure = 'present',
|
||||
@@ -136,7 +136,6 @@ class swift::containerreconciler(
|
||||
$log_max_line_length = $facts['os_service_default'],
|
||||
Boolean $purge_config = false,
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
Swift_container_reconciler_config<||> ~> Service['swift-container-reconciler']
|
||||
|
||||
@@ -160,7 +159,6 @@ class swift::containerreconciler(
|
||||
|
||||
# only add memcache servers if 'cache' is included in the pipeline
|
||||
if !empty(grep(any2array($pipeline), 'cache')) {
|
||||
|
||||
swift_container_reconciler_config {
|
||||
'filter:cache/memcache_servers': value => join(any2array($memcache_servers), ',');
|
||||
'filter:cache/tls_enabled': value => $cache_tls_enabled;
|
||||
@@ -220,5 +218,4 @@ class swift::containerreconciler(
|
||||
config_file_name => 'container-reconciler.conf',
|
||||
service_provider => $service_provider,
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -71,5 +71,4 @@ class swift::deps {
|
||||
# Installation or config changes will always restart services.
|
||||
Anchor['swift::install::end'] ~> Anchor['swift::service::begin']
|
||||
Anchor['swift::config::end'] ~> Anchor['swift::service::begin']
|
||||
|
||||
}
|
||||
|
@@ -79,7 +79,6 @@ class swift::dispersion (
|
||||
$concurrency = 25,
|
||||
$dump_json = 'no'
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
@@ -115,5 +114,4 @@ class swift::dispersion (
|
||||
# lint:endignore
|
||||
require => Package['swiftclient'],
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -44,13 +44,12 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
class swift(
|
||||
class swift (
|
||||
$swift_hash_path_suffix = $facts['os_service_default'],
|
||||
$swift_hash_path_prefix = $facts['os_service_default'],
|
||||
$package_ensure = 'present',
|
||||
Boolean $purge_config = false,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
include swift::client
|
||||
|
@@ -85,7 +85,6 @@ class swift::internal_client (
|
||||
$recoverable_node_timeout = $facts['os_service_default'],
|
||||
Boolean $purge_config = false,
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
|
@@ -47,7 +47,7 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
class swift::internal_client::cache(
|
||||
class swift::internal_client::cache (
|
||||
$memcache_servers = ['127.0.0.1:11211'],
|
||||
$tls_enabled = $facts['os_service_default'],
|
||||
$tls_cafile = $facts['os_service_default'],
|
||||
@@ -55,7 +55,6 @@ class swift::internal_client::cache(
|
||||
$tls_keyfile = $facts['os_service_default'],
|
||||
$memcache_max_connections = '2'
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
# require the memcached class if its on the same machine
|
||||
@@ -72,5 +71,4 @@ class swift::internal_client::cache(
|
||||
'filter:cache/tls_keyfile': value => $tls_keyfile;
|
||||
'filter:cache/memcache_max_connections': value => $memcache_max_connections;
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -15,8 +15,7 @@
|
||||
#
|
||||
# Copyright 2012 eNovance licensing@enovance.com
|
||||
#
|
||||
class swift::internal_client::catch_errors() {
|
||||
|
||||
class swift::internal_client::catch_errors {
|
||||
include swift::deps
|
||||
|
||||
swift_internal_client_config {
|
||||
|
@@ -6,7 +6,6 @@
|
||||
# Joe Topjian joe@topjian.net
|
||||
#
|
||||
class swift::internal_client::proxy_logging {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_internal_client_config {
|
||||
|
@@ -29,10 +29,9 @@
|
||||
#
|
||||
# shi.yan@ardc.edu.au
|
||||
#
|
||||
class swift::internal_client::symlink(
|
||||
class swift::internal_client::symlink (
|
||||
$symloop_max = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_internal_client_config {
|
||||
|
@@ -75,7 +75,7 @@
|
||||
#
|
||||
# Thiago da Silva thiago@redhat.com
|
||||
#
|
||||
class swift::keymaster(
|
||||
class swift::keymaster (
|
||||
String[1] $password,
|
||||
$api_class = 'barbican',
|
||||
$key_id = $facts['os_service_default'],
|
||||
@@ -90,7 +90,6 @@ class swift::keymaster(
|
||||
$user_domain_id = 'default',
|
||||
$meta_version_to_write = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
@@ -120,4 +119,3 @@ class swift::keymaster(
|
||||
'kms_keymaster/meta_version_to_write': value => $meta_version_to_write;
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -107,13 +107,13 @@
|
||||
# (optional) The endpoint's internal url. (Defaults to 'http://127.0.0.1:8080')
|
||||
# This url should *not* contain any trailing '/'.
|
||||
#
|
||||
class swift::keystone::auth(
|
||||
class swift::keystone::auth (
|
||||
String[1] $password,
|
||||
String[1] $auth_name = 'swift',
|
||||
String[1] $tenant = 'services',
|
||||
Array[String[1]] $roles = ['admin'],
|
||||
String[1] $system_scope = 'all',
|
||||
Array[String[1]]$system_roles = [],
|
||||
Array[String[1]] $system_roles = [],
|
||||
String[1] $email = 'swift@localhost',
|
||||
String[1] $region = 'RegionOne',
|
||||
Array[String[1]] $operator_roles = ['admin', 'SwiftOperator'],
|
||||
@@ -134,7 +134,6 @@ class swift::keystone::auth(
|
||||
Keystone::EndpointUrl $admin_url_s3 = 'http://127.0.0.1:8080',
|
||||
Keystone::EndpointUrl $internal_url_s3 = 'http://127.0.0.1:8080',
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
if $service_name == $service_name_s3 {
|
||||
|
@@ -29,13 +29,12 @@
|
||||
#
|
||||
# Francois Charlier fcharlier@ploup.net
|
||||
#
|
||||
class swift::keystone::dispersion(
|
||||
class swift::keystone::dispersion (
|
||||
$auth_user = 'dispersion',
|
||||
$auth_pass = 'dispersion_password',
|
||||
$email = 'swift@localhost',
|
||||
$tenant = 'services'
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
keystone_user { $auth_user:
|
||||
@@ -51,5 +50,4 @@ class swift::keystone::dispersion(
|
||||
|
||||
Keystone_user<| title == $auth_user |>
|
||||
~> Keystone_user_role<| title == "${auth_user}@${tenant}" |>
|
||||
|
||||
}
|
||||
|
@@ -76,7 +76,6 @@ class swift::memcache (
|
||||
$io_timeout = $facts['os_service_default'],
|
||||
Boolean $purge_config = false,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
|
@@ -129,7 +129,7 @@
|
||||
# (optional) Account name used for expiring objects.
|
||||
# Defaults to undef.
|
||||
#
|
||||
class swift::objectexpirer(
|
||||
class swift::objectexpirer (
|
||||
Boolean $manage_service = true,
|
||||
Boolean $enabled = true,
|
||||
$package_ensure = 'present',
|
||||
@@ -158,7 +158,6 @@ class swift::objectexpirer(
|
||||
# DEPRECATED PARAMETERS
|
||||
$expiring_objects_account_name = undef,
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
Swift_object_expirer_config<||> ~> Service['swift-object-expirer']
|
||||
|
||||
@@ -196,7 +195,6 @@ class swift::objectexpirer(
|
||||
|
||||
# only add memcache servers if 'cache' is included in the pipeline
|
||||
if !empty(grep(any2array($pipeline), 'cache')) {
|
||||
|
||||
swift_object_expirer_config {
|
||||
'filter:cache/memcache_servers': value => join(any2array($memcache_servers), ',');
|
||||
'filter:cache/tls_enabled': value => $cache_tls_enabled;
|
||||
|
@@ -72,6 +72,7 @@ class swift::params {
|
||||
fail("Unsupported osfamily: ${facts['os']['family']}")
|
||||
}
|
||||
}
|
||||
|
||||
$swift_init_service_names = [
|
||||
'swift-proxy-server',
|
||||
'swift-object-auditor',
|
||||
|
@@ -206,7 +206,7 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
class swift::proxy(
|
||||
class swift::proxy (
|
||||
$proxy_local_net_ip,
|
||||
$port = '8080',
|
||||
$cert_file = $facts['os_service_default'],
|
||||
@@ -253,12 +253,11 @@ class swift::proxy(
|
||||
Swift::ServiceProvider $service_provider = $swift::params::service_provider,
|
||||
Boolean $purge_config = false,
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
|
||||
if(member($pipeline, 'tempauth')) {
|
||||
if member($pipeline, 'tempauth') {
|
||||
$auth_type = 'tempauth'
|
||||
} elsif(member($pipeline, 'keystone')) {
|
||||
} elsif member($pipeline, 'keystone') {
|
||||
$auth_type = 'keystone'
|
||||
} else {
|
||||
warning('no auth type provided in the pipeline')
|
||||
@@ -269,7 +268,7 @@ class swift::proxy(
|
||||
fail('proxy-server must be the last element in pipeline')
|
||||
}
|
||||
|
||||
if($auth_type == 'tempauth' and ! $account_autocreate ){
|
||||
if $auth_type == 'tempauth' and !$account_autocreate {
|
||||
fail('account_autocreate must be set to true when auth_type is tempauth')
|
||||
}
|
||||
|
||||
|
@@ -17,8 +17,7 @@
|
||||
#
|
||||
# Configure Swift Account Quotas
|
||||
#
|
||||
class swift::proxy::account_quotas() {
|
||||
|
||||
class swift::proxy::account_quotas {
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -21,7 +21,6 @@ class swift::proxy::audit (
|
||||
$filter_factory = 'keystonemiddleware.audit:filter_factory',
|
||||
$audit_map_file = '/etc/pycadf/swift_api_audit_map.conf',
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -92,7 +92,7 @@
|
||||
#
|
||||
# Copyright 2012 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
class swift::proxy::authtoken(
|
||||
class swift::proxy::authtoken (
|
||||
String[1] $password,
|
||||
$delay_auth_decision = 1,
|
||||
$cache = 'swift.cache',
|
||||
@@ -111,7 +111,6 @@ class swift::proxy::authtoken(
|
||||
$service_type = $facts['os_service_default'],
|
||||
$interface = $facts['os_service_default'],
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
|
||||
if is_service_default($system_scope) {
|
||||
|
@@ -52,7 +52,7 @@
|
||||
# the connection alive while its processing the request.
|
||||
# Defaults to $facts['os_service_default'].
|
||||
#
|
||||
class swift::proxy::bulk(
|
||||
class swift::proxy::bulk (
|
||||
$max_containers_per_extraction = $facts['os_service_default'],
|
||||
$max_failed_extractions = $facts['os_service_default'],
|
||||
$max_failed_deletes = $facts['os_service_default'],
|
||||
@@ -61,7 +61,6 @@ class swift::proxy::bulk(
|
||||
$delete_concurrency = $facts['os_service_default'],
|
||||
$yield_frequency = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -47,7 +47,7 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
class swift::proxy::cache(
|
||||
class swift::proxy::cache (
|
||||
$memcache_servers = ['127.0.0.1:11211'],
|
||||
$tls_enabled = $facts['os_service_default'],
|
||||
$tls_cafile = $facts['os_service_default'],
|
||||
@@ -55,7 +55,6 @@ class swift::proxy::cache(
|
||||
$tls_keyfile = $facts['os_service_default'],
|
||||
$memcache_max_connections = '2'
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
# require the memcached class if its on the same machine
|
||||
@@ -72,5 +71,4 @@ class swift::proxy::cache(
|
||||
'filter:cache/tls_keyfile': value => $tls_keyfile;
|
||||
'filter:cache/memcache_max_connections': value => $memcache_max_connections;
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -15,8 +15,7 @@
|
||||
#
|
||||
# Copyright 2012 eNovance licensing@enovance.com
|
||||
#
|
||||
class swift::proxy::catch_errors() {
|
||||
|
||||
class swift::proxy::catch_errors {
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -183,7 +183,7 @@
|
||||
#
|
||||
# Copyright 2013 eNovance licensing@enovance.com
|
||||
#
|
||||
class swift::proxy::ceilometer(
|
||||
class swift::proxy::ceilometer (
|
||||
String[1] $password,
|
||||
String[1] $default_transport_url,
|
||||
$driver = $facts['os_service_default'],
|
||||
@@ -221,7 +221,6 @@ class swift::proxy::ceilometer(
|
||||
# DEPRECATED PARAMETERS
|
||||
$rabbit_heartbeat_in_pthread = undef,
|
||||
) inherits swift {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
@@ -297,5 +296,4 @@ class swift::proxy::ceilometer(
|
||||
name => $swift::params::ceilometermiddleware_package_name,
|
||||
tag => ['openstack', 'swift-support-package'],
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -42,7 +42,7 @@
|
||||
# Default to $facts['os_service_default']
|
||||
#
|
||||
#
|
||||
class swift::proxy::cname_lookup(
|
||||
class swift::proxy::cname_lookup (
|
||||
$log_name = $facts['os_service_default'],
|
||||
$log_facility = $facts['os_service_default'],
|
||||
$log_level = $facts['os_service_default'],
|
||||
@@ -52,7 +52,6 @@ class swift::proxy::cname_lookup(
|
||||
$lookup_depth = $facts['os_service_default'],
|
||||
$nameservers = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
|
@@ -17,8 +17,7 @@
|
||||
#
|
||||
# Configure Swift Container Quotas
|
||||
#
|
||||
class swift::proxy::container_quotas() {
|
||||
|
||||
class swift::proxy::container_quotas {
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -17,11 +17,10 @@
|
||||
#
|
||||
# Denis Egorenko <degorenko@mirantis.com>
|
||||
#
|
||||
class swift::proxy::container_sync(
|
||||
class swift::proxy::container_sync (
|
||||
$allow_full_urls = $facts['os_service_default'],
|
||||
$current = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -18,7 +18,6 @@
|
||||
class swift::proxy::copy (
|
||||
$object_post_as_copy = true
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -14,7 +14,6 @@
|
||||
class swift::proxy::crossdomain (
|
||||
$cross_domain_policy = '<allow-access-from domain="*" secure="false" />',
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -34,7 +34,6 @@ class swift::proxy::dlo (
|
||||
$rate_limit_segments_per_sec = $facts['os_service_default'],
|
||||
$max_get_time = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -67,7 +67,7 @@
|
||||
# shi.yan@ardc.edu.au
|
||||
#
|
||||
#
|
||||
class swift::proxy::domain_remap(
|
||||
class swift::proxy::domain_remap (
|
||||
$log_name = $facts['os_service_default'],
|
||||
$log_facility = $facts['os_service_default'],
|
||||
$log_level = $facts['os_service_default'],
|
||||
@@ -79,7 +79,6 @@ class swift::proxy::domain_remap(
|
||||
$default_reseller_prefix = $facts['os_service_default'],
|
||||
$mangle_client_paths = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
$reseller_prefixes_real = join(any2array($reseller_prefixes), ',')
|
||||
|
@@ -16,7 +16,6 @@
|
||||
class swift::proxy::encryption (
|
||||
$disable_encryption = false
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
@@ -24,4 +23,3 @@ class swift::proxy::encryption (
|
||||
'filter:encryption/disable_encryption': value => $disable_encryption;
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -24,7 +24,6 @@
|
||||
class swift::proxy::etag_quoter (
|
||||
$enabled_by_default = $facts['os_service_default']
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -21,10 +21,9 @@
|
||||
#
|
||||
# Copyright 2012 eNovance licensing@enovance.com
|
||||
#
|
||||
class swift::proxy::formpost(
|
||||
class swift::proxy::formpost (
|
||||
$allowed_digests = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -45,7 +45,7 @@
|
||||
#
|
||||
# Copyright 2014 UnitedStack licensing@unitedstack.com
|
||||
#
|
||||
class swift::proxy::gatekeeper(
|
||||
class swift::proxy::gatekeeper (
|
||||
$shunt_inbound_x_timestamp = $facts['os_service_default'],
|
||||
$allow_reserved_names_header = $facts['os_service_default'],
|
||||
$log_name = 'gatekeeper',
|
||||
@@ -54,7 +54,6 @@ class swift::proxy::gatekeeper(
|
||||
$log_headers = $facts['os_service_default'],
|
||||
$log_address = '/dev/log'
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -13,8 +13,7 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
class swift::proxy::healthcheck() {
|
||||
|
||||
class swift::proxy::healthcheck {
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -13,12 +13,10 @@
|
||||
class swift::proxy::keymaster (
|
||||
$encryption_root_secret,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
'filter:keymaster/use': value => 'egg:swift#keymaster';
|
||||
'filter:keymaster/encryption_root_secret': value => $encryption_root_secret, secret => true;
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -37,14 +37,13 @@
|
||||
# Dan Bode dan@puppetlabs.com
|
||||
# Francois Charlier fcharlier@ploup.net
|
||||
#
|
||||
class swift::proxy::keystone(
|
||||
class swift::proxy::keystone (
|
||||
$operator_roles = ['admin', 'SwiftOperator'],
|
||||
$reseller_prefix = 'AUTH_',
|
||||
$reseller_admin_role = undef,
|
||||
$project_reader_roles = $facts['os_service_default'],
|
||||
$system_reader_roles = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -13,7 +13,6 @@
|
||||
class swift::proxy::kms_keymaster (
|
||||
$keymaster_config_path = '/etc/swift/keymaster.conf'
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
@@ -21,4 +20,3 @@ class swift::proxy::kms_keymaster (
|
||||
'filter:kms_keymaster/keymaster_config_path': value => $keymaster_config_path;
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -17,7 +17,6 @@
|
||||
#
|
||||
class swift::proxy::listing_formats (
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -6,7 +6,6 @@
|
||||
# Joe Topjian joe@topjian.net
|
||||
#
|
||||
class swift::proxy::proxy_logging {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -47,7 +47,7 @@
|
||||
#
|
||||
# Copyright 2012 eNovance licensing@enovance.com
|
||||
#
|
||||
class swift::proxy::ratelimit(
|
||||
class swift::proxy::ratelimit (
|
||||
$clock_accuracy = $facts['os_service_default'],
|
||||
$max_sleep_time_seconds = $facts['os_service_default'],
|
||||
$log_sleep_time_seconds = $facts['os_service_default'],
|
||||
@@ -56,7 +56,6 @@ class swift::proxy::ratelimit(
|
||||
Hash $container_ratelimit = {},
|
||||
Hash $container_listing_ratelimit = {},
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -12,11 +12,10 @@
|
||||
# (optional) Allow deletes.
|
||||
# Defauls to $facts['os_service_default']
|
||||
#
|
||||
class swift::proxy::read_only(
|
||||
class swift::proxy::read_only (
|
||||
$read_only = $facts['os_service_default'],
|
||||
$allow_deletes = $facts['os_service_default']
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -72,7 +72,7 @@
|
||||
# Override the default log routing for s3api middleware
|
||||
# Defaults to $facts['os_service_default'].
|
||||
#
|
||||
class swift::proxy::s3api(
|
||||
class swift::proxy::s3api (
|
||||
$allow_no_owner = $facts['os_service_default'],
|
||||
$location = $facts['os_service_default'],
|
||||
$dns_compliant_bucket_names = $facts['os_service_default'],
|
||||
@@ -90,7 +90,6 @@ class swift::proxy::s3api(
|
||||
$min_segment_size = $facts['os_service_default'],
|
||||
$log_name = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -81,7 +81,7 @@
|
||||
#
|
||||
# Copyright 2012 eNovance licensing@enovance.com
|
||||
#
|
||||
class swift::proxy::s3token(
|
||||
class swift::proxy::s3token (
|
||||
String[1] $password,
|
||||
$auth_uri = 'http://127.0.0.1:5000',
|
||||
$reseller_prefix = 'AUTH_',
|
||||
@@ -96,7 +96,6 @@ class swift::proxy::s3token(
|
||||
$project_domain_id = 'default',
|
||||
$system_scope = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
if is_service_default($system_scope) {
|
||||
|
@@ -73,7 +73,6 @@ class swift::proxy::slo (
|
||||
$yield_frequency = $facts['os_service_default'],
|
||||
$allow_async_delete = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -22,10 +22,9 @@
|
||||
#
|
||||
# Copyright 2012 eNovance licensing@enovance.com
|
||||
#
|
||||
class swift::proxy::staticweb(
|
||||
class swift::proxy::staticweb (
|
||||
$url_base = $facts['os_service_default']
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -29,10 +29,9 @@
|
||||
#
|
||||
# shi.yan@ardc.edu.au
|
||||
#
|
||||
class swift::proxy::symlink(
|
||||
class swift::proxy::symlink (
|
||||
$symloop_max = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -71,7 +71,7 @@ class swift::proxy::tempauth (
|
||||
'user' => 'admin',
|
||||
'account' => 'admin',
|
||||
'key' => 'admin',
|
||||
'groups' => [ 'admin', 'reseller_admin' ],
|
||||
'groups' => ['admin', 'reseller_admin'],
|
||||
},
|
||||
],
|
||||
Optional[String[1]] $reseller_prefix = undef,
|
||||
@@ -80,10 +80,9 @@ class swift::proxy::tempauth (
|
||||
Optional[Boolean] $allow_overrides = undef,
|
||||
Optional[Enum['http', 'https', 'default']] $storage_url_scheme = undef,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
if ($reseller_prefix) {
|
||||
if $reseller_prefix {
|
||||
$reseller_prefix_upcase = upcase($reseller_prefix)
|
||||
} else {
|
||||
$reseller_prefix_upcase = $reseller_prefix
|
||||
|
@@ -11,8 +11,7 @@
|
||||
#
|
||||
# Adam Vinsh <adam.vinsh@charter.com>
|
||||
#
|
||||
define swift::proxy::tempauth_account() {
|
||||
|
||||
define swift::proxy::tempauth_account {
|
||||
include swift::deps
|
||||
|
||||
# strip white space and split string into array elements around ','
|
||||
|
@@ -56,7 +56,6 @@ class swift::proxy::tempurl (
|
||||
$outgoing_allow_headers = $facts['os_service_default'],
|
||||
$allowed_digests = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -14,7 +14,6 @@
|
||||
class swift::proxy::versioned_writes (
|
||||
$allow_versioned_writes = false
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift_proxy_config {
|
||||
|
@@ -24,16 +24,15 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
class swift::ringbuilder(
|
||||
class swift::ringbuilder (
|
||||
$part_power = undef,
|
||||
$replicas = undef,
|
||||
$min_part_hours = undef
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
Class['swift'] -> Class['swift::ringbuilder']
|
||||
|
||||
swift::ringbuilder::create{ ['object', 'account', 'container']:
|
||||
swift::ringbuilder::create { ['object', 'account', 'container']:
|
||||
part_power => $part_power,
|
||||
replicas => $replicas,
|
||||
min_part_hours => $min_part_hours,
|
||||
@@ -45,6 +44,5 @@ class swift::ringbuilder(
|
||||
|
||||
Swift::Ringbuilder::Create['account'] -> Ring_account_device <| |> ~> Swift::Ringbuilder::Rebalance['account']
|
||||
|
||||
swift::ringbuilder::rebalance{ ['object', 'account', 'container']: }
|
||||
|
||||
swift::ringbuilder::rebalance { ['object', 'account', 'container']: }
|
||||
}
|
||||
|
@@ -35,14 +35,13 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
define swift::ringbuilder::create(
|
||||
define swift::ringbuilder::create (
|
||||
Swift::RingType $ring_type = $name,
|
||||
$part_power = 18,
|
||||
$replicas = 3,
|
||||
$min_part_hours = 24,
|
||||
$user = 'root'
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
exec { "create_${ring_type}":
|
||||
@@ -52,5 +51,4 @@ define swift::ringbuilder::create(
|
||||
creates => "/etc/swift/${ring_type}.builder",
|
||||
before => Anchor['swift::config::end'],
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -37,13 +37,12 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
define swift::ringbuilder::policy_ring(
|
||||
define swift::ringbuilder::policy_ring (
|
||||
Pattern[/^\d+$/] $policy_id = $name,
|
||||
$part_power = undef,
|
||||
$replicas = undef,
|
||||
$min_part_hours = undef,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
Class['swift'] -> Swift::Ringbuilder::Policy_ring[$policy_id]
|
||||
|
||||
@@ -53,13 +52,12 @@ define swift::ringbuilder::policy_ring(
|
||||
$ring_builder = "object-${policy_id}"
|
||||
}
|
||||
|
||||
swift::ringbuilder::create{ $ring_builder :
|
||||
swift::ringbuilder::create { $ring_builder :
|
||||
part_power => $part_power,
|
||||
replicas => $replicas,
|
||||
min_part_hours => $min_part_hours,
|
||||
}
|
||||
swift::ringbuilder::rebalance{ $ring_builder: }
|
||||
swift::ringbuilder::rebalance { $ring_builder: }
|
||||
|
||||
Swift::Ringbuilder::Create[$ring_builder] -> Ring_object_device <| |> ~> Swift::Ringbuilder::Rebalance[$ring_builder]
|
||||
|
||||
}
|
||||
|
@@ -12,11 +12,10 @@
|
||||
# [*seed*]
|
||||
# Optional. Seed value used to seed pythons pseudo-random for ringbuilding.
|
||||
#
|
||||
define swift::ringbuilder::rebalance(
|
||||
define swift::ringbuilder::rebalance (
|
||||
Swift::RingType $ring_type = $name,
|
||||
Optional[Variant[Integer[0], Pattern[/^\d+$/]]] $seed = undef
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
exec { "rebalance_${ring_type}":
|
||||
|
@@ -29,12 +29,11 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
class swift::ringserver(
|
||||
class swift::ringserver (
|
||||
$local_net_ip,
|
||||
$max_connections = 5,
|
||||
$rsync_use_xinetd = $swift::params::xinetd_available,
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
Class['swift::ringbuilder'] -> Class['swift::ringserver']
|
||||
|
||||
|
@@ -5,11 +5,10 @@
|
||||
# [*ring_type*]
|
||||
# (optional) The type of ring to create. Accepts object|container|account
|
||||
#
|
||||
define swift::ringsync(
|
||||
define swift::ringsync (
|
||||
String[1] $ring_server,
|
||||
Swift::RingType $ring_type = $name,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
Exec { path => '/usr/bin' }
|
||||
|
@@ -41,7 +41,7 @@
|
||||
# [*service_tag*]
|
||||
# (optional) Additional tag to be added to the service resource
|
||||
#
|
||||
define swift::service(
|
||||
define swift::service (
|
||||
String[1] $os_family_service_name,
|
||||
String[1] $config_file_name,
|
||||
$service_ensure = undef,
|
||||
@@ -51,11 +51,10 @@ define swift::service(
|
||||
$service_require = undef,
|
||||
Optional[String[1]] $service_tag = undef,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
if(! member($swift::params::swift_init_service_names, $name)) {
|
||||
if !member($swift::params::swift_init_service_names, $name) {
|
||||
fail("swift::service name: ${name} is not a valid swift_init_service_name")
|
||||
}
|
||||
|
||||
|
@@ -24,11 +24,10 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
class swift::storage(
|
||||
class swift::storage (
|
||||
$storage_local_net_ip,
|
||||
$rsync_use_xinetd = $swift::params::xinetd_available,
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
|
||||
if $rsync_use_xinetd and ! $swift::params::xinetd_available {
|
||||
|
@@ -26,14 +26,13 @@
|
||||
# See README for more details.
|
||||
# Defaults to $swift::params::service_provider.
|
||||
#
|
||||
class swift::storage::account(
|
||||
class swift::storage::account (
|
||||
Boolean $manage_service = true,
|
||||
Boolean $enabled = true,
|
||||
$package_ensure = 'present',
|
||||
String[1] $config_file_name = 'account-server.conf',
|
||||
Swift::ServiceProvider $service_provider = $swift::params::service_provider
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift::storage::generic { 'account':
|
||||
|
@@ -140,7 +140,7 @@
|
||||
# (optional) Override whether to use xinetd to manage rsync service
|
||||
# Defaults to swift::params::xinetd_available
|
||||
#
|
||||
class swift::storage::all(
|
||||
class swift::storage::all (
|
||||
$storage_local_net_ip,
|
||||
$devices = '/srv/node',
|
||||
$object_port = 6000,
|
||||
@@ -176,7 +176,6 @@ class swift::storage::all(
|
||||
$splice = false,
|
||||
$rsync_use_xinetd = $swift::params::xinetd_available,
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
|
||||
if ("${$object_port}" == '6000') {
|
||||
|
@@ -31,7 +31,7 @@
|
||||
# See README for more details.
|
||||
# Defaults to $swift::params::service_provider.
|
||||
#
|
||||
class swift::storage::container(
|
||||
class swift::storage::container (
|
||||
Boolean $manage_service = true,
|
||||
Boolean $enabled = true,
|
||||
$package_ensure = 'present',
|
||||
@@ -39,7 +39,6 @@ class swift::storage::container(
|
||||
String[1] $config_file_name = 'container-server.conf',
|
||||
Swift::ServiceProvider $service_provider = $swift::params::service_provider
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift::storage::generic { 'container':
|
||||
|
@@ -44,7 +44,7 @@
|
||||
# Defaults to 'swift'.
|
||||
#
|
||||
|
||||
class swift::storage::cron::recon(
|
||||
class swift::storage::cron::recon (
|
||||
$minute = '*/5',
|
||||
$hour = '*',
|
||||
$monthday = '*',
|
||||
@@ -53,7 +53,6 @@ class swift::storage::cron::recon(
|
||||
$configfile = '/etc/swift/object-server.conf',
|
||||
$user = $swift::params::user
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
|
||||
cron { 'swift-recon-cron':
|
||||
|
@@ -73,7 +73,7 @@
|
||||
#
|
||||
# TODO(yuxcer): maybe we can remove param $base_dir
|
||||
#
|
||||
define swift::storage::disk(
|
||||
define swift::storage::disk (
|
||||
Stdlib::Absolutepath $base_dir = '/dev',
|
||||
Stdlib::Absolutepath $mnt_base_dir = '/srv/node',
|
||||
$byte_size = '1024',
|
||||
@@ -84,7 +84,6 @@ define swift::storage::disk(
|
||||
Boolean $manage_filesystem = true,
|
||||
String[1] $label = $name,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
@@ -113,7 +112,8 @@ define swift::storage::disk(
|
||||
}
|
||||
}
|
||||
|
||||
create_resources("swift::storage::${filesystem_type}", { $name => {
|
||||
create_resources("swift::storage::${filesystem_type}", {
|
||||
$name => {
|
||||
'device' => "${base_dir}/${name}",
|
||||
'mnt_base_dir' => $mnt_base_dir,
|
||||
'byte_size' => $byte_size,
|
||||
@@ -121,6 +121,6 @@ define swift::storage::disk(
|
||||
'mount_type' => $mount_type,
|
||||
'manage_filesystem' => $manage_filesystem,
|
||||
'label' => $label,
|
||||
}})
|
||||
|
||||
},
|
||||
})
|
||||
}
|
||||
|
@@ -24,6 +24,9 @@
|
||||
# [*defaults*] A config hash
|
||||
# Optional. Defaults to a empty hash
|
||||
#
|
||||
class swift::storage::disks($args = {}, $defaults = {}) {
|
||||
class swift::storage::disks (
|
||||
$args = {},
|
||||
$defaults = {}
|
||||
) {
|
||||
create_resources(swift::storage::disk, $args, $defaults)
|
||||
}
|
||||
|
@@ -100,7 +100,7 @@
|
||||
# audit config.
|
||||
# Defaults to false.
|
||||
#
|
||||
class swift::storage::drive_audit(
|
||||
class swift::storage::drive_audit (
|
||||
# cron options
|
||||
$user = $swift::params::user,
|
||||
$minute = 1,
|
||||
@@ -128,7 +128,6 @@ class swift::storage::drive_audit(
|
||||
Hash[String[1], String[1]] $regex_pattern = {},
|
||||
Boolean $purge_config = false,
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
|
||||
resources { 'swift_drive_audit_config':
|
||||
@@ -145,7 +144,6 @@ class swift::storage::drive_audit(
|
||||
}
|
||||
File['/etc/swift/drive-audit.conf'] -> Swift_drive_audit_config<||>
|
||||
|
||||
|
||||
swift_drive_audit_config {
|
||||
'drive-audit/log_name' : value => $log_name;
|
||||
'drive-audit/log_facility' : value => $log_facility;
|
||||
|
@@ -34,7 +34,7 @@
|
||||
# (optional) Filesystem label.
|
||||
# Defaults to $name.
|
||||
#
|
||||
define swift::storage::ext4(
|
||||
define swift::storage::ext4 (
|
||||
Stdlib::Absolutepath $device = "/dev/${name}",
|
||||
$byte_size = '1024',
|
||||
Stdlib::Absolutepath $mnt_base_dir = '/srv/node',
|
||||
@@ -43,7 +43,6 @@ define swift::storage::ext4(
|
||||
Boolean $manage_filesystem = true,
|
||||
String[1] $label = $name,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
case $mount_type {
|
||||
|
@@ -60,7 +60,7 @@
|
||||
#
|
||||
# Copyright 2022 Red Hat, unless otherwise noted.
|
||||
#
|
||||
define swift::storage::filter::backend_ratelimit(
|
||||
define swift::storage::filter::backend_ratelimit (
|
||||
$requests_per_device_per_second = $facts['os_service_default'],
|
||||
$delete_requests_per_device_per_second = $facts['os_service_default'],
|
||||
$get_requests_per_device_per_second = $facts['os_service_default'],
|
||||
@@ -71,7 +71,6 @@ define swift::storage::filter::backend_ratelimit(
|
||||
$update_requests_per_device_per_second = $facts['os_service_default'],
|
||||
$requests_per_device_rate_buffer = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
$config_type = "swift_${name}_config"
|
||||
@@ -108,5 +107,4 @@ define swift::storage::filter::backend_ratelimit(
|
||||
'value' => $requests_per_device_rate_buffer,
|
||||
}
|
||||
})
|
||||
|
||||
}
|
||||
|
@@ -3,14 +3,12 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
define swift::storage::filter::healthcheck(
|
||||
) {
|
||||
|
||||
define swift::storage::filter::healthcheck {
|
||||
include swift::deps
|
||||
|
||||
$config_type = "swift_${name}_config"
|
||||
|
||||
create_resources($config_type, {
|
||||
'filter:healthcheck/use' => {'value' => 'egg:swift#healthcheck'},
|
||||
'filter:healthcheck/use' => { 'value' => 'egg:swift#healthcheck' },
|
||||
})
|
||||
}
|
||||
|
@@ -19,17 +19,15 @@
|
||||
#
|
||||
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
|
||||
#
|
||||
define swift::storage::filter::recon(
|
||||
define swift::storage::filter::recon (
|
||||
$cache_path = $facts['os_service_default'],
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
$config_type = "swift_${name}_config"
|
||||
|
||||
create_resources($config_type, {
|
||||
'filter:recon/use' => {'value' => 'egg:swift#recon'},
|
||||
'filter:recon/recon_cache_path' => {'value' => $cache_path},
|
||||
'filter:recon/use' => { 'value' => 'egg:swift#recon' },
|
||||
'filter:recon/recon_cache_path' => { 'value' => $cache_path },
|
||||
})
|
||||
|
||||
}
|
||||
|
@@ -33,7 +33,7 @@
|
||||
# == Dependencies
|
||||
# Requires Class[swift::storage]
|
||||
#
|
||||
define swift::storage::generic(
|
||||
define swift::storage::generic (
|
||||
Swift::StorageServerType $type = $name,
|
||||
Boolean $manage_service = true,
|
||||
Boolean $enabled = true,
|
||||
@@ -41,7 +41,6 @@ define swift::storage::generic(
|
||||
String[1] $config_file_name = "${name}-server.conf",
|
||||
Swift::ServiceProvider $service_provider = $swift::params::service_provider
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
|
@@ -30,14 +30,13 @@
|
||||
# (optional) The filesystem type.
|
||||
# Defaults to 'xfs'.
|
||||
#
|
||||
define swift::storage::loopback(
|
||||
define swift::storage::loopback (
|
||||
$base_dir = '/srv/loopback-device',
|
||||
$mnt_base_dir = '/srv/node',
|
||||
$byte_size = '1024',
|
||||
$seek = '25000',
|
||||
$fstype = 'xfs'
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
|
@@ -24,6 +24,9 @@
|
||||
# [*defaults*] A config hash
|
||||
# Optional. Defaults to a empty hash
|
||||
#
|
||||
class swift::storage::loopbacks($args = {}, $defaults = {}) {
|
||||
class swift::storage::loopbacks (
|
||||
$args = {},
|
||||
$defaults = {},
|
||||
) {
|
||||
create_resources(swift::storage::loopback, $args, $defaults)
|
||||
}
|
||||
|
@@ -18,23 +18,22 @@
|
||||
# (optional) The filesystem type.
|
||||
# Defaults to 'xfs'.
|
||||
#
|
||||
define swift::storage::mount(
|
||||
define swift::storage::mount (
|
||||
Swift::MountDevice $device = "/dev/${name}",
|
||||
Stdlib::Absolutepath $mnt_base_dir = '/srv/node',
|
||||
Boolean $loopback = false,
|
||||
String[1] $fstype = 'xfs'
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
if($loopback){
|
||||
if $loopback {
|
||||
$options = 'noatime,nodiratime,nofail,loop'
|
||||
} else {
|
||||
$options = 'noatime,nodiratime,nofail'
|
||||
}
|
||||
|
||||
if($fstype == 'xfs'){
|
||||
if $fstype == 'xfs' {
|
||||
$fsoptions = 'logbufs=8'
|
||||
} else {
|
||||
$fsoptions = 'user_xattr'
|
||||
|
@@ -41,7 +41,7 @@
|
||||
# [*policy_index*]
|
||||
# (optional) storage policy index
|
||||
# Defaults to undef
|
||||
define swift::storage::node(
|
||||
define swift::storage::node (
|
||||
$mnt_base_dir,
|
||||
Variant[Integer, Pattern[/^\d+$/]] $zone,
|
||||
$weight = 1,
|
||||
@@ -51,7 +51,6 @@ define swift::storage::node(
|
||||
$storage_local_net_ip = '127.0.0.1',
|
||||
$policy_index = undef,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
Swift::Storage::Server {
|
||||
@@ -94,5 +93,4 @@ define swift::storage::node(
|
||||
zone => $zone,
|
||||
weight => $weight,
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -26,14 +26,13 @@
|
||||
# See README for more details.
|
||||
# Defaults to $swift::params::service_provider.
|
||||
#
|
||||
class swift::storage::object(
|
||||
class swift::storage::object (
|
||||
Boolean $manage_service = true,
|
||||
Boolean $enabled = true,
|
||||
$package_ensure = 'present',
|
||||
String[1] $config_file_name = 'object-server.conf',
|
||||
Swift::ServiceProvider $service_provider = $swift::params::service_provider
|
||||
) inherits swift::params {
|
||||
|
||||
include swift::deps
|
||||
|
||||
swift::storage::generic { 'object':
|
||||
|
@@ -1,4 +1,4 @@
|
||||
# Class swift::storage::policy
|
||||
# Define swift::storage::policy
|
||||
#
|
||||
# Setting any optional parameter to undef will remove it
|
||||
# from the storage policy defined in swift.conf.
|
||||
@@ -57,7 +57,7 @@
|
||||
# feeding a segment into the encoder/decoder in bytes.
|
||||
# Defaults to undef
|
||||
#
|
||||
define swift::storage::policy(
|
||||
define swift::storage::policy (
|
||||
$policy_name,
|
||||
$default_policy,
|
||||
$ensure = 'present',
|
||||
@@ -70,7 +70,6 @@ define swift::storage::policy(
|
||||
$ec_num_parity_fragments = undef,
|
||||
$ec_object_segment_size = undef,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
|
||||
Swift_storage_policy<| |> ~> Service<| tag == 'swift-service' |>
|
||||
@@ -95,5 +94,4 @@ define swift::storage::policy(
|
||||
ec_num_parity_fragments => $ec_num_parity_fragments,
|
||||
ec_object_segment_size => $ec_object_segment_size,
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -291,7 +291,7 @@
|
||||
# in the config file.
|
||||
# Defaults to false.
|
||||
#
|
||||
define swift::storage::server(
|
||||
define swift::storage::server (
|
||||
Swift::StorageServerType $type,
|
||||
$storage_local_net_ip,
|
||||
Pattern[/^\d+$/] $bind_port = $name,
|
||||
@@ -361,8 +361,7 @@ define swift::storage::server(
|
||||
$container_sharder_conn_timeout = $facts['os_service_default'],
|
||||
$container_sharder_node_timeout = $facts['os_service_default'],
|
||||
Boolean $purge_config = false,
|
||||
){
|
||||
|
||||
) {
|
||||
include swift::deps
|
||||
include swift::params
|
||||
|
||||
@@ -437,39 +436,39 @@ define swift::storage::server(
|
||||
|
||||
# common settings
|
||||
$common_opts = {
|
||||
'DEFAULT/devices' => {'value' => $devices},
|
||||
'DEFAULT/bind_ip' => {'value' => $storage_local_net_ip},
|
||||
'DEFAULT/bind_port' => {'value' => $bind_port},
|
||||
'DEFAULT/mount_check' => {'value' => $mount_check},
|
||||
'DEFAULT/disable_fallocate' => {'value' => $disable_fallocate},
|
||||
'DEFAULT/fallocate_reserve' => {'value' => $fallocate_reserve},
|
||||
'DEFAULT/user' => {'value' => $user_real},
|
||||
'DEFAULT/workers' => {'value' => $workers},
|
||||
'DEFAULT/conn_timeout' => {'value' => $conn_timeout},
|
||||
'DEFAULT/node_timeout' => {'value' => $node_timeout},
|
||||
'DEFAULT/log_name' => {'value' => $log_name},
|
||||
'DEFAULT/log_facility' => {'value' => $log_facility},
|
||||
'DEFAULT/log_level' => {'value' => $log_level},
|
||||
'DEFAULT/log_address' => {'value' => $log_address},
|
||||
'DEFAULT/log_udp_host' => {'value' => $log_udp_host},
|
||||
'DEFAULT/log_udp_port' => {'value' => $log_udp_port},
|
||||
'DEFAULT/log_max_line_length' => {'value' => $log_max_line_length},
|
||||
'DEFAULT/devices' => { 'value' => $devices },
|
||||
'DEFAULT/bind_ip' => { 'value' => $storage_local_net_ip },
|
||||
'DEFAULT/bind_port' => { 'value' => $bind_port },
|
||||
'DEFAULT/mount_check' => { 'value' => $mount_check },
|
||||
'DEFAULT/disable_fallocate' => { 'value' => $disable_fallocate },
|
||||
'DEFAULT/fallocate_reserve' => { 'value' => $fallocate_reserve },
|
||||
'DEFAULT/user' => { 'value' => $user_real },
|
||||
'DEFAULT/workers' => { 'value' => $workers },
|
||||
'DEFAULT/conn_timeout' => { 'value' => $conn_timeout },
|
||||
'DEFAULT/node_timeout' => { 'value' => $node_timeout },
|
||||
'DEFAULT/log_name' => { 'value' => $log_name },
|
||||
'DEFAULT/log_facility' => { 'value' => $log_facility },
|
||||
'DEFAULT/log_level' => { 'value' => $log_level },
|
||||
'DEFAULT/log_address' => { 'value' => $log_address },
|
||||
'DEFAULT/log_udp_host' => { 'value' => $log_udp_host },
|
||||
'DEFAULT/log_udp_port' => { 'value' => $log_udp_port },
|
||||
'DEFAULT/log_max_line_length' => { 'value' => $log_max_line_length },
|
||||
# pipeline
|
||||
'pipeline:main/pipeline' => {'value' => join($pipeline, ' ')},
|
||||
'pipeline:main/pipeline' => { 'value' => join($pipeline, ' ') },
|
||||
# server
|
||||
"app:${type}-server/use" => {'value' => "egg:swift#${type}"},
|
||||
"app:${type}-server/set log_name" => {'value' => $log_name},
|
||||
"app:${type}-server/set log_facility" => {'value' => $log_facility},
|
||||
"app:${type}-server/set log_level" => {'value' => $log_level},
|
||||
"app:${type}-server/set log_requests" => {'value' => $log_requests},
|
||||
"app:${type}-server/set log_address" => {'value' => $log_address},
|
||||
"app:${type}-server/fallocate_reserve" => {'value' => $server_fallocate_reserve},
|
||||
"app:${type}-server/stale_worker_timeout" => {'value' => $stale_worker_timeout},
|
||||
"app:${type}-server/use" => { 'value' => "egg:swift#${type}" },
|
||||
"app:${type}-server/set log_name" => { 'value' => $log_name },
|
||||
"app:${type}-server/set log_facility" => { 'value' => $log_facility },
|
||||
"app:${type}-server/set log_level" => { 'value' => $log_level },
|
||||
"app:${type}-server/set log_requests" => { 'value' => $log_requests },
|
||||
"app:${type}-server/set log_address" => { 'value' => $log_address },
|
||||
"app:${type}-server/fallocate_reserve" => { 'value' => $server_fallocate_reserve },
|
||||
"app:${type}-server/stale_worker_timeout" => { 'value' => $stale_worker_timeout },
|
||||
# auditor
|
||||
"${type}-auditor/" => {'ensure' => present},
|
||||
"${type}-auditor/" => { 'ensure' => present },
|
||||
# replicator
|
||||
"${type}-replicator/" => {'ensure' => present},
|
||||
"${type}-replicator/rsync_module" => {'value' => $rsync_module},
|
||||
"${type}-replicator/" => { 'ensure' => present },
|
||||
"${type}-replicator/rsync_module" => { 'value' => $rsync_module },
|
||||
}
|
||||
|
||||
Anchor['swift::config::begin']
|
||||
@@ -479,98 +478,98 @@ define swift::storage::server(
|
||||
# statsd
|
||||
if $statsd_enabled {
|
||||
$log_statsd_opts = {
|
||||
'DEFAULT/log_statsd_host' => {'value' => $log_statsd_host},
|
||||
'DEFAULT/log_statsd_port' => {'value' => $log_statsd_port},
|
||||
'DEFAULT/log_statsd_default_sample_rate' => {'value' => $log_statsd_default_sample_rate},
|
||||
'DEFAULT/log_statsd_sample_rate_factor' => {'value' => $log_statsd_sample_rate_factor},
|
||||
'DEFAULT/log_statsd_metric_prefix' => {'value' => $log_statsd_metric_prefix},
|
||||
'DEFAULT/log_statsd_host' => { 'value' => $log_statsd_host },
|
||||
'DEFAULT/log_statsd_port' => { 'value' => $log_statsd_port },
|
||||
'DEFAULT/log_statsd_default_sample_rate' => { 'value' => $log_statsd_default_sample_rate },
|
||||
'DEFAULT/log_statsd_sample_rate_factor' => { 'value' => $log_statsd_sample_rate_factor },
|
||||
'DEFAULT/log_statsd_metric_prefix' => { 'value' => $log_statsd_metric_prefix },
|
||||
}
|
||||
} else {
|
||||
$log_statsd_opts = {
|
||||
'DEFAULT/log_statsd_host' => {'value' => $facts['os_service_default']},
|
||||
'DEFAULT/log_statsd_port' => {'value' => $facts['os_service_default']},
|
||||
'DEFAULT/log_statsd_default_sample_rate' => {'value' => $facts['os_service_default']},
|
||||
'DEFAULT/log_statsd_sample_rate_factor' => {'value' => $facts['os_service_default']},
|
||||
'DEFAULT/log_statsd_metric_prefix' => {'value' => $facts['os_service_default']},
|
||||
'DEFAULT/log_statsd_host' => { 'value' => $facts['os_service_default'] },
|
||||
'DEFAULT/log_statsd_port' => { 'value' => $facts['os_service_default'] },
|
||||
'DEFAULT/log_statsd_default_sample_rate' => { 'value' => $facts['os_service_default'] },
|
||||
'DEFAULT/log_statsd_sample_rate_factor' => { 'value' => $facts['os_service_default'] },
|
||||
'DEFAULT/log_statsd_metric_prefix' => { 'value' => $facts['os_service_default'] },
|
||||
}
|
||||
}
|
||||
|
||||
case $type {
|
||||
'account': {
|
||||
$type_opts = {
|
||||
'DEFAULT/db_preallocation' => {'value' => $db_preallocation},
|
||||
'DEFAULT/db_preallocation' => { 'value' => $db_preallocation },
|
||||
# account-server
|
||||
# account-auditor
|
||||
# account-replicator
|
||||
'account-replicator/concurrency' => {'value' => $replicator_concurrency},
|
||||
'account-replicator/interval' => {'value' => $replicator_interval},
|
||||
'account-replicator/conn_timeout' => {'value' => $replicator_conn_timeout},
|
||||
'account-replicator/node_timeout' => {'value' => $replicator_node_timeout},
|
||||
'account-replicator/concurrency' => { 'value' => $replicator_concurrency },
|
||||
'account-replicator/interval' => { 'value' => $replicator_interval },
|
||||
'account-replicator/conn_timeout' => { 'value' => $replicator_conn_timeout },
|
||||
'account-replicator/node_timeout' => { 'value' => $replicator_node_timeout },
|
||||
# account-reaper
|
||||
'account-reaper/' => {'ensure' => present},
|
||||
'account-reaper/concurrency' => {'value' => $reaper_concurrency},
|
||||
'account-reaper/interval' => {'value' => $reaper_interval},
|
||||
'account-reaper/conn_timeout' => {'value' => $reaper_conn_timeout},
|
||||
'account-reaper/node_timeout' => {'value' => $reaper_node_timeout},
|
||||
'account-reaper/' => { 'ensure' => present },
|
||||
'account-reaper/concurrency' => { 'value' => $reaper_concurrency },
|
||||
'account-reaper/interval' => { 'value' => $reaper_interval },
|
||||
'account-reaper/conn_timeout' => { 'value' => $reaper_conn_timeout },
|
||||
'account-reaper/node_timeout' => { 'value' => $reaper_node_timeout },
|
||||
}
|
||||
|
||||
if $log_name_per_daemon {
|
||||
$log_name_opts = {
|
||||
'account-auditor/log_name' => {'value' => 'account-auditor'},
|
||||
'account-replicator/log_name' => {'value' => 'account-replicator'},
|
||||
'account-reaper/log_name' => {'value' => 'account-reaper'},
|
||||
'account-auditor/log_name' => { 'value' => 'account-auditor' },
|
||||
'account-replicator/log_name' => { 'value' => 'account-replicator' },
|
||||
'account-reaper/log_name' => { 'value' => 'account-reaper' },
|
||||
}
|
||||
} else {
|
||||
$log_name_opts = {
|
||||
'account-auditor/log_name' => {'ensure' => absent},
|
||||
'account-replicator/log_name' => {'ensure' => absent},
|
||||
'account-reaper/log_name' => {'ensure' => absent},
|
||||
'account-auditor/log_name' => { 'ensure' => absent },
|
||||
'account-replicator/log_name' => { 'ensure' => absent },
|
||||
'account-reaper/log_name' => { 'ensure' => absent },
|
||||
}
|
||||
}
|
||||
}
|
||||
'container': {
|
||||
$type_opts = {
|
||||
'DEFAULT/db_preallocation' => {'value' => $db_preallocation},
|
||||
'DEFAULT/allowed_sync_hosts' => {'value' => join($swift::storage::container::allowed_sync_hosts, ',')},
|
||||
'DEFAULT/db_preallocation' => { 'value' => $db_preallocation },
|
||||
'DEFAULT/allowed_sync_hosts' => { 'value' => join($swift::storage::container::allowed_sync_hosts, ',') },
|
||||
# container-server
|
||||
# container-auditor
|
||||
# container-replicator
|
||||
'container-replicator/concurrency' => {'value' => $replicator_concurrency},
|
||||
'container-replicator/interval' => {'value' => $replicator_interval},
|
||||
'container-replicator/conn_timeout' => {'value' => $replicator_conn_timeout},
|
||||
'container-replicator/node_timeout' => {'value' => $replicator_node_timeout},
|
||||
'container-replicator/concurrency' => { 'value' => $replicator_concurrency },
|
||||
'container-replicator/interval' => { 'value' => $replicator_interval },
|
||||
'container-replicator/conn_timeout' => { 'value' => $replicator_conn_timeout },
|
||||
'container-replicator/node_timeout' => { 'value' => $replicator_node_timeout },
|
||||
# container-updater
|
||||
'container-updater/' => {'ensure' => present},
|
||||
'container-updater/concurrency' => {'value' => $updater_concurrency},
|
||||
'container-updater/interval' => {'value' => $updater_interval},
|
||||
'container-updater/conn_timeout' => {'value' => $updater_conn_timeout},
|
||||
'container-updater/node_timeout' => {'value' => $updater_node_timeout},
|
||||
'container-updater/' => { 'ensure' => present },
|
||||
'container-updater/concurrency' => { 'value' => $updater_concurrency },
|
||||
'container-updater/interval' => { 'value' => $updater_interval },
|
||||
'container-updater/conn_timeout' => { 'value' => $updater_conn_timeout },
|
||||
'container-updater/node_timeout' => { 'value' => $updater_node_timeout },
|
||||
# container-sync
|
||||
'container-sync/' => {'ensure' => present},
|
||||
'container-sync/' => { 'ensure' => present },
|
||||
# container-sharder
|
||||
'container-sharder/' => {'ensure' => present},
|
||||
'container-sharder/auto_shard' => {'value' => $container_sharder_auto_shard},
|
||||
'container-sharder/concurrency' => {'value' => $container_sharder_concurrency},
|
||||
'container-sharder/interval' => {'value' => $container_sharder_interval},
|
||||
'container-sharder/conn_timeout' => {'value' => $container_sharder_conn_timeout},
|
||||
'container-sharder/node_timeout' => {'value' => $container_sharder_node_timeout},
|
||||
'container-sharder/' => { 'ensure' => present },
|
||||
'container-sharder/auto_shard' => { 'value' => $container_sharder_auto_shard },
|
||||
'container-sharder/concurrency' => { 'value' => $container_sharder_concurrency },
|
||||
'container-sharder/interval' => { 'value' => $container_sharder_interval },
|
||||
'container-sharder/conn_timeout' => { 'value' => $container_sharder_conn_timeout },
|
||||
'container-sharder/node_timeout' => { 'value' => $container_sharder_node_timeout },
|
||||
}
|
||||
|
||||
if $log_name_per_daemon {
|
||||
$log_name_opts = {
|
||||
'container-auditor/log_name' => {'value' => 'container-auditor'},
|
||||
'container-replicator/log_name' => {'value' => 'container-replicator'},
|
||||
'container-updater/log_name' => {'value' => 'container-updater'},
|
||||
'container-sync/log_name' => {'value' => 'container-sync'},
|
||||
'container-sharder/log_name' => {'value' => 'container-sharder'},
|
||||
'container-auditor/log_name' => { 'value' => 'container-auditor' },
|
||||
'container-replicator/log_name' => { 'value' => 'container-replicator' },
|
||||
'container-updater/log_name' => { 'value' => 'container-updater' },
|
||||
'container-sync/log_name' => { 'value' => 'container-sync' },
|
||||
'container-sharder/log_name' => { 'value' => 'container-sharder' },
|
||||
}
|
||||
} else {
|
||||
$log_name_opts = {
|
||||
'container-auditor/log_name' => {'ensure' => absent},
|
||||
'container-replicator/log_name' => {'ensure' => absent},
|
||||
'container-updater/log_name' => {'ensure' => absent},
|
||||
'container-sync/log_name' => {'ensure' => absent},
|
||||
'container-sharder/log_name' => {'ensure' => absent},
|
||||
'container-auditor/log_name' => { 'ensure' => absent },
|
||||
'container-replicator/log_name' => { 'ensure' => absent },
|
||||
'container-updater/log_name' => { 'ensure' => absent },
|
||||
'container-sync/log_name' => { 'ensure' => absent },
|
||||
'container-sharder/log_name' => { 'ensure' => absent },
|
||||
}
|
||||
}
|
||||
|
||||
@@ -586,48 +585,48 @@ define swift::storage::server(
|
||||
}
|
||||
'object': {
|
||||
$type_opts = {
|
||||
'DEFAULT/servers_per_port' => {'value' => $servers_per_port},
|
||||
'DEFAULT/network_chunk_size' => {'value' => $network_chunk_size},
|
||||
'DEFAULT/disk_chunk_size' => {'value' => $disk_chunk_size},
|
||||
'DEFAULT/client_timeout' => {'value' => $client_timeout},
|
||||
'DEFAULT/servers_per_port' => { 'value' => $servers_per_port },
|
||||
'DEFAULT/network_chunk_size' => { 'value' => $network_chunk_size },
|
||||
'DEFAULT/disk_chunk_size' => { 'value' => $disk_chunk_size },
|
||||
'DEFAULT/client_timeout' => { 'value' => $client_timeout },
|
||||
# object-server
|
||||
'app:object-server/splice' => {'value' => $splice},
|
||||
'app:object-server/mb_per_sync' => {'value' => $object_server_mb_per_sync},
|
||||
'app:object-server/splice' => { 'value' => $splice },
|
||||
'app:object-server/mb_per_sync' => { 'value' => $object_server_mb_per_sync },
|
||||
# object-auditor
|
||||
'object-auditor/disk_chunk_size' => {'value' => $auditor_disk_chunk_size},
|
||||
'object-auditor/disk_chunk_size' => { 'value' => $auditor_disk_chunk_size },
|
||||
# object-replicator
|
||||
'object-replicator/concurrency' => {'value' => $replicator_concurrency},
|
||||
'object-replicator/conn_timeout' => {'value' => $replicator_conn_timeout},
|
||||
'object-replicator/node_timeout' => {'value' => $replicator_node_timeout},
|
||||
'object-replicator/rsync_timeout' => {'value' => $rsync_timeout},
|
||||
'object-replicator/rsync_bwlimit' => {'value' => $rsync_bwlimit},
|
||||
'object-replicator/concurrency' => { 'value' => $replicator_concurrency },
|
||||
'object-replicator/conn_timeout' => { 'value' => $replicator_conn_timeout },
|
||||
'object-replicator/node_timeout' => { 'value' => $replicator_node_timeout },
|
||||
'object-replicator/rsync_timeout' => { 'value' => $rsync_timeout },
|
||||
'object-replicator/rsync_bwlimit' => { 'value' => $rsync_bwlimit },
|
||||
# object-updater
|
||||
'object-updater/' => {'ensure' => present},
|
||||
'object-updater/concurrency' => {'value' => $updater_concurrency},
|
||||
'object-updater/interval' => {'value' => $updater_interval},
|
||||
'object-updater/conn_timeout' => {'value' => $updater_conn_timeout},
|
||||
'object-updater/node_timeout' => {'value' => $updater_node_timeout},
|
||||
'object-updater/' => { 'ensure' => present },
|
||||
'object-updater/concurrency' => { 'value' => $updater_concurrency },
|
||||
'object-updater/interval' => { 'value' => $updater_interval },
|
||||
'object-updater/conn_timeout' => { 'value' => $updater_conn_timeout },
|
||||
'object-updater/node_timeout' => { 'value' => $updater_node_timeout },
|
||||
# object-reconstructor
|
||||
'object-reconstructor/' => {'ensure' => present},
|
||||
'object-reconstructor/' => { 'ensure' => present },
|
||||
# object-relinker
|
||||
'object-relinker/' => {'ensure' => present},
|
||||
'object-relinker/' => { 'ensure' => present },
|
||||
}
|
||||
|
||||
if $log_name_per_daemon {
|
||||
$log_name_opts = {
|
||||
'object-auditor/log_name' => {'value' => 'object-auditor'},
|
||||
'object-replicator/log_name' => {'value' => 'object-replicator'},
|
||||
'object-updater/log_name' => {'value' => 'object-updater'},
|
||||
'object-reconstructor/log_name' => {'value' => 'object-reconstructor'},
|
||||
'object-relinker/log_name' => {'value' => 'object-relinker'},
|
||||
'object-auditor/log_name' => { 'value' => 'object-auditor' },
|
||||
'object-replicator/log_name' => { 'value' => 'object-replicator' },
|
||||
'object-updater/log_name' => { 'value' => 'object-updater' },
|
||||
'object-reconstructor/log_name' => { 'value' => 'object-reconstructor' },
|
||||
'object-relinker/log_name' => { 'value' => 'object-relinker' },
|
||||
}
|
||||
} else {
|
||||
$log_name_opts = {
|
||||
'object-auditor/log_name' => {'ensure' => absent},
|
||||
'object-replicator/log_name' => {'ensure' => absent},
|
||||
'object-updater/log_name' => {'ensure' => absent},
|
||||
'object-reconstructor/log_name' => {'ensure' => absent},
|
||||
'object-relinker/log_name' => {'ensure' => absent},
|
||||
'object-auditor/log_name' => { 'ensure' => absent },
|
||||
'object-replicator/log_name' => { 'ensure' => absent },
|
||||
'object-updater/log_name' => { 'ensure' => absent },
|
||||
'object-reconstructor/log_name' => { 'ensure' => absent },
|
||||
'object-relinker/log_name' => { 'ensure' => absent },
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -47,7 +47,7 @@
|
||||
# Creates /srv/node if dir does not exist, formats sdbX with XFS unless
|
||||
# it already has an XFS FS, and mounts de FS in /srv/node/sdX
|
||||
#
|
||||
define swift::storage::xfs(
|
||||
define swift::storage::xfs (
|
||||
Stdlib::Absolutepath $device = "/dev/${name}",
|
||||
$byte_size = '1024',
|
||||
Stdlib::Absolutepath $mnt_base_dir = '/srv/node',
|
||||
@@ -56,7 +56,6 @@ define swift::storage::xfs(
|
||||
Boolean $manage_filesystem = true,
|
||||
String[1] $label = $name,
|
||||
) {
|
||||
|
||||
include swift::deps
|
||||
include swift::params
|
||||
include swift::xfs
|
||||
@@ -81,7 +80,7 @@ define swift::storage::xfs(
|
||||
}
|
||||
}
|
||||
|
||||
if(!defined(File[$mnt_base_dir])) {
|
||||
if !defined(File[$mnt_base_dir]) {
|
||||
file { $mnt_base_dir:
|
||||
ensure => directory,
|
||||
owner => 'root',
|
||||
|
@@ -20,11 +20,10 @@
|
||||
class swift::wsgi::uwsgi_account (
|
||||
$processes = $facts['os_workers'],
|
||||
$listen_queue_size = 100,
|
||||
){
|
||||
|
||||
) {
|
||||
include swift::deps
|
||||
|
||||
if $facts['os']['name'] != 'Debian'{
|
||||
if $facts['os']['name'] != 'Debian' {
|
||||
warning('This class is only valid for Debian, as other operating systems are not using uwsgi by default.')
|
||||
}
|
||||
|
||||
|
@@ -20,11 +20,10 @@
|
||||
class swift::wsgi::uwsgi_container (
|
||||
$processes = $facts['os_workers'],
|
||||
$listen_queue_size = 100,
|
||||
){
|
||||
|
||||
) {
|
||||
include swift::deps
|
||||
|
||||
if $facts['os']['name'] != 'Debian'{
|
||||
if $facts['os']['name'] != 'Debian' {
|
||||
warning('This class is only valid for Debian, as other operating systems are not using uwsgi by default.')
|
||||
}
|
||||
|
||||
|
@@ -20,11 +20,10 @@
|
||||
class swift::wsgi::uwsgi_proxy (
|
||||
$processes = $facts['os_workers'],
|
||||
$listen_queue_size = 100,
|
||||
){
|
||||
|
||||
) {
|
||||
include swift::deps
|
||||
|
||||
if $facts['os']['name'] != 'Debian'{
|
||||
if $facts['os']['name'] != 'Debian' {
|
||||
warning('This class is only valid for Debian, as other operating systems are not using uwsgi by default.')
|
||||
}
|
||||
|
||||
|
@@ -2,10 +2,8 @@
|
||||
# package dependencies for creating
|
||||
# xfs partitions
|
||||
class swift::xfs {
|
||||
|
||||
include swift::deps
|
||||
|
||||
$packages = ['xfsprogs', 'parted']
|
||||
stdlib::ensure_packages($packages)
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user