puppet: move to meta-stx-cloud
Most of the puppet configuration is related to cloud configuration Signed-off-by: Saul Wold <sgw@linux.intel.com>
This commit is contained in:
committed by
babak sarashki
parent
60e40ce807
commit
4d9fced3b1
@@ -0,0 +1,116 @@
|
||||
From 7430149d3a7f1ab9f93ec863e55cdf6d96cd4f06 Mon Sep 17 00:00:00 2001
|
||||
From: Al Bailey <al.bailey@windriver.com>
|
||||
Date: Tue, 7 Jun 2016 10:22:23 -0400
|
||||
Subject: [PATCH] puppet-dnsmasq Kilo quilt patches
|
||||
|
||||
---
|
||||
packstack/puppet/modules/dnsmasq/manifests/init.pp | 8 ++++++++
|
||||
packstack/puppet/modules/dnsmasq/manifests/params.pp | 7 +++++--
|
||||
packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb | 9 ++++++---
|
||||
3 files changed, 19 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/packstack/puppet/modules/dnsmasq/manifests/init.pp b/packstack/puppet/modules/dnsmasq/manifests/init.pp
|
||||
index 176bec7..c61fd94 100644
|
||||
--- a/packstack/puppet/modules/dnsmasq/manifests/init.pp
|
||||
+++ b/packstack/puppet/modules/dnsmasq/manifests/init.pp
|
||||
@@ -258,6 +258,13 @@
|
||||
# If you don't want dnsmasq to read /etc/hosts, set this to true.
|
||||
# Default: false
|
||||
#
|
||||
+# [*dhcp_hostsfile*]
|
||||
+# Read DHCP host information from the specified file. The file contains
|
||||
+# information about one host per line. The format of a line is the same
|
||||
+# as text to the right of '=' in --dhcp-host. The advantage of storing
|
||||
+# DHCP host information in this file is that it can be changed without
|
||||
+# re-starting dnsmasq: the file will be re-read when dnsmasq receives SIGHUP.
|
||||
+#
|
||||
# [*addn_hosts*]
|
||||
# If you want dnsmasq to read another file/s, as well as /etc/hosts, use this.
|
||||
# It can be an array of files to read. See next option to manage these files with
|
||||
@@ -457,6 +464,7 @@ class dnsmasq (
|
||||
$no_poll = params_lookup( 'no_poll' ),
|
||||
$bind_interfaces = params_lookup( 'bind_interfaces' ),
|
||||
$no_hosts = params_lookup( 'no_hosts' ),
|
||||
+ $dhcp_hostsfile = params_lookup( 'dhcp_hostsfile' ),
|
||||
$addn_hosts = params_lookup( 'addn_hosts' ),
|
||||
$addn_hosts_dir = params_lookup( 'addn_hosts_dir' ),
|
||||
$expand_hosts = params_lookup( 'expand_hosts' ),
|
||||
diff --git a/packstack/puppet/modules/dnsmasq/manifests/params.pp b/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
index 5b8f02d..6dd5b96 100644
|
||||
--- a/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
+++ b/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
@@ -38,6 +38,7 @@ class dnsmasq::params {
|
||||
|
||||
$process_user = $::operatingsystem ? {
|
||||
/(?i:Debian|Ubuntu|Mint)/ => 'dnsmasq',
|
||||
+ /(?i:wrlinux)/ => 'root',
|
||||
default => 'nobody',
|
||||
}
|
||||
|
||||
@@ -62,7 +63,7 @@ class dnsmasq::params {
|
||||
}
|
||||
|
||||
$config_file_init = $::operatingsystem ? {
|
||||
- /(?i:Debian|Ubuntu|Mint)/ => '/etc/default/dnsmasq',
|
||||
+ /(?i:Debian|Ubuntu|Mint|wrlinux)/ => '/etc/default/dnsmasq',
|
||||
default => '/etc/sysconfig/dnsmasq',
|
||||
}
|
||||
|
||||
@@ -90,6 +91,7 @@ class dnsmasq::params {
|
||||
$no_poll = false
|
||||
$bind_interfaces = false
|
||||
$no_hosts = false
|
||||
+ $dhcp_hostsfile = ''
|
||||
$addn_hosts = ''
|
||||
$addn_hosts_dir = ''
|
||||
$expand_hosts = false
|
||||
@@ -115,6 +117,7 @@ class dnsmasq::params {
|
||||
}
|
||||
$mx_target = ''
|
||||
$localmx = false
|
||||
+ $selfmx = false
|
||||
$server = ''
|
||||
$local = ''
|
||||
$address = ''
|
||||
@@ -151,7 +154,7 @@ class dnsmasq::params {
|
||||
$version = 'present'
|
||||
$absent = false
|
||||
$disable = false
|
||||
- $disableboot = false
|
||||
+ $disableboot = true
|
||||
|
||||
### General module variables that can have a site or per module default
|
||||
$monitor = false
|
||||
diff --git a/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb b/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb
|
||||
index 7bc4a03..ea5aa01 100644
|
||||
--- a/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb
|
||||
+++ b/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb
|
||||
@@ -3,12 +3,12 @@
|
||||
<% if scope.lookupvar('dnsmasq::port') != '' -%>
|
||||
port=<%= scope.lookupvar('dnsmasq::port') %>
|
||||
<% end -%>
|
||||
-<% if scope.lookupvar('dnsmasq::bool_domain_need') -%>
|
||||
-domain-needed
|
||||
-<% end -%>
|
||||
<% if scope.lookupvar('dnsmasq::bool_bogus_priv') -%>
|
||||
bogus-priv
|
||||
<% end -%>
|
||||
+<% if scope.lookupvar('dnsmasq::bool_domain_needed') -%>
|
||||
+domain-needed
|
||||
+<% end -%>
|
||||
<% if scope.lookupvar('dnsmasq::bool_filterwin2k') -%>
|
||||
filterwin2k
|
||||
<% end -%>
|
||||
@@ -33,6 +33,9 @@ bind-interfaces
|
||||
<% if scope.lookupvar('dnsmasq::bool_no_hosts') -%>
|
||||
no-hosts
|
||||
<% end -%>
|
||||
+<% if scope.lookupvar('dnsmasq::dhcp_hostsfile') != '' -%>
|
||||
+dhcp-hostsfile=<%= scope.lookupvar('dnsmasq::dhcp_hostsfile') %>
|
||||
+<% end -%>
|
||||
<% if scope.lookupvar('dnsmasq::bool_expand_hosts') -%>
|
||||
expand-hosts
|
||||
<% end -%>
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
From b8308a495f853d066c5c0e5d2257a070b033f626 Mon Sep 17 00:00:00 2001
|
||||
From: Kam Nasim <kam.nasim@windriver.com>
|
||||
Date: Tue, 5 Jul 2016 16:46:28 -0400
|
||||
Subject: [PATCH] CGTS-4280: Fixing mismatched permission on dnsmasq.conf which
|
||||
was set to 0640 when created from config_controller (controller-0) but was at
|
||||
0644 on controller-1 through application of this manifest.
|
||||
|
||||
---
|
||||
packstack/puppet/modules/dnsmasq/manifests/params.pp | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/packstack/puppet/modules/dnsmasq/manifests/params.pp b/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
index 6dd5b96..6129b57 100644
|
||||
--- a/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
+++ b/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
@@ -51,7 +51,7 @@ class dnsmasq::params {
|
||||
}
|
||||
|
||||
$config_file_mode = $::operatingsystem ? {
|
||||
- default => '0644',
|
||||
+ default => '0640',
|
||||
}
|
||||
|
||||
$config_file_owner = $::operatingsystem ? {
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@@ -0,0 +1,62 @@
|
||||
From 017e2ed0c664fb8689f6a9c4352db740c2c39725 Mon Sep 17 00:00:00 2001
|
||||
From: Don Penney <don.penney@windriver.com>
|
||||
Date: Thu, 15 Sep 2016 16:49:48 -0400
|
||||
Subject: [PATCH] Support management of tftp_max option
|
||||
|
||||
---
|
||||
packstack/puppet/modules/dnsmasq/manifests/init.pp | 4 ++++
|
||||
packstack/puppet/modules/dnsmasq/manifests/params.pp | 1 +
|
||||
packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb | 3 +++
|
||||
3 files changed, 8 insertions(+)
|
||||
|
||||
diff --git a/packstack/puppet/modules/dnsmasq/manifests/init.pp b/packstack/puppet/modules/dnsmasq/manifests/init.pp
|
||||
index c61fd94..b66ac17 100644
|
||||
--- a/packstack/puppet/modules/dnsmasq/manifests/init.pp
|
||||
+++ b/packstack/puppet/modules/dnsmasq/manifests/init.pp
|
||||
@@ -328,6 +328,9 @@
|
||||
# Enable dnsmasq's built-in TFTP server
|
||||
# Default: false
|
||||
#
|
||||
+# [*tftp_max*]
|
||||
+# Max tftp connections
|
||||
+#
|
||||
# [*tftp_secure*]
|
||||
# Make the TFTP server more secure: with this set, only files owned by
|
||||
# the user dnsmasq is running as will be send over the net.
|
||||
@@ -476,6 +479,7 @@ class dnsmasq (
|
||||
$pxe_prompt_timeout = params_lookup( 'pxe_prompt_timeout' ),
|
||||
$pxe_service = params_lookup( 'pxe_service' ),
|
||||
$enable_tftp = params_lookup( 'enable_tftp' ),
|
||||
+ $tftp_max = params_lookup( 'tftp_max' ),
|
||||
$tftp_secure = params_lookup( 'tftp_secure' ),
|
||||
$tftp_root = params_lookup( 'tftp_root' ),
|
||||
$dhcp_lease_max = params_lookup( 'dhcp_lease_max' ),
|
||||
diff --git a/packstack/puppet/modules/dnsmasq/manifests/params.pp b/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
index 6129b57..845e91e 100644
|
||||
--- a/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
+++ b/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
@@ -103,6 +103,7 @@ class dnsmasq::params {
|
||||
$pxe_prompt_timeout = '60'
|
||||
$pxe_service = ''
|
||||
$enable_tftp = false
|
||||
+ $tftp_max = ''
|
||||
$tftp_secure = false
|
||||
$tftp_root = ''
|
||||
$dhcp_lease_max = ''
|
||||
diff --git a/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb b/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb
|
||||
index ea5aa01..6a6cbdf 100644
|
||||
--- a/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb
|
||||
+++ b/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb
|
||||
@@ -60,6 +60,9 @@ pxe-service=<%= scope.lookupvar('dnsmasq::pxe_service') %>
|
||||
<% if scope.lookupvar('dnsmasq::bool_enable_tftp') -%>
|
||||
enable-tftp
|
||||
<% end -%>
|
||||
+<% if scope.lookupvar('dnsmasq::tftp_max') != '' -%>
|
||||
+tftp-max=<%= scope.lookupvar('dnsmasq::tftp_max') %>
|
||||
+<% end -%>
|
||||
<% if scope.lookupvar('dnsmasq::bool_tftp_secure') -%>
|
||||
tftp-secure
|
||||
<% end -%>
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@@ -0,0 +1,72 @@
|
||||
From 35fa3c673307db2ebed20c952817608fadd26fa6 Mon Sep 17 00:00:00 2001
|
||||
From: Tao Liu <tao.liu@windriver.com>
|
||||
Date: Thu, 22 Jun 2017 16:33:29 -0400
|
||||
Subject: [PATCH 1/1] Enable clear the DNS cache on reload
|
||||
|
||||
---
|
||||
packstack/puppet/modules/dnsmasq/manifests/init.pp | 7 +++++++
|
||||
packstack/puppet/modules/dnsmasq/manifests/params.pp | 1 +
|
||||
packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb | 3 +++
|
||||
3 files changed, 11 insertions(+)
|
||||
|
||||
diff --git a/packstack/puppet/modules/dnsmasq/manifests/init.pp b/packstack/puppet/modules/dnsmasq/manifests/init.pp
|
||||
index b66ac17..93276bb 100644
|
||||
--- a/packstack/puppet/modules/dnsmasq/manifests/init.pp
|
||||
+++ b/packstack/puppet/modules/dnsmasq/manifests/init.pp
|
||||
@@ -211,6 +211,11 @@
|
||||
# bringing up the link unnecessarily.
|
||||
# Default: true
|
||||
#
|
||||
+# [*clear_on_reload*]
|
||||
+# Whenever /etc/resolv.conf is re-read or the upstream servers are set via
|
||||
+# DBus, clear the DNS cache.
|
||||
+# Default: true
|
||||
+#
|
||||
# [*filterwin2k*]
|
||||
# Uncomment this to filter useless windows-originated DNS requests
|
||||
# which can trigger dial-on-demand links needlessly.
|
||||
@@ -460,6 +465,7 @@ class dnsmasq (
|
||||
$protocol = params_lookup( 'protocol' ),
|
||||
$domain_needed = params_lookup( 'domain_needed' ),
|
||||
$bogus_priv = params_lookup( 'bogus_priv' ),
|
||||
+ $clear_on_reload = params_lookup( 'clear_on_reload' ),
|
||||
$filterwin2k = params_lookup( 'filterwin2k' ),
|
||||
$resolv_file = params_lookup( 'resolv_file' ),
|
||||
$strict_order = params_lookup( 'strict_order' ),
|
||||
@@ -531,6 +537,7 @@ class dnsmasq (
|
||||
|
||||
$bool_domain_needed=any2bool($domain_needed)
|
||||
$bool_bogus_priv=any2bool($bogus_priv)
|
||||
+ $bool_clear_on_reload=any2bool($clear_on_reload)
|
||||
$bool_filterwin2k=any2bool($filterwin2k)
|
||||
$bool_strict_order=any2bool($strict_order)
|
||||
$bool_no_resolv=any2bool($no_resolv)
|
||||
diff --git a/packstack/puppet/modules/dnsmasq/manifests/params.pp b/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
index 845e91e..4d8e70a 100644
|
||||
--- a/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
+++ b/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
@@ -84,6 +84,7 @@ class dnsmasq::params {
|
||||
|
||||
$domain_needed = true
|
||||
$bogus_priv = true
|
||||
+ $clear_on_reload = true
|
||||
$filterwin2k = false
|
||||
$resolv_file = ''
|
||||
$strict_order = false
|
||||
diff --git a/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb b/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb
|
||||
index bb8d941..109b768 100644
|
||||
--- a/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb
|
||||
+++ b/packstack/puppet/modules/dnsmasq/templates/dnsmasq.conf.erb
|
||||
@@ -9,6 +9,9 @@ bogus-priv
|
||||
<% if scope.lookupvar('dnsmasq::bool_domain_needed') -%>
|
||||
domain-needed
|
||||
<% end -%>
|
||||
+<% if scope.lookupvar('dnsmasq::bool_clear_on_reload') -%>
|
||||
+clear-on-reload
|
||||
+<% end -%>
|
||||
<% if scope.lookupvar('dnsmasq::bool_filterwin2k') -%>
|
||||
filterwin2k
|
||||
<% end -%>
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@@ -0,0 +1,22 @@
|
||||
diff --git a/packstack/puppet/modules/dnsmasq/manifests/params.pp b/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
index 4d8e70a..b978224 100644
|
||||
--- a/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
+++ b/packstack/puppet/modules/dnsmasq/manifests/params.pp
|
||||
@@ -38,7 +38,7 @@ class dnsmasq::params {
|
||||
|
||||
$process_user = $::operatingsystem ? {
|
||||
/(?i:Debian|Ubuntu|Mint)/ => 'dnsmasq',
|
||||
- /(?i:wrlinux)/ => 'root',
|
||||
+ /(?i:wrlinux|poky-stx)/ => 'root',
|
||||
default => 'nobody',
|
||||
}
|
||||
|
||||
@@ -63,7 +63,7 @@ class dnsmasq::params {
|
||||
}
|
||||
|
||||
$config_file_init = $::operatingsystem ? {
|
||||
- /(?i:Debian|Ubuntu|Mint|wrlinux)/ => '/etc/default/dnsmasq',
|
||||
+ /(?i:Debian|Ubuntu|Mint|wrlinux|poky-stx)/ => '/etc/default/dnsmasq',
|
||||
default => '/etc/sysconfig/dnsmasq',
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user