Skip to content

Commit 438fede

Browse files
committed
add initial configs for setting tls cert
1 parent 0ebd990 commit 438fede

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

manifests/common/dbatools_ps.pp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# @summary Installs the DBA Tools powershell module
2+
#
3+
class sqlserver::common::dbatools_ps () {
4+
require chocolatey
5+
package { 'dbatools':
6+
ensure => latest,
7+
provider => chocolatey,
8+
}
9+
}

manifests/common/set_tls_cert.pp

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# @summary Set's the TLS certificate for an instance
2+
#
3+
# @param certificate_thumbprint
4+
# The thumbprint of the certificate in the LocalMachine\My certificate store.
5+
# It's CN MUST match the servers FQDN. It can optionally have additional SANs
6+
#
7+
# @param instance_name
8+
# The name of the SQL Instance to set the certificate on
9+
#
10+
define sqlserver::common::set_tls_cert (
11+
String $certificate_thumbprint,
12+
String $instance_name = $title,
13+
) {
14+
require sqlserver::common::dbatools_ps
15+
}

0 commit comments

Comments
 (0)