Commit Graph

25 Commits

Author SHA1 Message Date
Guilherme Steinmüller 9e3bd3f320 Retire openstack-ansible-os_monasca
Change-Id: Ie8da46562c150885010b47980a1ee26bff4d3bc5
2019-06-11 20:22:23 +00:00
kaiokassiano e7c468ed84 Add support for openSUSE
This patch aims to ensure that this role is functional in
opensuse distros.

Change-Id: I153ba0b5ba3b56f70d223f7e472e6213be146f27
2018-10-01 11:49:07 -03:00
Jesse Pretorius 4f08a80f0a Use a common python build/install role
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.

Depends-On: https://review.openstack.org/598957
Change-Id: I52ef39767ba8acc80ca0c9503c58efe7548ebba4
Implements: blueprint python-build-install-simplification
Signed-off-by: Jesse Pretorius <jesse.pretorius@rackspace.co.uk>
2018-09-03 12:01:27 +00:00
Guilherme Steinmüller 61d0a8964c Remove unnecessary default variables
Remove unusable variables as well as change
default passwords for influxdb users (perister and
api). These users needs use the values provided by
user_secrets.yml.

Change-Id: I02a4fa5df919d48d6e0671510793bc41143711d5
2018-07-23 18:28:31 +00:00
Jean-Philippe Evrard 0e4da819fd Fix monasca
This ensures the dependencies on the monasca roles are deployed
after the initial deploy steps of monasca. This allows us to
install on the host the packages required for the extra roles,
until they are fixed. Moreover, the grafana-ansible role is being
moved to ansible-grafana from cloudalchemy repository.

Change-Id: I9381c4994e38933fd12c02c673bfe409daf2a59c
Co-Authored-By: Guilherme Steinmüller <guilhermesp@lsd.ufcg.edu.br>
2018-07-17 17:47:46 -03:00
Jesse Pretorius 4b46ce34a7 Execute service setup against a delegated host using Ansible built-in modules
In order to reduce the packages required to pip install on to the hosts,
we allow the service setup to be delegated to a specific host, defaulting
to the deploy host. We also switch as many tasks as possible to using the
built-in Ansible modules which make use of the shade library.

The 'virtualenv' package is now installed appropriately by the openstack_hosts
role, so there's no need to install it any more. The 'httplib2' package is a
legacy Ansible requirement for the get_url/get_uri module which is no longer
needed. The keystone client library is not required any more now that we're
using the upstream modules. As there are no required packages left, the task
to install them is also removed.

Change-Id: I673a465863559d6fc72e4fdcd5da2ab788e561ab
2018-07-12 18:03:14 +01:00
Jesse Pretorius 356317735b Move database creation into role
There is no record for why we implement the database creation outside
of the role in the playbook, when we could do it inside the role.

Implementing it inside the role allows us to reduce the quantity of
group_vars duplicated from the role, and allows us to better document
the required variables in the role. The delegation can still be done
as it is done in the playbook too.

In this patch we implement a new variable called 'monasca_db_setup_host'
which is used in the role to allow delegation of the database setup
task to any host, but defaults to the first member of the galera_all
host group. We also document the variable 'monasca_galera_address' which
has been used for a long time, but never documented. A bunch of unused
variables have also been removed.

Change-Id: I42fe26054aec078a7a7ef66c20416af2cfb65811
2018-06-28 16:24:35 +01:00
Kevin Carter d2ac6aff1c
Add packages required for osprofiler
The following packages are required in-order to run osprofiler.
these packages will provide deployers the ability to profile
a service on demand should they choose to enable the profile
functionality.

Change-Id: I37f5a8da1e5fda51fd69d4c13421fabd083e3c6c
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2018-06-11 22:58:37 -05:00
Jesse Pretorius cac7008e57 Replace virtualenv-tools with a script
virtualenv-tools has a bug which gets triggered in gates: it can't
change the shebang of a virtualenv python bin/ files if they
were generated with a virtualenv script whose shebang ends with
python2 instead of python.

Because we can't modify virtualenv-tools, we use shell scripts
instead.

Change-Id: I62ae0b1f406f102fcb184913c5a6de54bb84c4c2
Partial-Bug: #1741634
Partial-Bug: #1764470
2018-04-24 13:52:24 +00:00
Flávio Ramalho 030df04ef8 Fix for monasca modules and other minor changes
This change fixes monasca modules to work with the latest version
of monascaclient.

Other minor changes:
  - Use cryptography instead of pycrypto
  - Removed duplicate variable for monasca_api_port
  - Added static paths for dashboards

Change-Id: Ib4fe27c276413bb2e1e5da3fe532d824745c5b99
2017-08-03 15:10:25 +02:00
Flávio Ramalho b884927071 Monasca role refactoring[+docs]
This patch refactors the whole monasca role by bringing consistency
with the other openstack-ansible roles. Main changes include:
  - Install services on its specific cointainer;
  - monasca-thresh, monasca-notification and monasca-persister was
    not being installed/configured, now it is;
  - Tempest tests are ran for the whole monasca-api;
  - The service should be fully functional;
  - Added documentation.

The extras directory contains the changes necessary to openstack-
ansible to setup monasca.

Change-Id: Ib53d4311c4b4aa722c7cdf7b18632e23b8639a56
2017-06-19 14:45:02 -03:00
Kevin Carter 2746142b68 Ensure the components are isolated from the system
This creates a specific slice which all OpenStack services will operate
from. By creating an independent slice these components will be governed
away from the system slice allowing us to better optimise resource
consumption.

See the following for more information on slices:

* https://www.freedesktop.org/software/systemd/man/systemd.slice.html

See for following for more information on resource controls:

* https://www.freedesktop.org/software/systemd/man/systemd.resource-control.html

Tools like ``systemd-cgtop`` and ``systemd-cgls`` will now give us
insight into specific processes, process groups, and resouce consumption
in ways that we've not had access to before. To enable some of this reporting
the accounting options have been added to the [Service] section of the unit
file.

Change-Id: I619ab58574eedece7e00e323f91aeaec4c5b5a6e
Signed-off-by: Kevin Carter <kevin.carter@rackspace.com>
2017-03-30 15:10:50 +00:00
Logan V c2f3c075af Clean up developer mode logic
Fixes the ability to deploy a venv in cases where:
1) developer_mode is not enabled
2) A cached venv is not downloaded from the repo server

Additional cleanup to the developer_mode venv deployment
logic is implemented by adding a *_venv_download var
which is used to decouple developer_mode from the
cached venv extraction process so that a deployer
can force venv builds in-place (disable cached
venv usage) without enabling developer mode
constraints.

Change-Id: I0280dce05e9f20b035e64b85750c72895e83a4b7
2017-01-16 12:55:31 +00:00
Jenkins 18c5d9f1dc Merge "Adding required monasca roles so users can query the apis." 2016-11-16 13:12:34 +00:00
Donovan Francesco (drifterza) 7f1c7d8c52 Adding required monasca roles so users can query the apis.
Change-Id: Id225d81b2d24b0e952ca6fb95c77d72ba189fd69
2016-11-16 13:46:49 +02:00
Donovan Francesco (drifterza) 649eb279fd Removing duplicate monasca_bin variable.
Change-Id: I3c5a51a17af445b4bd83ad1d1e9a11f3bb60678f
2016-11-16 09:51:14 +02:00
Donovan Francesco (drifterza) 5523577ffe Fix tmpfiles.d when multiple service are running.
- adding {{ monasca_lock_path }} for the monasca lock dir.

Change-Id: I4b6f1e72873b8e11ab805467d59cb45ba9a55af3
2016-11-10 08:39:41 +02:00
Jenkins 25fa6661ae Merge "Addressing grafana external role's required variables." 2016-11-10 02:24:07 +00:00
Donovan Francesco (drifterza) cfd94f19a2 Addressing grafana external role's required variables.
- https://review.openstack.org/#/c/394562/5/tests/test-install-monasca.yml

Change-Id: I816d2c830046c49db20487f85c0dc6acf6c2eebe
2016-11-09 16:59:04 +02:00
Donovan Francesco (drifterza) 8ea0b5118d Simplify pip options/constraints mechanism
The current constraints generation for the
installation involves multiple tasks and multiple
variables.

Using multiple tasks extends the installation time
unnecessarily and the additional variables are
unnecessary.

This patch aims to simplify the mechanism and
hopes to speed it up a little.

Change-Id: I213c955f832fd7bd0bc3497d8d8005985ecb04bd
2016-11-09 16:22:42 +02:00
Donovan Francesco (drifterza) 57eefc0f84 Optimizing monasca role.
- Making role more compatible with keystone v3
 - Replacing variable names with more OSA aligned styling

Change-Id: I5b7230301faedfdfa63f12e51ccadcc16c26639a
2016-11-08 16:57:51 +02:00
Donovan Francesco (drifterza) 57e026fccd Fix linting issues for ansible-lint 3.4.1
Preparing this role for the ansible-lint version bump

Change-Id: I8bfa56de4f69f121cdec419d3135153dc26edfbd
2016-11-07 18:45:22 +02:00
Donovan Francesco (drifterza) a67b4c9673 Better functional tests for monasca-api.
- This patch returns status code 200 if keystone auth token is
retrieved.
 - Minor adjustments to the keystone middleware sections.
 - Adjustments in user naming in service endpoint creations.

Change-Id: Ifbb356634b29f1586c44e1135a761bf1f6adddb0
2016-11-03 15:27:57 +02:00
Donovan Francesco (drifterza) 524a052417 Refactoring Monasca role to align more with OSA.
- This patch is to provide monasca backend services and monasca api,log-api
 - Adding the use of dictionary for service group mappings.
 - Switching to use tested external roles for backend services.

Change-Id: I7f6335f12a4b3a13acf6b644f16587ab1b46745f
2016-11-01 20:03:18 +02:00
Donovan Francesco cfda2f626d Initial Commit 2016-08-18 15:46:59 +02:00