Commit Graph

62 Commits

Author SHA1 Message Date
Paul Belanger 9ae268fa89 Add zookeeper tls support
Now that tls support is required, add support for it.

Change-Id: I36f2c0a2b2209cfa974b4686c0c32f3fe32e9cae
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2021-06-22 08:51:00 -04:00
Paul Belanger 7b0af5bbfc Clean up bitrot
Do the things we need to do to get our testing working.

Change-Id: Ia9898a2406c601f45b07714b46a7d44632e229e5
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2021-06-22 08:50:57 -04:00
OpenDev Sysadmins b6bf41a4da OpenDev Migration Patch
This commit was bulk generated and pushed by the OpenDev sysadmins
as a part of the Git hosting and code review systems migration
detailed in these mailing list posts:

http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003603.html
http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004920.html

Attempts have been made to correct repository namespaces and
hostnames based on simple pattern matching, but it's possible some
were updated incorrectly or missed entirely. Please reach out to us
via the contact information listed at https://opendev.org/ with any
questions you may have.
2019-04-19 19:52:08 +00:00
Paul Belanger 17e04fb576 Switch to yamllint for tox -elinters
It was a lot of overhead, with little gain, to run molecule lint.
Switch back to just using yamllint.

Change-Id: Ie4e4d5d77dcb864f7b76cd356cab7adf9516d1b3
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2019-03-08 10:10:34 -05:00
Paul Belanger b363f10c1e Move testinfra validate to run phase
Zuul now supports multiple run playbooks, lets use that over post-run.

Change-Id: Id6d591023ef9b351e08e4260c281d25eec0836cc
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2019-02-16 19:48:48 -05:00
Paul Belanger 34bd22ca8b Add experimental installation from docker
This is our first attempt at running nodepool from docker, consider it
experimental.  The idea here, is you now have the option of using the
official docker images from https://hub.docker.com/u/zuul for nodepool.

Users themself will be required to manage / configure docker, this role
only installs / configures / starts nodepool.

Change-Id: I2f3aa301e626a7b09ff129a21a188cee06e31f18
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2019-02-07 16:15:03 -05:00
Paul Belanger 4666971ac5 Switch to molecule for testing
Molecule is the defacto testing tool for ansible roles. Switch to it to
make it easier for users to test.

Change-Id: I881e895877c9702e62c4415d48b0f33f34f7487b
Depends-On: https://review.openstack.org/593369
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-08-19 11:32:19 -04:00
Paul Belanger efc9d57e2c Switch to testinfra for role validation
We can switch to using testinfra to help ensure ansible did everything
properly.

Change-Id: I9e21cd16f1149d76308043a97658c93e7f14ac42
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-08-16 20:26:51 -04:00
Paul Belanger 2d9363cba7 Also collect journald logs
Change-Id: I7a952f835d7f43e1e96e8024d17fa6756fe0cc48
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-08-14 21:58:34 -04:00
Paul Belanger 81b000901c Use new log collection process
While this isn't 100%, it is enough to actually get started using it.

Change-Id: I8e4bad97658f98ca5280eca694dc2d9cb4028ad1
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-08-14 21:35:02 -04:00
Paul Belanger 08f40aa7bd
Stop using pre-compiled wheels
We actually want to ensure users are able to use our roles outside of
openstack-infra. Since those users won't have wheel mirrors, disable
our jobs from using them too.

Change-Id: I0a3c44c81aff497bc1678b68fc7b1374f233901b
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-04-13 15:00:42 -04:00
Paul Belanger 5efd428d9e
Refactor jobs to support pip / git installation testing
Because we want users to support both pip / git install methods,
refactor testing to support the testing of that.

Change-Id: Ieef3763172fbfe07a5d0cc4c83c37a6dad30b3cd
Depends-On: https://review.openstack.org/560996
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-04-12 17:55:15 -04:00
Paul Belanger 4972ff6b7f
Update nodepool_git_dest location
Stop using /opt folder to store the location of git checkout. We don't
actually need to be root user to do that.

Change-Id: Icdb2905cf66fd9ab414d009ad3d782bc802e037d
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-03-04 15:17:09 -05:00
Zuul e8b754ae13 Merge "Collect logs from testing" 2018-02-12 00:03:09 +00:00
Paul Belanger 19929aa259
Collect logs from testing
It is helpful to have logs to debug failures.

Change-Id: I3d5170713a031dc8ccb4772a7778bec1e63ffa15
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-02-11 15:17:30 -05:00
Paul Belanger 7212863d56
Default nodepool_pip_executable to pip3 for testing
There is no more python2 support for nodepool, switch to using pip3 to
install it by default.

Change-Id: I9daf4c6e78c4069e6eb949cc89b2b76452b3a42f
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-02-09 18:14:50 -05:00
Paul Belanger 22befecd1f
Initial support for zuulv3
Now that zuulv3 is live, we can start having in repo jobs.

Change-Id: I0463d440abac26b4592fce0e26960be33c0a4efc
Depends-On: I7db3518f6dbd9c9315ebb5d4c40c6e18764b4e94
Depends-On: I3bff01ebac17c40988df60e7e4dd6e7fdc88a896
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-10-20 09:52:32 -04:00
Paul Belanger 5c8d047bd4
Switch to systemd configuration files
Now that we are using systemd everywhere, we can simplify our service
configuration.

Change-Id: I9bacb3925f8e95587d459284758de337f9a270c3
Depends-On: I37ae527a93f5d5300c9ac4a1b4a6ca4363e7096d
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-05-29 10:49:48 -04:00
Paul Belanger 982b5534e3
Remove ubuntu-trusty support
Move forward with only supporting ubuntu-xenial for our LTS.

Change-Id: I95194bd5555a0df18059f4aaf2ab1898dcfb59e6
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-05-26 21:42:56 -04:00
Paul Belanger 5a2fdd352e Switch to feature/zuulv3 branch
Change-Id: Ia1c530fc57f50d255e87e066c292bcbe09cdd094
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-03-29 14:02:01 -04:00
Paul Belanger 8dc8c157eb Drop elements-dir from nodepool.yaml
This is an optional setting, and not needed to start nodepool.

Change-Id: I603b4a79f9a15ad404df4b34377c2f9fc0f7ba17
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-12-24 12:44:42 -05:00
Paul Belanger cf93f245f6 Drop scripts-dir support
This is no longer a valid setting in nodepool.

Change-Id: Iee9399cf0989eb7cfab4c71c97baf5a69c3265d0
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-12-24 11:54:50 -05:00
Paul Belanger 40f1e5036f Add /opt/nodepool/images to required directories
Change-Id: Icfcbfc71bfa06f35c5961f8a7dd6c6b138e5fedc
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-11-26 16:56:01 -05:00
Paul Belanger 01acdd5bad Add unit test to validate PID files exist
This is a follow up to a previous commit, make sure the PID files
actually exist.

We only need this for initd scripts today.

Change-Id: Iedad736a9656aa04bc9b696051e421663061c0bb
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-11-26 11:49:21 -05:00
Paul Belanger 0b6be488ba Support systemd for ubuntu-xenial too
Here we are adding support to our existing systemd files for both
centos-7 and ubuntu-xenial.

Change-Id: I15e8db69a87bbfa75391f2faa97b312a034673bf
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-11-24 14:09:47 -05:00
Paul Belanger 7ae472381d Add nodepool-launcher support
We now have the ability to scale out nodepool-launcher, on a single
instance.

Change-Id: Ib7792ea591c7e1ce953730791884566f77fcbd33
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-10-08 16:01:20 -04:00
Paul Belanger c95988bccb Add nodepool-deleter support
We now have the ability to scale out nodepool-deleter, on a single
instance.

Change-Id: Idce9a7a1f49ae7b433009967bc1df220b0c35e00
Depends-On: I84a727198f0f3b1d3fbd0564b9ccb120648069cd
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-10-08 11:13:29 -04:00
Paul Belanger 5b1c3321a3 Add nodepool-builder logging.conf file
Change-Id: I97a3d2d394b5daca23af2c44d4488c097e521f33
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-10-08 09:18:46 -04:00
Paul Belanger 2644350b7d Register the results of file changes
The idea here is to expose information to users to allow them to make
decisions, for example restarting a service.

Change-Id: Ifbc45af72db820c842c83d7af1adb460969a7336
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-10-07 21:15:13 -04:00
Paul Belanger 7d24cad3cd Clean up logging.conf settings
Change-Id: I8117498c19b2fb72603245efce8e708276b37f10
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-10-07 20:12:20 -04:00
Paul Belanger 5fc48b568e
Limit become usage for testing
Change-Id: Id15688bf0cf6cd95ee625368973e4ce6b30a990c
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-09-05 22:13:51 -04:00
Paul Belanger a0a37bddb9
Drop synchronize support for scripts
It was become too much work to deal with this. Additionally, if people
want to manually synchronize we expose the proper settings to allow
them to do so.

Change-Id: I68aedb16223146f1ff6d7c9115773e62ae4ba8c9
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-09-05 15:10:01 -04:00
Paul Belanger 7220ba6dac
Drop synchronize support for elements
It was become too much work to deal with this. Additionally, if people
want to manually synchronize we expose the proper settings to allow
them to do so.

Change-Id: I68ae9e7cb6e4a69392ea95cd0be72e01f166190e
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-09-05 14:24:33 -04:00
Paul Belanger 354161295f
Stop templating secure.conf options
Simplify things by only passing the secure.conf file, not a
template.

If users need more dynamic options, they are free to template the file
first then use us to copy the file in place.

Also tests file mode for nodepool.yaml

Change-Id: I4d2eba3292b2657ef9a607497056fa94cdd1bec8
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-09-05 13:24:20 -04:00
Paul Belanger 70feab610d
Stop templating configuration options
Simplify things by only passing the nodepool.yaml file, not a
template.

If users need more dynamic options, they are free to template the file
first then use us to copy the file in place.

We'll be doing this over a series of commits, rather then 1 large
patch.

Change-Id: Id751920e31edac9a469f4624ae2a30e841245d80
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-09-05 12:43:31 -04:00
Paul Belanger 2658537bb4
Per service configuration
Since it is possible to run both nodepool and nodepool-builder, we
should give the user 2 different configuration files.

Change-Id: I9e825a331d04124a2548203cfd8d77935fdf7bb6
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-08-31 20:40:16 -04:00
Paul Belanger fe3081b09d
Fixes to pass in the gate
- update role_path
- new ansible_lint skips

Change-Id: I15eef07cce61f78a19797be3db0dd3521c2b503f
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-08-30 17:38:19 -04:00
Paul Belanger 9e40c41283 More elements and scripts to /etc/nodepool
Move them back to their original location to be in sync with
openstack-infra.

Change-Id: I21a38b7be1c7a9ee2547a8bbd2f2f5018e51d15f
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-03-26 20:42:01 -04:00
Paul Belanger 63367f14ce More elements and scripts to /var/lib/nodepool
To keep things in sync with future packaging.

Change-Id: Iff3221cd4d9eb7c058aefcd8747ac7f8baa3988b
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-02-13 16:02:46 -05:00
Paul Belanger eb5560bec5 Fix ansible-lint failure
Change-Id: Ie8fe9301c1f38c1c6d3c163c05aa9471100e0407
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-02-13 12:34:23 -05:00
Leif Madsen 212a191c4d Drop unnecessary relational paths in copy module
* add tests to validate files are installed
* change to match zuul style service configuration
* fix invalid tests added first time around
* add missing defaults
* drop nodepool.sysconfig and move to proper location

Change-Id: Iee0b11897d7f4916035ab2d92c5d2dd755341670
2016-01-28 13:36:16 -05:00
Paul Belanger 539b27a6d2 Add nodepool-builder support
Change-Id: Ia8786c2bf118089d9ded53257ec6d3dec6cb9c14
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-01-26 16:36:24 -05:00
Paul Belanger 06e87cf8cf Let jenkins generate SSH keys
Change-Id: I9987623224daa93bdda8be81c334a3eee11db307
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2015-12-14 13:47:04 -05:00
Paul Belanger 617c03797c Switch back to init.d for Ubuntu 14.04
Upstart is dead moving forward, just skip using it until systemd is
default for Debian.

Change-Id: I3ca250523d2871097001df0c76b3b83f57eb5c99
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2015-12-13 18:11:04 -05:00
Paul Belanger 1360549636 SSH to localhost for functional tests
There is an open review for project-config to enable this by default,
until then, we can have ansible set things up for us.

Change-Id: I64aaa7187568ff08ef6b0935d8829376dd6761e5
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2015-12-13 13:45:30 -05:00
Paul Belanger b08a112351 Refactor nodepool service
Allow the user to override the service settings and add unit tests.

Change-Id: I2d9409d210015a202f33eca970d02be137617de7
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2015-12-12 15:58:35 -05:00
Paul Belanger 3f9c17f936 Switch to separate elements and scripts directories
This will give the user more flexibility when defining source folders.

Change-Id: Ib57f81fc6892c55e67be647d2f1d2e56fd4f08ec
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2015-11-27 23:23:41 -05:00
Paul Belanger c694057024 Preserve existing permissions with rsync
Otherwise, we loose the execute bits for dib elements.

Change-Id: I83e193cd9aef7e7e9da71558b27af1463c80bc3b
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2015-11-27 17:50:15 -05:00
Paul Belanger 8b831ff81c Rsync support for elements and scripts directory
nodepool_project_config_dir should contain the path of adirectory which
has both elements/ and scripts/ sub directories.

Change-Id: I3a3d2ba225f15cf785da327905915053b04340ea
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2015-11-27 11:30:53 -05:00
Paul Belanger 62f8ad044b Add unit tests
Like we did in ansible-role-zuul, start writing unit tests for our
role.

Change-Id: I8e7a0dd90323c67458caf2a06f5799c23df20ffb
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2015-11-26 13:02:42 -05:00