Move NTP management into openstack_project::server

Once nodepool is building images with NTP already installed and enabled,
we don't need to manage it in the common openstack_project::template
class. This patch moves them over to openstack_project::server so that
it is obvious that puppet doesn't need to manage them for both
single-use workers and long-lived servers. Eventually the
openstack_project::template class should be empty and we can remove it.

Depends-On: Iee6babc183dd12cc82ce76ddfde04f2d98ddc4d6
Change-Id: Ie808a5b62014716c8506506fd15f39dba06e76b6
This commit is contained in:
Colleen Murphy 2017-03-28 22:39:40 +02:00
parent df050bc7b6
commit dccba790ae
2 changed files with 26 additions and 26 deletions

View File

@ -48,6 +48,32 @@ class openstack_project::server (
ensure => present
}
###########################################################
# Manage ntp
include '::ntp'
if ($::osfamily == "RedHat") {
# Utils in ntp-perl are included in Debian's ntp package; we
# add it here for consistency. See also
# https://tickets.puppetlabs.com/browse/MODULES-3660
package { 'ntp-perl':
ensure => present
}
# NOTE(pabelanger): We need to ensure ntpdate service starts on boot for
# centos-7. Currently, ntpd explicitly require ntpdate to be running before
# the sync process can happen in ntpd. As a result, if ntpdate is not
# running, ntpd will start but fail to sync because of DNS is not properly
# setup.
package { 'ntpdate':
ensure => present,
}
service { 'ntpdate':
enable => true,
require => Package['ntpdate'],
}
}
class { 'openstack_project::template':
iptables_public_tcp_ports => $iptables_public_tcp_ports,
iptables_public_udp_ports => $iptables_public_udp_ports,

View File

@ -167,32 +167,6 @@ class openstack_project::template (
}
}
###########################################################
# Manage ntp
include '::ntp'
if ($::osfamily == "RedHat") {
# Utils in ntp-perl are included in Debian's ntp package; we
# add it here for consistency. See also
# https://tickets.puppetlabs.com/browse/MODULES-3660
package { 'ntp-perl':
ensure => present
}
# NOTE(pabelanger): We need to ensure ntpdate service starts on boot for
# centos-7. Currently, ntpd explicitly require ntpdate to be running before
# the sync process can happen in ntpd. As a result, if ntpdate is not
# running, ntpd will start but fail to sync because of DNS is not properly
# setup.
package { 'ntpdate':
ensure => present,
}
service { 'ntpdate':
enable => true,
require => Package['ntpdate'],
}
}
###########################################################
# Manage python/pip