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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
|
# File 'modules/snapshot/manifests/dumps/dblists.pp', line 1
class snapshot::dumps::dblists {
$enwiki = ['enwiki']
$enwiki_dblist = join($enwiki, "\n")
$wikidatawiki = ['wikidatawiki']
$wikidatawiki_dblist = join($wikidatawiki, "\n")
$bigwikis = ['arwiki', 'dewiki', 'commonswiki', 'frwiki', 'eswiki', 'hewiki',
'huwiki', 'itwiki', 'jawiki', 'kowiki', 'metawiki', 'nlwiki', 'plwiki',
'ptwiki', 'ruwiki', 'svwiki', 'ukwiki', 'viwiki', 'zhwiki']
$bigwikis_dblist = join($bigwikis, "\n")
# for testing in deployment-prep
$labs_bigwikis = ['enwiki', 'simplewiki', 'wikidatawiki']
$labs_bigwikis_dblist = join($labs_bigwikis, "\n")
# labswiki(s) can't be dumped from snapshot hosts
$excludewikis = ['labswiki', 'labtestwiki']
$excludewikis_dblist = join($excludewikis, "\n")
$skip_dblist = "${enwiki_dblist}\n${wikidatawiki_dblist}\n${bigwikis_dblist}\n${excludewikis_dblist}"
$skip_labs_dblist = $labs_bigwikis_dblist
$skipnone_dblist = ''
$globalusage_dblist = 'commonswiki'
$dblistsdir = $snapshot::dumps::dirs::dblistsdir
file { "${dblistsdir}/enwiki.dblist":
ensure => 'present',
path => "${dblistsdir}/enwiki.dblist",
mode => '0644',
owner => 'root',
group => 'root',
content => "${enwiki_dblist}\n",
}
file { "${dblistsdir}/wikidatawiki.dblist":
ensure => 'present',
path => "${dblistsdir}/wikidatawiki.dblist",
mode => '0644',
owner => 'root',
group => 'root',
content => "${wikidatawiki_dblist}\n",
}
file { "${dblistsdir}/bigwikis.dblist":
ensure => 'present',
path => "${dblistsdir}/bigwikis.dblist",
mode => '0644',
owner => 'root',
group => 'root',
content => "${bigwikis_dblist}\n",
}
file { "${dblistsdir}/bigwikis-labs.dblist":
ensure => 'present',
path => "${dblistsdir}/bigwikis-labs.dblist",
mode => '0644',
owner => 'root',
group => 'root',
content => "${labs_bigwikis_dblist}\n",
}
file { "${dblistsdir}/skip.dblist":
ensure => 'present',
path => "${dblistsdir}/skip.dblist",
mode => '0644',
owner => 'root',
group => 'root',
content => "${skip_dblist}\n",
}
file { "${dblistsdir}/skip-labs.dblist":
ensure => 'present',
path => "${dblistsdir}/skip-labs.dblist",
mode => '0644',
owner => 'root',
group => 'root',
content => "${skip_labs_dblist}\n",
}
file { "${dblistsdir}/skipmonitor.dblist":
ensure => 'present',
path => "${dblistsdir}/skipmonitor.dblist",
mode => '0644',
owner => 'root',
group => 'root',
content => "${excludewikis_dblist}\n",
}
file { "${dblistsdir}/skipnone.dblist":
ensure => 'present',
path => "${dblistsdir}/skipnone.dblist",
mode => '0644',
owner => 'root',
group => 'root',
content => "${skipnone_dblist}\n",
}
file { "${dblistsdir}/globalusage.dblist":
ensure => 'present',
path => "${dblistsdir}/globalusage.dblist",
mode => '0644',
owner => 'root',
group => 'root',
content => "${globalusage_dblist}\n",
}
$warning = "The files in this directory are maintained by puppet!\n"
$location = "puppet:///modules/snapshot/dumps/dblists.pp\n"
file { "${dblistsdir}/README":
ensure => 'present',
path => "${dblistsdir}/README",
mode => '0644',
owner => 'root',
group => 'root',
content => "${warning}${location}",
}
}
|