-
Notifications
You must be signed in to change notification settings - Fork 0
/
params.pp
83 lines (72 loc) · 2.42 KB
/
params.pp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
# File:: <tt>bontmia-params.pp</tt>
# Author:: Hyacinthe Cartiaux ([email protected])
# Copyright:: Copyright (c) 2013 Hyacinthe Cartiaux
# License:: GPLv3
#
# ------------------------------------------------------------------------------
# = Class: bontmia::params
#
# In this class are defined as variables values that are used in other
# bontmia classes.
# This class should be included, where necessary, and eventually be enhanced
# with support for more OS
#
# == Warnings
#
# /!\ Always respect the style guide available
# here[http://docs.puppetlabs.com/guides/style_guide]
#
# The usage of a dedicated param classe is advised to better deal with
# parametrized classes, see
# http://docs.puppetlabs.com/guides/parameterized_classes.html
#
# [Remember: No empty lines between comments and class definition]
#
class bontmia::params {
######## DEFAULTS FOR VARIABLES USERS CAN SET ##########################
# (Here are set the defaults, provide your custom variables externally)
# (The default used is in the line with '')
###########################################
# ensure the presence (or absence) of bontmia
$ensure = 'present'
$sudo = false
#### MODULE INTERNAL VARIABLES #########
# (Modify to adapt to unsupported OSes)
#######################################
# ensure the presence (or absence) of bontmia
$url = 'https://github.com/hcartiaux/bontmia/archive/v0.18.1.tar.gz'
# ensure the presence (or absence) of bontmia
$install_dir = 'bontmia-0.18.1'
# Log directory
$logdir = $facts['os']['name'] ? {
default => '/var/log/bontmia'
}
$logdir_mode = $facts['os']['name'] ? {
default => '750',
}
$logdir_owner = $facts['os']['name'] ? {
default => 'root',
}
$logdir_group = $facts['os']['name'] ? {
default => 'adm',
}
$configfile = $facts['os']['name'] ? {
default => '/etc/bontmia.conf',
}
$configfile_init = $facts['os']['name'] ? {
/(?i-mx:ubuntu|debian)/ => '/etc/default/bontmia',
default => '/etc/sysconfig/bontmia'
}
$configfile_mode = $facts['os']['name'] ? {
default => '0700',
}
$configfile_owner = $facts['os']['name'] ? {
default => 'root',
}
$configfile_group = $facts['os']['name'] ? {
default => 'root',
}
$bontmia_user = $facts['os']['name'] ? {
default => 'root',
}
}