Skip to content

Commit 319ea41

Browse files
committed
postgresql version >=10 onwards does not require contrib package
1 parent 74a62e9 commit 319ea41

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

manifests/database/postgresql.pp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,11 @@
5959
# Only install pg_trgm extension, if database it is actually managed by the module
6060
if $manage_database {
6161

62-
# get the pg contrib to use pg_trgm extension
63-
class { '::postgresql::server::contrib': }
62+
# from postgresql version 10 onwards, this extension is no longer inside the contrib package, but is being bundled with the postgresql package itself
63+
if (versioncmp($postgres_version, '10') < 0) {
64+
# get the pg contrib to use pg_trgm extension
65+
include postgresql::server::contrib
66+
}
6467

6568
postgresql::server::extension { 'pg_trgm':
6669
database => $database_name,

0 commit comments

Comments
 (0)