3
0

Merge branch 'jenkins-build-6' into 'master'

Auto-merge for build 6

See merge request puppet/postgresql_cd!3
This commit is contained in:
2025-09-28 11:52:27 +00:00
3 changed files with 108 additions and 14 deletions

View File

@@ -304,6 +304,78 @@
— —
<div class='inline'> <div class='inline'>
<p>maximum connections the service will accept</p> <p>maximum connections the service will accept</p>
</div>
</li>
<li>
<span class='name'>pl_ssl_enabled</span>
<span class='type'>(<tt>Boolean</tt>)</span>
<em class="default">(defaults to: <tt>false</tt>)</em>
&mdash;
<div class='inline'>
<p>whether SSL is enabled (true) or disabled (false)</p>
</div>
</li>
<li>
<span class='name'>pl_server_crt</span>
<span class='type'>(<tt>String</tt>)</span>
<em class="default">(defaults to: <tt>&#39;server.crt&#39;</tt>)</em>
&mdash;
<div class='inline'>
<p>the name of the server cert</p>
</div>
</li>
<li>
<span class='name'>pl_server_key</span>
<span class='type'>(<tt>String</tt>)</span>
<em class="default">(defaults to: <tt>&#39;server.key&#39;</tt>)</em>
&mdash;
<div class='inline'>
<p>the name of the server key</p>
</div>
</li>
<li>
<span class='name'>pl_ca_crt</span>
<span class='type'>(<tt>String</tt>)</span>
<em class="default">(defaults to: <tt>&#39;root.crt&#39;</tt>)</em>
&mdash;
<div class='inline'>
<p>the name of the CA crt</p>
</div> </div>
</li> </li>
@@ -319,10 +391,6 @@
<pre class="lines"> <pre class="lines">
19
20
21
22
23 23
24 24
25 25
@@ -353,17 +421,25 @@
50 50
51 51
52 52
53</pre> 53
54
55
56
57
58
59
60
61</pre>
</td> </td>
<td> <td>
<pre class="code"><span class="info file"># File 'manifests/params.pp', line 19</span> <pre class="code"><span class="info file"># File 'manifests/params.pp', line 23</span>
class postgresql_cd::params ( class postgresql_cd::params (
String $pl_server_fqdn = undef, String $pl_server_fqdn = undef,
# installation # installation
Array $reqpackages_server = [&#39;postgresql-server&#39;,&#39;postgresql-contrib&#39;], Array $reqpackages_server = [&#39;postgresql-server&#39;,&#39;postgresql-contrib&#39;],
String $reqpackages_client = &#39;postgresql&#39;, String $reqpackages_client = &#39;postgresql&#39;,
String $pkg_ensure = &#39;latest&#39;, String $pkg_ensure = &#39;latest&#39;,
@@ -376,7 +452,11 @@ class postgresql_cd::params (
# main config # main config
String $pl_listen_address = &#39;*&#39;, String $pl_listen_address = &#39;*&#39;,
String $pl_listen_port = &#39;5432&#39;, String $pl_listen_port = &#39;5432&#39;,
String $pl_max_conn = &#39;100&#39;, String $pl_max_conn = &#39;100&#39;,
Boolean $pl_ssl_enabled = false,
String $pl_server_crt = &#39;server.crt&#39;,
String $pl_server_key = &#39;server.key&#39;,
String $pl_ca_crt = &#39;root.crt&#39;,
) { ) {
$fqdn = $facts[&#39;networking&#39;][&#39;fqdn&#39;] $fqdn = $facts[&#39;networking&#39;][&#39;fqdn&#39;]

View File

@@ -14,6 +14,10 @@
# @param [String] pl_listen_address which address should the service listen on # @param [String] pl_listen_address which address should the service listen on
# @param [String] pl_listen_port which port should the service listen on # @param [String] pl_listen_port which port should the service listen on
# @param [String] pl_max_conn maximum connections the service will accept # @param [String] pl_max_conn maximum connections the service will accept
# @param [Boolean] pl_ssl_enabled whether SSL is enabled (true) or disabled (false)
# @param [String] pl_server_crt the name of the server cert
# @param [String] pl_server_key the name of the server key
# @param [String] pl_ca_crt the name of the CA crt
# @summary Class contains all parameters for the postgresql_cd module. # @summary Class contains all parameters for the postgresql_cd module.
############################################################################## ##############################################################################
class postgresql_cd::params ( class postgresql_cd::params (
@@ -21,7 +25,7 @@ class postgresql_cd::params (
String $pl_server_fqdn = undef, String $pl_server_fqdn = undef,
# installation # installation
Array $reqpackages_server = ['postgresql-server','postgresql-contrib'], Array $reqpackages_server = ['postgresql-server','postgresql-contrib'],
String $reqpackages_client = 'postgresql', String $reqpackages_client = 'postgresql',
String $pkg_ensure = 'latest', String $pkg_ensure = 'latest',
@@ -34,7 +38,11 @@ class postgresql_cd::params (
# main config # main config
String $pl_listen_address = '*', String $pl_listen_address = '*',
String $pl_listen_port = '5432', String $pl_listen_port = '5432',
String $pl_max_conn = '100', String $pl_max_conn = '100',
Boolean $pl_ssl_enabled = false,
String $pl_server_crt = 'server.crt',
String $pl_server_key = 'server.key',
String $pl_ca_crt = 'root.crt',
) { ) {
$fqdn = $facts['networking']['fqdn'] $fqdn = $facts['networking']['fqdn']

View File

@@ -95,11 +95,17 @@ max_connections = <%= @pl_max_conn %>
# - SSL - # - SSL -
#ssl = off <% if @pl_ssl_enabled == true -%>
#ssl_ca_file = '' ssl = on
#ssl_cert_file = 'server.crt' ssl_ca_file = '<%= @pl_ca_crt -%>'
ssl_cert_file = '<%= @pl_server_crt -%>'
ssl_key_file = '<%= @pl_server_key -%>'
<% end -%>
<% if @pl_ssl_enabled != true -%>
ssl = off
<% end -%>
#ssl_crl_file = '' #ssl_crl_file = ''
#ssl_key_file = 'server.key'
#ssl_ciphers = 'HIGH:MEDIUM:+3DES:!aNULL' # allowed SSL ciphers #ssl_ciphers = 'HIGH:MEDIUM:+3DES:!aNULL' # allowed SSL ciphers
#ssl_prefer_server_ciphers = on #ssl_prefer_server_ciphers = on
#ssl_ecdh_curve = 'prime256v1' #ssl_ecdh_curve = 'prime256v1'