File tree Expand file tree Collapse file tree 12 files changed +77
-10
lines changed Expand file tree Collapse file tree 12 files changed +77
-10
lines changed Original file line number Diff line number Diff line change @@ -123,4 +123,15 @@ Vagrant.configure("2") do |config|
123123 provider . vm . box_url = CENTOS_9_BOX_URL
124124 end
125125 end
126+
127+ config . vm . define "repo-deb" do |override |
128+ override . vm . hostname = "repo-deb"
129+ override . vm . box = "centos/stream9"
130+
131+ override . vm . provider "libvirt" do |libvirt , provider |
132+ libvirt . memory = "2048"
133+ libvirt . machine_virtual_size = 40
134+ provider . vm . box_url = CENTOS_9_BOX_URL
135+ end
136+ end
126137end
Original file line number Diff line number Diff line change 11---
22stable_release : ' 3.11'
33profiles::web::stable : ' %{alias("stable_release")}'
4+ profiles::repo::deb::stable : ' %{alias("stable_release")}'
45
56backup_servicename : ' backups.theforeman.org'
67backup_username : ' backup-%{facts.networking.hostname}'
Original file line number Diff line number Diff line change @@ -22,4 +22,6 @@ profiles::jenkins::node::swap_size_mb: 0
2222
2323profiles::web::https : false
2424
25+ profiles::repo::deb::https : false
26+
2527redmine::https : false
Original file line number Diff line number Diff line change 4141 include profiles::base
4242 include profiles::web
4343}
44+
45+ node /^repo-deb\d+\.[a-z]+\.theforeman\.org$/ {
46+ include profiles::base
47+ include profiles::repo::deb
48+ }
Original file line number Diff line number Diff line change 11# @summary install freight
22class freight {
3- if $facts [' os' ][' family' ] == ' Debian' {
4- apt::source { 'freight' :
5- location => ' http://build.openvpn.net/debian/freight_team' ,
6- repos => ' main' ,
7- key => {
8- id => ' 30EBF4E73CCE63EEE124DD278E6DA8B4E158C569' ,
9- source => ' https://swupdate.openvpn.net/repos/repo-public.gpg' ,
10- },
11- before => Package[' freight' ],
3+ if $facts [' os' ][' family' ] == ' RedHat' and $facts [' os' ][' release' ][' major' ] == ' 9' {
4+ class {'epel' :
5+ epel_testing_enabled => true ,
6+ before => Package[' freight' ],
127 }
138 }
149
Original file line number Diff line number Diff line change 55 Stdlib::Absolutepath $stagedir ,
66 String $vhost ,
77 Variant[String, Array[String]] $cron_matches ,
8+ String[1] $stable ,
89) {
910 require freight
1011
7778 owner => ' root' ,
7879 group => ' root' ,
7980 mode => ' 0644' ,
80- content => epp(" ${module_name} /${vhost} -HEADER.html.epp" , { ' stable' => $profiles::web:: stable }),
81+ content => epp(" ${module_name} /${vhost} -HEADER.html.epp" , { ' stable' => $stable }),
8182 }
8283 file { "${webdir}/foreman.asc" :
8384 ensure => link,
Original file line number Diff line number Diff line change 1+ # @summary A profile for the debian repo machines
2+ #
3+ # @param stable
4+ # Latest release that users expect
5+ #
6+ # @param https
7+ # Whether to enable HTTPS. This is typically wanted but can only be enabled
8+ # in a 2 pass setup. First Apache needs to run for Letsencrypt to function.
9+ # Then Letsencrypt can be enabled. Also useful to turn off in test setups.
10+ class profiles::repo::deb (
11+ String[1] $stable,
12+ Boolean $https = true ,
13+ ) {
14+ class { 'web' :
15+ https => $https ,
16+ }
17+ contain web
18+
19+ class { 'web::vhost::archivedeb' :
20+ stable => $stable ,
21+ }
22+ contain web::vhost::archivedeb
23+
24+ class { 'web::vhost::deb' :
25+ stable => $stable ,
26+ }
27+ contain web::vhost::deb
28+
29+ class { 'web::vhost::stagingdeb' :
30+ stable => $stable ,
31+ }
32+ contain web::vhost::stagingdeb
33+ }
Original file line number Diff line number Diff line change 2222 }
2323 contain web
2424
25+ class { 'web::vhost::archivedeb' :
26+ stable => $stable ,
27+ }
2528 contain web::vhost::archivedeb
2629
30+ class { 'web::vhost::deb' :
31+ stable => $stable ,
32+ }
2733 contain web::vhost::deb
2834
2935 class { 'web::vhost::debugs' :
3339
3440 contain web::vhost::downloads
3541
42+ class { 'web::vhost::stagingdeb' :
43+ stable => $stable ,
44+ }
3645 contain web::vhost::stagingdeb
3746
3847 class { 'web::vhost::web' :
Original file line number Diff line number Diff line change 11# @summary Set up the archivedeb vhost
22# @api private
33class web::vhost::archivedeb (
4+ String[1] $stable,
45 String $user = ' freightarchive' ,
56 Stdlib::Absolutepath $home = " /home/${user} " ,
67) {
1213 stagedir => " /var/www/${user} " ,
1314 vhost => ' archivedeb' ,
1415 cron_matches => [],
16+ stable => $stable ,
1517 }
1618
1719 secure_ssh::rsync::receiver_setup { $user:
Original file line number Diff line number Diff line change 11# @summary Set up the deb vhost
22# @api private
33class web::vhost::deb (
4+ String[1] $stable,
45 String $user = ' freight' ,
56 Stdlib::Absolutepath $home = " /home/${user} " ,
67) {
1213 stagedir => ' /var/www/freight' ,
1314 vhost => ' deb' ,
1415 cron_matches => [' nightly' , ' scratch' ],
16+ stable => $stable ,
1517 }
1618
1719 # Can't use a standard rsync define here as we need to extend the
You can’t perform that action at this time.
0 commit comments