Description: Fix compat with latest puppetserver
 Some facts and types have gone, let's use what currently still exists.
Author: Thomas Goirand <zigo@debian.org>
Forwarded: not-needed
Last-Update: 2025-05-13

--- puppet-module-voxpupuli-corosync-6.0.1.orig/manifests/init.pp
+++ puppet-module-voxpupuli-corosync-6.0.1/manifests/init.pp
@@ -306,7 +306,7 @@ class corosync(
   Optional[Integer] $threads                              = undef,
   Integer[0,65535] $port                                  = $corosync::params::port,
   Corosync::IpStringIp $bind_address                      = $corosync::params::bind_address,
-  Optional[Stdlib::Compat::Ip_address] $multicast_address = undef,
+  Optional[Corosync::IpStringIp] $multicast_address       = undef,
   Optional[Array] $unicast_addresses                      = undef,
   Boolean $force_online                                   = $corosync::params::force_online,
   Boolean $check_standby                                  = $corosync::params::check_standby,
@@ -495,7 +495,7 @@ class corosync(
     require => $corosync_package_require,
   }
 
-  case $::osfamily {
+  case $facts['os']['family'] {
     'Debian': {
       augeas { 'enable corosync':
         lens    => 'Shellvars.lns',
--- puppet-module-voxpupuli-corosync-6.0.1.orig/manifests/params.pp
+++ puppet-module-voxpupuli-corosync-6.0.1/manifests/params.pp
@@ -3,7 +3,7 @@ class corosync::params {
   $authkey_source                      = 'file'
   $authkey                             = '/etc/puppet/ssl/certs/ca.pem'
   $port                                = 5405
-  $bind_address                        = $::ipaddress
+  $bind_address                        = $facts['networking']['ip']
   $force_online                        = false
   $check_standby                       = false
   $log_timestamp                       = false
@@ -23,7 +23,7 @@ class corosync::params {
   $enable_pacemaker_service            = true
   $enable_pcsd_service                 = true
 
-  case $::osfamily {
+  case $facts['os']['family'] {
     'RedHat': {
       $package_crmsh  = false
       $package_pcs    = true
@@ -41,7 +41,7 @@ class corosync::params {
     'Debian': {
       $package_crmsh  = true
       $package_pcs    = false
-      case $::operatingsystem {
+      case $facts['os']['name'] {
         'Ubuntu': {
           if versioncmp($::operatingsystemrelease, '14.04') >= 0 {
             $set_votequorum = true
--- puppet-module-voxpupuli-corosync-6.0.1.orig/types/ipstringip.pp
+++ puppet-module-voxpupuli-corosync-6.0.1/types/ipstringip.pp
@@ -1,6 +1,6 @@
 type Corosync::IpStringIp = Variant[
-  Stdlib::Compat::Ip_address,
+  Stdlib::IP::Address,
   Array[
-    Stdlib::Compat::Ip_address
+    Stdlib::IP::Address
   ]
 ]
