Skip to content

Commit

Permalink
restructure module so all classes for the inheritance hierarchy puref…
Browse files Browse the repository at this point in the history
…tpd -> pureftpd::params -> pureftpd::<foo>
  • Loading branch information
Joshua Hoblitt committed Jan 23, 2013
1 parent 12b5798 commit 1296a7b
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 12 deletions.
8 changes: 1 addition & 7 deletions manifests/config.pp
Original file line number Diff line number Diff line change
Expand Up @@ -115,13 +115,7 @@
$tls = false,
$ipv4only = false,
$ipv6only = false,

$use_selinux = false,
){

class { 'pureftpd':
use_selinux => $use_selinux
}
) inherits pureftpd::params {

$default_auth = 'unix'

Expand Down
9 changes: 7 additions & 2 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@
#
class pureftpd (
$use_selinux=false
){
include pureftpd::params, pureftpd::install, pureftpd::service
) {
include pureftpd::install, pureftpd::config, pureftpd::service

Class[ 'pureftpd::install' ] ->
Class[ 'pureftpd::config' ] ->
Class[ 'pureftpd::service' ] ->
Class[ 'pureftpd' ]
}
2 changes: 1 addition & 1 deletion manifests/install.pp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
#
# 5Ub-Z3r0
#
class pureftpd::install {
class pureftpd::install inherits pureftpd::params {
package { $pureftpd::params::package_name:
ensure => present,
}
Expand Down
2 changes: 1 addition & 1 deletion manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#
# 5Ub-Z3r0
#
class pureftpd::params {
class pureftpd::params inherits pureftpd {
case $::osfamily {
'RedHat':{
$package_name = $pureftpd::use_selinux ?{
Expand Down
2 changes: 1 addition & 1 deletion manifests/service.pp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#
# 5Ub-Z3r0
#
class pureftpd::service {
class pureftpd::service inherits pureftpd::params {
service { $pureftpd::params::service_name:
ensure => running,
enable => true,
Expand Down

0 comments on commit 1296a7b

Please sign in to comment.