Skip to content

Commit

Permalink
Merge 0955646 into 31b702d
Browse files Browse the repository at this point in the history
  • Loading branch information
genebean committed Nov 15, 2019
2 parents 31b702d + 0955646 commit 87f1a44
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 7 deletions.
5 changes: 3 additions & 2 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -142,10 +142,11 @@
$https_proxy = $mrepo::params::https_proxy,
Integer $priority = $mrepo::params::priority,
Integer $port = $mrepo::params::port,
String $createrepo_options = $mrepo::params::createrepo_options,
$selinux_context = $mrepo::params::selinux_context,
$service_enable = $mrepo::params::service_enable,
$service_manage = $mrepo::params::service_manage,
) inherits ::mrepo::params {
) inherits mrepo::params {

if $rhn {
assert_type(String[1], $rhn_username)
Expand All @@ -156,7 +157,7 @@
# If undefined and selinux is present and not disabled, use selinux.
case $mrepo::selinux {
undef: {
case $::selinux {
case $selinux {
'enforcing', 'permissive': {
$use_selinux = true
}
Expand Down
1 change: 1 addition & 0 deletions manifests/package.pp
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@
$mailto = $mrepo::mailto
$http_proxy = $mrepo::http_proxy
$https_proxy = $mrepo::https_proxy
$createrepo_options = $mrepo::createrepo_options

file { '/etc/mrepo.conf':
ensure => present,
Expand Down
7 changes: 3 additions & 4 deletions manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,7 @@
#
# Copyright 2011 Puppet Labs unless otherwise noted
#
class mrepo::params
{

class mrepo::params {
$src_root = '/var/mrepo'
$www_root = '/var/www/mrepo'
$www_servername = 'mrepo'
Expand All @@ -38,8 +36,9 @@
$https_proxy = ''
$priority = 10
$port = 80
$createrepo_options = ''
$selinux_context = 'system_u:object_r:httpd_sys_content_t'
$service_enable = true
$service_manage = false

}

3 changes: 3 additions & 0 deletions templates/mrepo.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ srcdir = <%= @src_root %>
wwwdir = <%= @www_root %>
confdir = /etc/mrepo.conf.d

<% if not @createrepo_options.empty? -%>
createrepo-options = <%= @createrepo_options %>
<% end -%>
<% if not @http_proxy.empty? -%>
http_proxy = <%= @http_proxy %>
<% end -%>
Expand Down
2 changes: 1 addition & 1 deletion types/arch.pp
Original file line number Diff line number Diff line change
@@ -1 +1 @@
type Mrepo::Arch = Enum['i386', 'i586', 'x86_64', 'ppc', 's390', 's390x', 'ia64']
type Mrepo::Arch = Enum['i386', 'i586', 'x86_64', 'ppc', 'ppc64le', 's390', 's390x', 'ia64']

0 comments on commit 87f1a44

Please sign in to comment.