At the moment we don't restart services if systemd unit file is changed.
We knowingly prevent systemd_service role handlers to execute
by providing `state: started` as otherwise service will be restarted twice.
With that now we ensure that role handlers will also listen for systemd
unit changes.
Change-Id: Ibb1b0159ca8267ce3ab6ffb1752ab10ddb4b8139
In order to radically simplify how we prepare the service
venvs, we use a common role to do the wheel builds and the
venv preparation. This makes the process far simpler to
understand, because the role does its own building and
installing. It also reduces the code maintenance burden,
because instead of duplicating the build processes in the
repo_build role and the service role - we only have it all
done in a single place.
We also change the role venv tag var to use the integrated
build's common venv tag so that we can remove the role's
venv tag in group_vars in the integrated build. This reduces
memory consumption and also reduces the duplication.
This is by no means the final stop in the simplification
process, but it is a step forward. The will be work to follow
which:
1. Replaces 'developer mode' with an equivalent mechanism
that uses the common role and is simpler to understand.
We will also simplify the provisioning of pip install
arguments when doing this.
2. Simplifies the installation of optional pip packages.
Right now it's more complicated than it needs to be due
to us needing to keep the py_pkgs plugin working in the
integrated build.
3. Deduplicates the distro package installs. Right now the
role installs the distro packages twice - just before
building the venv, and during the python_venv_build role
execution.
Depends-On: https://review.openstack.org/598957
Change-Id: I1e722ad353564a6586e5b597d73b5e1dad6033d9
Implements: blueprint python-build-install-simplification
Signed-off-by: Jesse Pretorius <jesse.pretorius@rackspace.co.uk>
With the more recent versions of ansible, we should now use
"is" instead of the "|" sign for the tests.
This should fix it.
Change-Id: I25327d6d37ccedfa446f49acaea70de798ad8a01
From Ansible 2.2 onwards, listen can be used for
handlers instead of chaining notifiers. The
handlers are then executed in the sequence
present in the handler file.
Change-Id: I04d4c2bdb3a9152cef06995368a65931ba495ea0
Ceilometer no longer stores any data so the MongoDB installation
playbook is not used. In addition, it no longer has an API so
the api-paste file is useless as well.
Closes-Bug: #1747612
Change-Id: I20104cc357f78b01e2b1246a3f51d609bb2f4f24
Due to the debug message plugin the handler restart
messages show at the end of the playbook execution
which is a little confusing. Using debug also
requires setting changed_when to true which is a
little extra bit of code which we do not have to
carry.
Instead we use the command module which is simple,
works and less wordy.
Change-Id: Ide5abf639e90f8d81044aed59bd2c73b960be9e6
When the policy file is copied from the templated
file to the active file, it loses its group/mode
settings. This patch ensures that they are properly
replicated during the copy.
Change-Id: I50c50958fbdcc7f3912189a0b47cda0cf9313927
The policy.json file is currently read continually by the
services and is not only read on service start. We therefore
cannot template directly to the file read by the service
(if the service is already running) because the new policies
may not be valid until the service restarts. This is
particularly important during a major upgrade. We therefore
only put the policy file in place after the service restart.
This patch also tidies up the handlers and some of the install
tasks to simplify them and reduce the tasks/code a little.
Change-Id: I706d99cec90491216bb997ed06cbed6514e1b663
Ceilometer API is now deprecated in favor of using
Gnocchi, Aodh, and Panko to pull telemetry information.
Change-Id: I4464fc6bd4ad3ef14e2638abcdb86180e82615e1
Closes-Bug: 1666640
Using ansible systemd module to daemon reload and service reload
is the solution for the future. Let's embrace it!
Change-Id: I702a10266bec2e2b34f60abcd60159f34d2cacd3
Signed-off-by: Jean-Philippe Evrard <jean-philippe.evrard@rackspace.co.uk>
As a part of removing Trusty from OpenStack-Ansible we shall aim to
remove this from all the roles.
Testing has already been removed for Trusty in the integrated build and
all individual repositories on master (Ocata), as such we can now go
ahead and remove the support within the roles.
Change-Id: Ia564599a02eeafecc5614271fe4afbb1eb812aea
Implements: blueprint trusty-removal
With the move to using a service-group mapping for installing services,
the ceilometer-polling agent now only installs on hosts within the
ceilometer_central_agent group when it should also be installed to the
ceilometer_compute_agent group. Adjust the service mapping to allow for
multiple group assignments per service and update relevant tasks to use
subelements to install each service within its assigned groups.
Also fix the 'Reload upstart init scripts' handler so that it can
properly be marked 'changed' in order to notify the 'Restart
ceilometer services' handler.
Closes-Bug: 1639026
Change-Id: Iba8e1f58c996a55389f50c727a4afa55099daa22
Change the 'ceilometer_service_names' from a list to a dictionary
mapping of services, groups that install those services. This brings
the method into line with that used in the os_neutron role in order
to implement a more standardised method.
The init tasks have been updated to run once and loop through this
mapping rather than being included multiple times and re-run against
each host. This may potentially reduce role run times.
Currently the reload of upstart/systemd scripts may not happen if
only one script changes as the task uses a loop with only one result
register. This patch implements handlers to reload upstart/systemd
scripts to ensure that this happens when any one of the scripts
change.
The handler to reload the services now only tries to restart the
service if the host is in the group for the service according to the
service group mapping. This allows us to ensure that handler
failures are no longer ignored and that no execution time is wasted
trying to restart services which do not exist on the host.
Finally:
- Common variables shared by each service's template files have
been updated to use the service namespaced variables.
- Unused handlers have been removed.
- Unused variables have been removed.
Change-Id: I417f366e343a7b764e3bcd9ab75efc3a233b460b
Because Ceilometer is deployed with impacts on some deploy hosts,
Apache presents an undesirable surface area to deploying it seems to
be contraindicated.
Change-Id: I494875017509516e50af594c53430f5db90f5322
With the dependent change merged Ceilometer API will no longer run
without a stand-alone wsgi engine. It is too late in the cycle right
now to bring over changes for nginx and/or uwsgi for this project so
only this deployment option is being supported at this time.
Change-Id: I3cff6b183feae3c346cd56602d7b733a6dd9a01b
Depends-On: I8812ea1a92d6dc7f41a490e971bb7a09dee9b304
When executing the role with Ansible 2.1, the following
deprecation warning is issued in the output for some tasks.
[DEPRECATION WARNING]: Using bare variables is deprecated.
This patch addresses the tasks to fix the behaviour appropriately.
Change-Id: I21615fa7fea8332487cd83854d1f0cd243165e9d
The ceilometer-central-agent and ceilometer-agent-compute
services are now completely removed from the liberty release
of ceilometer. The new implementation is to use ceilometer-polling
and call the respective pollsters by namespace.
This patch addes the neccessary upstart configurations for
ceilometer-polling and it also removes the deprecated admin_* options
from the ceilometer config file.
This patch set is also forcing ceilometer to use the Keystone
v2.0 API by adding the versioned path uder [service_credentials]
in the ceilometer config file.
Change-Id: Iba2bb148df4f3ae9d16b44c27ddff0c0d3fd29d3
UpgradeImpact
Closes-Bug: #1519423
Closes-Bug: #1519462
The alarming function of Telemetry has been seperated out
by design. This patchset creates new containers for these
alarming services and deploys them accordingly.
See:
http://lists.openstack.org/pipermail/openstack-dev/2015-September/073897.html
DocImpact
UpgradeImpact
Implements: blueprint liberty-release
Change-Id: I25294a25afa76d4d8bddad0a51c48485f33a6d20
This patch implements the implement-ceilometer blueprint.
It addes the necessary role/variables to deploy ceilometer
with a Mongodb backend. The Monogdb backend is assumed to
be up and configured and the playbooks only require a few
values to be set in user_variables to establish a connection.
Change-Id: I2164a1f27f632ce254cc2711ada2c449a9961fed
Implements: blueprint implement-ceilometer