puppet-swift/manifests/ringserver.pp
Adam Vinsh c659733d39 Add hooks for external install & svc management
This adds defined anchor points for external modules to hook into the
software install, config and service dependency chain.  This allows
external modules to manage software installation (virtualenv,
containers, etc) and service management (pacemaker) without needing rely
on resources that may change or be renamed.

Change-Id: I00cf4846bb933291469be94c9debed425eddf798
2016-05-25 08:52:47 -04:00

53 lines
1.1 KiB
Puppet

# == Class: swift::ringserver
#
# Used to create an rsync server to serve up the ring databases via rsync
#
# === Parameters
#
# [*local_net_ip*]
# (required) ip address that the swift servers should bind to.
#
# [*max_connections*]
# (optional) maximum connections to rsync server
# Defaults to 5
#
# == Dependencies
#
# Class['swift']
#
# == Examples
#
# == Authors
#
# Dan Bode dan@puppetlabs.com
#
# == Copyright
#
# Copyright 2011 Puppetlabs Inc, unless otherwise noted.
#
class swift::ringserver(
$local_net_ip,
$max_connections = 5
) {
include ::swift::deps
Class['swift::ringbuilder'] -> Class['swift::ringserver']
if !defined(Class['rsync::server']) {
class { '::rsync::server':
use_xinetd => true,
address => $local_net_ip,
use_chroot => 'no',
}
}
rsync::server::module { 'swift_server':
path => '/etc/swift',
lock_file => '/var/lock/swift_server.lock',
uid => 'swift',
gid => 'swift',
max_connections => $max_connections,
read_only => true,
}
}