/[adm]/puppet/deployment/mga_buildsystem/manifests/config.pp
ViewVC logotype

Contents of /puppet/deployment/mga_buildsystem/manifests/config.pp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3208 - (show annotations) (download)
Wed May 29 22:48:30 2013 UTC (10 years, 10 months ago) by boklm
File size: 16496 byte(s)
Disable media.cfg generation for Mageia 1 & 2
1 class mga_buildsystem::config {
2 class { 'buildsystem::var::signbot':
3 keyid => '80420F66',
4 keyemail => "packages@${::domain}",
5 keyname => 'Mageia Packages',
6 }
7
8 class { 'buildsystem::var::groups':
9 packagers => 'mga-packagers',
10 packagers_committers => 'mga-packagers-committers',
11 }
12
13 class { 'buildsystem::var::webstatus' :
14 package_commit_url => 'http://svnweb.mageia.org/packages?view=revision&revision=%d',
15 theme_name => 'mageia',
16 }
17
18 class { 'buildsystem::var::scheduler' :
19 admin_mail => 'mageia-sysadm@mageia.org',
20 build_nodes => {
21 'i586' => [ 'jonund0', 'ecosse0', 'jonund1', 'ecosse1' ],
22 'x86_64' => [ 'ecosse0', 'jonund0', 'ecosse1', 'jonund1' ],
23 },
24 build_nodes_aliases => {
25 'jonund0' => "jonund.${::domain}",
26 'jonund1' => "jonund.${::domain}",
27 'ecosse0' => "ecosse.${::domain}",
28 'ecosse1' => "ecosse.${::domain}",
29 },
30 build_src_node => "valstar",
31 }
32 include buildsystem::var::repository
33 class { 'buildsystem::var::binrepo':
34 uploadmail_from => "root@${::domain}",
35 uploadmail_to => "packages-commits@ml.${::domain}",
36 }
37
38 $svn_hostname = "svn.$::domain"
39 $svn_root_packages = "svn://${svn_hostname}/svn/packages"
40 $svn_root_packages_ssh = "svn+ssh://${svn_hostname}/svn/packages"
41 class { 'buildsystem::var::mgarepo':
42 submit_host => "pkgsubmit.${::domain}",
43 svn_hostname => $svn_hostname,
44 svn_root_packages => $svn_root_packages,
45 svn_root_packages_ssh => $svn_root_packages_ssh,
46 oldurl => "${svn_root_packages_ssh}/misc",
47 conf => {
48 'global' => {
49 'ldap-server' => "ldap.${::domain}",
50 'ldap-base' => "ou=People,${::dc_suffix}",
51 'ldap-filterformat' => '(&(objectClass=inetOrgPerson)(uid=$username))',
52 'ldap-resultformat' => '$cn <$mail>',
53 }
54 }
55 }
56
57 $std_arch = ['i586', 'x86_64']
58 $std_repos = {
59 'release' => {
60 'media_type' => [ 'release' ],
61 'requires' => [],
62 'order' => 0,
63 },
64 'updates' => {
65 'media_type' => [ 'updates' ],
66 'updates_for' => 'release',
67 'requires' => [ 'release' ],
68 'order' => 1,
69 },
70 'updates_testing' => {
71 'media_type' => [ 'testing' ],
72 'noauto' => '1',
73 'requires' => [ 'updates' ],
74 'order' => 2,
75 },
76 'backports' => {
77 'media_type' => [ 'backports' ],
78 'noauto' => '1',
79 'requires' => [ 'updates' ],
80 'order' => 3,
81 },
82 'backports_testing' => {
83 'media_type' => [ 'testing' ],
84 'noauto' => '1',
85 'requires' => [ 'backports' ],
86 'order' => 4,
87 },
88 }
89 $std_medias = {
90 'core' => {
91 'repos' => $std_repos,
92 'media_type' => [ 'official', 'free' ],
93 'order' => 0,
94 },
95 'nonfree' => {
96 'repos' => $std_repos,
97 'media_type' => [ 'official' ],
98 'noauto' => '1',
99 'requires' => [ 'core' ],
100 'order' => 1,
101 },
102 'tainted' => {
103 'repos' => $std_repos,
104 'media_type' => [ 'official' ],
105 'noauto' => '1',
106 'requires' => [ 'core' ],
107 'order' => 2,
108 },
109 }
110 $std_base_media = [ 'core/release', 'core/updates' ]
111 $infra_medias = {
112 'infra' => {
113 'repos' => {
114 'updates' => {
115 'media_type' => [ 'updates' ],
116 'requires' => [ 'release' ],
117 'order' => 0,
118 },
119 },
120 'media_type' => [ 'infra' ],
121 'requires' => [ 'core' ],
122 'order' => 0,
123 },
124 }
125 $std_macros = {
126 'distsuffix' => '.mga',
127 'distribution' => 'Mageia',
128 'vendor' => 'Mageia.Org',
129 '_real_vendor' => 'mageia',
130 }
131 $repo_allow_from = [
132 $::nodes_ipaddr[valstar][ipv6],
133 $::nodes_ipaddr[valstar][ipv4],
134 $::nodes_ipaddr[ecosse][ipv6],
135 $::nodes_ipaddr[ecosse][ipv4],
136 $::nodes_ipaddr[jonund][ipv6],
137 $::nodes_ipaddr[jonund][ipv4],
138 ".${::domain}",
139 '10.42.0',
140 $::nodes_ipaddr[rabbit][ipv4],
141 $::nodes_ipaddr[rabbit][ipv6],
142 ]
143
144 # the list of checks, actions, posts for cauldron in youri-upload
145 $cauldron_youri_upload_targets = {
146 'checks' => [
147 'version',
148 'tag',
149 'acl',
150 'rpmlint',
151 'recency',
152 ],
153 'actions' => [
154 'markrelease',
155 'sign',
156 'install',
157 'link',
158 'unpack_release_notes',
159 'unpack_gfxboot_theme',
160 'unpack_meta_task',
161 'unpack_installer_images',
162 'unpack_installer_images_nonfree',
163 'unpack_installer_stage2',
164 'unpack_installer_advertising',
165 'unpack_installer_rescue',
166 'unpack_syslinux',
167 'archive',
168 'mail',
169 'maintdb',
170 ],
171 'posts' => [
172 'genhdlist2',
173 'clean_rpmsrate',
174 'mirror',
175 ],
176 }
177
178 # the list of checks, actions, posts for stable distros in youri-upload
179 $std_youri_upload_targets = {
180 'checks' => [
181 'version',
182 'tag',
183 'acl',
184 'rpmlint',
185 'recency',
186 ],
187 'actions' => [
188 'sign',
189 'install',
190 'link',
191 'archive',
192 'mail',
193 ],
194 'posts' => [
195 'genhdlist2',
196 'clean_rpmsrate',
197 'mirror',
198 ],
199 }
200
201 # the list of checks, actions, posts for infra distros in youri-upload
202 $infra_youri_upload_targets = {
203 'checks' => [
204 'version',
205 'tag',
206 'acl',
207 'rpmlint',
208 'recency',
209 ],
210 'actions' => [
211 'sign',
212 'install',
213 'link',
214 'archive',
215 ],
216 'posts' => [
217 'genhdlist2',
218 ],
219 }
220
221 # the list of checks, actions, posts for cauldron in youri-todo
222 $cauldron_youri_todo_targets = {
223 'checks' => [
224 'source',
225 'deps',
226 'version',
227 'tag',
228 'acl',
229 'host',
230 'rpmlint',
231 'recency',
232 'queue_recency',
233 ],
234 'actions' => [
235 'send',
236 'rpminfo',
237 ],
238 }
239
240 # the list of checks, actions, posts for stable distros in youri-todo
241 $std_youri_todo_targets = {
242 'checks' => [
243 'source',
244 'version',
245 'tag',
246 'acl',
247 'host',
248 'rpmlint',
249 'recency',
250 'queue_recency',
251 ],
252 'actions' => [
253 'send',
254 'rpminfo',
255 'ulri',
256 ],
257 }
258
259 # the list of checks, actions, posts for infra distros in youri-todo
260 $infra_youri_todo_targets = {
261 'checks' => [
262 'source',
263 'version',
264 'tag',
265 'acl',
266 'rpmlint',
267 'recency',
268 'queue_recency',
269 ],
270 'actions' => [
271 'send',
272 'rpminfo',
273 'ulri',
274 ],
275 }
276
277 # rpmlint check options for mageia <= 2
278 $mga2_rpmlint = {
279 'config' => '/usr/share/rpmlint/config.mga2',
280 'path' => '/usr/bin/mga2-rpmlint',
281 'results' => [
282 'buildprereq-use',
283 'no-description-tag',
284 'no-summary-tag',
285 'non-standard-group',
286 'non-xdg-migrated-menu',
287 'percent-in-conflicts',
288 'percent-in-dependency',
289 'percent-in-obsoletes',
290 'percent-in-provides',
291 'summary-ended-with-dot',
292 'unexpanded-macro',
293 'unknown-lsb-keyword',
294 'malformed-line-in-lsb-comment-block',
295 'empty-%postun',
296 'empty-%post',
297 'invalid-desktopfile',
298 'standard-dir-owned-by-package',
299 'use-tmp-in-%postun',
300 'bogus-variable-use-in-%posttrans',
301 'dir-or-file-in-usr-local',
302 'dir-or-file-in-tmp',
303 'dir-or-file-in-mnt',
304 'dir-or-file-in-opt',
305 'dir-or-file-in-home',
306 'dir-or-file-in-var-local',
307 ],
308 }
309
310 # rpmlint check options for Mageia 3
311 $mga3_rpmlint = {
312 'config' => '/usr/share/rpmlint/config',
313 'path' => '/usr/bin/rpmlint',
314 'results' => [
315 'buildprereq-use',
316 'no-description-tag',
317 'no-summary-tag',
318 'non-standard-group',
319 'non-xdg-migrated-menu',
320 'percent-in-conflicts',
321 'percent-in-dependency',
322 'percent-in-obsoletes',
323 'percent-in-provides',
324 'summary-ended-with-dot',
325 'unexpanded-macro',
326 'unknown-lsb-keyword',
327 'malformed-line-in-lsb-comment-block',
328 'empty-%postun',
329 'empty-%post',
330 'invalid-desktopfile',
331 'standard-dir-owned-by-package',
332 'use-tmp-in-%postun',
333 'bogus-variable-use-in-%posttrans',
334 'dir-or-file-in-usr-local',
335 'dir-or-file-in-tmp',
336 'dir-or-file-in-mnt',
337 'dir-or-file-in-opt',
338 'dir-or-file-in-home',
339 'dir-or-file-in-var-local',
340 'tmpfiles-conf-in-etc',
341 'non-ghost-in-run',
342 'non-ghost-in-var-run',
343 'non-ghost-in-var-lock',
344 'systemd-unit-in-etc',
345 'udev-rule-in-etc',
346 ],
347 }
348
349 # rpmlint check options for cauldron
350 $cauldron_rpmlint = {
351 'config' => '/usr/share/rpmlint/config',
352 'path' => '/usr/bin/rpmlint',
353 'results' => [
354 'buildprereq-use',
355 'no-description-tag',
356 'no-summary-tag',
357 'non-standard-group',
358 'non-xdg-migrated-menu',
359 'percent-in-conflicts',
360 'percent-in-dependency',
361 'percent-in-obsoletes',
362 'percent-in-provides',
363 'summary-ended-with-dot',
364 'unexpanded-macro',
365 'unknown-lsb-keyword',
366 'malformed-line-in-lsb-comment-block',
367 'empty-%postun',
368 'empty-%post',
369 'invalid-desktopfile',
370 'standard-dir-owned-by-package',
371 'use-tmp-in-%postun',
372 'bogus-variable-use-in-%posttrans',
373 'dir-or-file-in-usr-local',
374 'dir-or-file-in-tmp',
375 'dir-or-file-in-mnt',
376 'dir-or-file-in-opt',
377 'dir-or-file-in-home',
378 'dir-or-file-in-var-local',
379 'tmpfiles-conf-in-etc',
380 'non-ghost-in-run',
381 'non-ghost-in-var-run',
382 'non-ghost-in-var-lock',
383 'systemd-unit-in-etc',
384 'udev-rule-in-etc',
385 ],
386 }
387
388 # list of users allowed to submit packages when cauldron is frozen
389 $cauldron_authorized_users = str_join(group_members('mga-release_managers'), '|')
390 $cauldron_version_check = {
391 'authorized_sections' => '^[a-z]+/updates_testing$',
392 'authorized_packages' => '^$',
393 'authorized_arches' => 'none',
394 'authorized_users' => "^${cauldron_authorized_users}\$",
395 'mode' => 'normal',
396 #'mode' => 'version_freeze',
397 #'mode' => 'freeze',
398 }
399
400 # for EOL distributions
401 $frozen_version_check = {
402 'authorized_packages' => 'none_package_authorized',
403 'authorized_sections' => 'none_section_authorized',
404 'authorized_arches' => 'none',
405 'mode' => 'freeze',
406 }
407
408 # for supported stable distributions
409 $std_version_check = {
410 'authorized_packages' => 'none_package_authorized',
411 'authorized_sections' => '^(core|nonfree|tainted)/(updates_testing|backports_testing)$',
412 'authorized_arches' => 'none',
413 'mode' => 'freeze',
414 }
415
416 $infra_authorized_users = str_join(group_members('mga-sysadmin'), '|')
417 $infra_version_check = {
418 'authorized_users' => "^${infra_authorized_users}\$",
419 'mode' => 'freeze',
420 }
421
422 class { 'buildsystem::var::distros':
423 default_distro => 'cauldron',
424 distros => {
425 'cauldron' => {
426 'arch' => $std_arch,
427 'medias' => $std_medias,
428 'base_media' => $std_base_media,
429 'branch' => 'Devel',
430 'version' => '4',
431 'submit_allowed' => "${svn_root_packages}/cauldron",
432 'macros' => $std_macros,
433 'repo_allow_from' => $repo_allow_from,
434 'youri' => {
435 'upload' => {
436 'targets' => $cauldron_youri_upload_targets,
437 'checks' => {
438 'rpmlint' => $cauldron_rpmlint,
439 },
440 },
441 'todo' => {
442 'targets' => $cauldron_youri_todo_targets,
443 'checks' => {
444 'rpmlint' => $cauldron_rpmlint,
445 'version' => $cauldron_version_check,
446 },
447 },
448 },
449 },
450
451 '1' => {
452 'arch' => $std_arch,
453 'no_media_cfg_update' => true,
454 'medias' => $std_medias,
455 'base_media' => $std_base_media,
456 'branch' => 'Official',
457 'version' => '1',
458 'submit_allowed' => "${svn_root_packages}/updates/1",
459 'macros' => $std_macros,
460 'repo_allow_from' => $repo_allow_from,
461 'youri' => {
462 'upload' => {
463 'targets' => $std_youri_upload_targets,
464 'checks' => {
465 'rpmlint' => $mga2_rpmlint,
466 },
467 },
468 'todo' => {
469 'targets' => $std_youri_todo_targets,
470 'checks' => {
471 'rpmlint' => $mga2_rpmlint,
472 'version' => $frozen_version_check,
473 },
474 },
475 },
476 },
477
478 '2' => {
479 'arch' => $std_arch,
480 'no_media_cfg_update' => true,
481 'medias' => $std_medias,
482 'base_media' => $std_base_media,
483 'branch' => 'Official',
484 'version' => '2',
485 'submit_allowed' => "${svn_root_packages}/updates/2",
486 'macros' => $std_macros,
487 'repo_allow_from' => $repo_allow_from,
488 'youri' => {
489 'upload' => {
490 'targets' => $std_youri_upload_targets,
491 'checks' => {
492 'rpmlint' => $mga2_rpmlint,
493 },
494 },
495 'todo' => {
496 'targets' => $std_youri_todo_targets,
497 'checks' => {
498 'rpmlint' => $mga2_rpmlint,
499 'version' => $std_version_check,
500 },
501 },
502 },
503 },
504
505 '3' => {
506 'arch' => $std_arch,
507 'medias' => $std_medias,
508 'base_media' => $std_base_media,
509 'branch' => 'Official',
510 'version' => '3',
511 'submit_allowed' => "${svn_root_packages}/updates/3",
512 'macros' => $std_macros,
513 'repo_allow_from' => $repo_allow_from,
514 'youri' => {
515 'upload' => {
516 'targets' => $std_youri_upload_targets,
517 'checks' => {
518 'rpmlint' => $mga3_rpmlint,
519 },
520 },
521 'todo' => {
522 'targets' => $std_youri_todo_targets,
523 'checks' => {
524 'rpmlint' => $mga3_rpmlint,
525 'version' => $std_version_check,
526 },
527 },
528 },
529 },
530
531 'infra_1' => {
532 'arch' => $std_arch,
533 'medias' => $infra_medias,
534 'base_media' => $std_base_media,
535 'branch' => 'Official',
536 'version' => '1',
537 'submit_allowed' => $svn_root_packages,
538 'macros' => $std_macros,
539 'based_on' => {
540 '1' => {
541 'core' => [ 'release', 'updates' ],
542 },
543 },
544 'youri' => {
545 'upload' => {
546 'targets' => $infra_youri_upload_targets,
547 'checks' => {
548 'rpmlint' => $mga2_rpmlint,
549 },
550 },
551 'todo' => {
552 'targets' => $infra_youri_todo_targets,
553 'checks' => {
554 'rpmlint' => $mga2_rpmlint,
555 'version' => $infra_version_check,
556 },
557 },
558 },
559 },
560
561 'infra_2' => {
562 'arch' => $std_arch,
563 'medias' => $infra_medias,
564 'base_media' => $std_base_media,
565 'branch' => 'Official',
566 'version' => '2',
567 'submit_allowed' => $svn_root_packages,
568 'macros' => $std_macros,
569 'based_on' => {
570 '2' => {
571 'core' => [ 'release', 'updates' ],
572 },
573 },
574 'youri' => {
575 'upload' => {
576 'targets' => $infra_youri_upload_targets,
577 'checks' => {
578 'rpmlint' => $mga2_rpmlint,
579 },
580 },
581 'todo' => {
582 'targets' => $infra_youri_todo_targets,
583 'checks' => {
584 'rpmlint' => $mga2_rpmlint,
585 'version' => $infra_version_check,
586 },
587 },
588 },
589 },
590 }
591 }
592 $checks_tag_options = {
593 'tags' => {
594 'release' => inline_template("<%= std_macros['distsuffix'] %>\\d+"),
595 'distribution' => inline_template("^<%= std_macros['distribution'] %>"),
596 'vendor' => inline_template("^<%= std_macros['vendor'] %>$"),
597 },
598 }
599 class { 'buildsystem::var::youri':
600 packages_archivedir => "${buildsystem::var::scheduler::homedir}/old",
601 youri_conf => {
602 'upload' => {
603 'checks' => {
604 'tag' => {
605 'options' => $checks_tag_options,
606 },
607 'rpmlint' => {
608 'options' => {
609 'results' => [
610 'buildprereq-use',
611 'no-description-tag',
612 'no-summary-tag',
613 'non-standard-group',
614 'non-xdg-migrated-menu',
615 'percent-in-conflicts',
616 'percent-in-dependency',
617 'percent-in-obsoletes',
618 'percent-in-provides',
619 'summary-ended-with-dot',
620 'unexpanded-macro',
621 'unknown-lsb-keyword',
622 'malformed-line-in-lsb-comment-block',
623 'empty-%postun',
624 'empty-%post',
625 'invalid-desktopfile',
626 'standard-dir-owned-by-package',
627 'use-tmp-in-%postun',
628 'bogus-variable-use-in-%posttrans',
629 'dir-or-file-in-usr-local',
630 'dir-or-file-in-tmp',
631 'dir-or-file-in-mnt',
632 'dir-or-file-in-opt',
633 'dir-or-file-in-home',
634 'dir-or-file-in-var-local',
635 ],
636 },
637 },
638 },
639 'actions' => {
640 'mail' => {
641 'options' => {
642 'to' => "changelog@ml.${::domain}",
643 'reply_to' => "mageia-dev@${::domain}",
644 'from' => "buildsystem-daemon@${::domain}",
645 'prefix' => 'RPM',
646 },
647 },
648 },
649 },
650 'todo' => {
651 'checks' => {
652 'tag' => {
653 'options' => $checks_tag_options,
654 },
655 },
656 },
657 }
658 }
659 }

  ViewVC Help
Powered by ViewVC 1.1.30