Improve restarting Apache

The previous approach could lead to restarting Apache after
Anchor['aodh::service::end']. The new approach is already used in other
Puppet modules and guarantees restarting Apache between the service
anchors.

Change-Id: Id88fe6c893964fa5f8dfd3e75c933615b9f6af40
This commit is contained in:
Matthias Bastian 2018-08-14 16:46:38 +02:00
parent 82b983437b
commit 1ea9ed2e82
1 changed files with 1 additions and 2 deletions

View File

@ -122,11 +122,10 @@ release. aodh::wsgi::apache supports setting a port.')
enable => false,
tag => 'aodh-service',
}
Service <| title == 'httpd' |> { tag +> 'aodh-service' }
# we need to make sure aodh-api/eventlet is stopped before trying to start apache
Service['aodh-api'] -> Service[$service_name]
# the apache service is untagged so add it to the service section manually
Anchor['aodh::service::begin'] ~> Service[$service_name]
} else {
fail("Invalid service_name. Either aodh/openstack-aodh-api for running \
as a standalone service, or httpd for being run by a httpd server")