projects
/
mirror
/
dsa-puppet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
ded0c1d
)
Make bacula DB a parameter and template variable again
author
Peter Palfrader
<peter@palfrader.org>
Tue, 24 Sep 2019 06:34:39 +0000
(08:34 +0200)
committer
Peter Palfrader
<peter@palfrader.org>
Tue, 24 Sep 2019 06:34:39 +0000
(08:34 +0200)
data/common.yaml
patch
|
blob
|
history
modules/bacula/manifests/director.pp
patch
|
blob
|
history
modules/bacula/manifests/init.pp
patch
|
blob
|
history
modules/bacula/templates/bacula-dir.conf.erb
patch
|
blob
|
history
diff --git
a/data/common.yaml
b/data/common.yaml
index
f5c4b7f
..
78b0551
100644
(file)
--- a/
data/common.yaml
+++ b/
data/common.yaml
@@
-7,14
+7,14
@@
lookup_options:
apt::sources::debian::location:
merge: unique
apt::sources::debian::location:
merge: unique
-# class parameters
+# == class parameters
+#####################
resolv::nameservers: []
resolv::searchpaths: ['debian.org']
staticsync::user: 'staticsync'
staticsync::basedir: '/srv/static.debian.org'
exim::smarthost: 'mailout.debian.org'
postfix::smarthost: 'mailout.debian.org'
resolv::nameservers: []
resolv::searchpaths: ['debian.org']
staticsync::user: 'staticsync'
staticsync::basedir: '/srv/static.debian.org'
exim::smarthost: 'mailout.debian.org'
postfix::smarthost: 'mailout.debian.org'
-
roles::dns_primary::allow_access:
# easydns
- '64.68.200.91'
roles::dns_primary::allow_access:
# easydns
- '64.68.200.91'
@@
-30,8
+30,14
@@
roles::dns_primary::allow_access:
- '194.146.105.25'
- '2a01:3f0:0:27::24'
- '2a01:3f0:0:28::25'
- '194.146.105.25'
- '2a01:3f0:0:27::24'
- '2a01:3f0:0:28::25'
+# bacula
+#
+bacula::director::bacula_db_address: 'postgresql-manda-01.debian.org'
+bacula::director::bacula_db_port: 5432
+
-# other variables
+# == other variables
+#####################
allow_dns_query: []
role_config__mirrors:
mirror_basedir_prefix: '/srv/mirrors/'
allow_dns_query: []
role_config__mirrors:
mirror_basedir_prefix: '/srv/mirrors/'
diff --git
a/modules/bacula/manifests/director.pp
b/modules/bacula/manifests/director.pp
index
b4e0105
..
daa0d6b
100644
(file)
--- a/
modules/bacula/manifests/director.pp
+++ b/
modules/bacula/manifests/director.pp
@@
-1,5
+1,11
@@
# our bacula director
# our bacula director
-class bacula::director inherits bacula {
+#
+# @param bacula_db_address hostname of the postgres server for the catalog DB
+# @param bacula_db_port port of the postgres server for the catalog DB
+class bacula::director(
+ String $bacula_db_address = 'postgresql-manda-01.debian.org',
+ Integer $bacula_db_port = 5432,
+) inherits bacula {
ensure_packages ( [
'bacula-director-pgsql',
ensure_packages ( [
'bacula-director-pgsql',
diff --git
a/modules/bacula/manifests/init.pp
b/modules/bacula/manifests/init.pp
index
7649388
..
128063f
100644
(file)
--- a/
modules/bacula/manifests/init.pp
+++ b/
modules/bacula/manifests/init.pp
@@
-16,8
+16,6
@@
class bacula (
String $bacula_storage_address = 'storace.debian.org',
Integer $bacula_storage_port = 9103,
Integer $bacula_client_port = 9102,
String $bacula_storage_address = 'storace.debian.org',
Integer $bacula_storage_port = 9103,
Integer $bacula_client_port = 9102,
- String $bacula_db_address = 'danzi.debian.org',
- Integer $bacula_db_port = 5433,
String $bacula_backup_path = '/srv/bacula',
String $bacula_backup_path = '/srv/bacula',
diff --git
a/modules/bacula/templates/bacula-dir.conf.erb
b/modules/bacula/templates/bacula-dir.conf.erb
index
d3835be
..
8d06dea
100644
(file)
--- a/
modules/bacula/templates/bacula-dir.conf.erb
+++ b/
modules/bacula/templates/bacula-dir.conf.erb
@@
-124,8
+124,8
@@
Schedule {
Catalog {
Name = MyCatalog
dbname = bacula;
Catalog {
Name = MyCatalog
dbname = bacula;
- dbport =
5432
;
- dbaddress =
postgresql-manda-01.debian.org
;
+ dbport =
<%= @bacula_db_port %>
;
+ dbaddress =
<%= @bacula_db_address %>
;
dbsslmode = verify-ca;
dbsslca = /etc/ssl/debian/certs/ca.crt;
dbuser = "bacula";
dbsslmode = verify-ca;
dbsslca = /etc/ssl/debian/certs/ca.crt;
dbuser = "bacula";