## confdroid_postgresql::server::service.pp
# Module name: confdroid_postgresql
# Author: 12ww1160 (12ww1160@confdroid.com)
# @summary Class manages the postgresql service
###############################################################################
class confdroid_postgresql::server::service (

) inherits confdroid_postgresql::params {
  if $fqdn == $pl_server_fqdn {
    require confdroid_postgresql::firewall::iptables
    require confdroid_postgresql::server::initdb
    require confdroid_postgresql::server::pghba::pg_hba

    service { $pl_service:
      ensure     => running,
      hasstatus  => true,
      hasrestart => true,
      enable     => true,
    }
  }
}
