Commit Graph

71 Commits

Author SHA1 Message Date
Paul Belanger be19120a4a Add ssl support for zookeeper
Change-Id: I891373b656e4f2ab59e1cdffaa122bc821c46bf1
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2021-06-22 21:59:34 -04:00
Paul Belanger 45d256899b Create zuul_pip_virtualenv_symlink variable
Expose the ability for a user to create a symlink to a zuul
virtualenv, this is usually needed when you start trying to version
different virtualenv installs.

Change-Id: Icef1ac5c412e6c905c6490899dffa47262812466
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2019-03-23 23:20:26 -04:00
Paul Belanger 9ecd092e43 Split zuul service state into own task
It is possible we want to enable a service on boot, but don't want to
ensure it is currently running. This splits our systemd tasks into 2
different checks now.

Change-Id: Ic4d9cd8f770f72c262a099dddd6372c155bae133
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2019-01-19 12:06:39 -05:00
Paul Belanger c1d6259f95 Don't reload scheduler when zuul.conf changes
Zuul doesn't (yet) support reloads when zuul.conf changes. For this, you
need to actually stop / start the services.

Change-Id: I7e0932e27bc68777d40a6efa350569a205274f43
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2019-01-17 14:13:16 -05:00
Paul Belanger 96b9c0de96 Allow user to optionally manage config files
As an example, if we are only install zuul-web, a user might not want
logging files from other services. However, installing them won't hury
anything, so do that by default.

Change-Id: I3c43259a1a6f1bfc35911fa6e1c9d4f506c05f40
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2019-01-07 14:39:51 -05:00
Paul Belanger 60144b8a04 Clean up punctuation
Change-Id: I4dc54429850abfba854a56fbf634143e1e3eb9f2
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-12-21 14:27:21 -05:00
Paul Belanger 44cf73e41c Add zuul_user_shell variable
Give the ability for a user to override the default shell for zuul user
account.

Change-Id: I30cb9a13f4eaf799abb627a99780aef84eaec286
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-12-21 14:22:42 -05:00
Paul Belanger 118b914aec Fix deprecation warning for ansible
Change-Id: I4a79e9396feb93d12138ee88e0cd1fa5ecba301b
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-08-19 12:47:24 -04:00
Paul Belanger f1cd85520b Fix truthy value should be true or false warnings
Running yamllint, this exposed the follow warnings. Lets clean them up
before we switch to molecule.

Change-Id: I7eec334124e8c5eecb5a0b5670f0e512ef50a607
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-08-19 12:33:51 -04:00
liusheng 621bbb0150 Support editable flag to pip installation
This is useful for deploying experimental CI system for testing.

Change-Id: Ib66ae60936c5659a43857d3e0d0b1a08a089e288
2018-07-03 09:37:31 +08:00
Paul Belanger 3a377a0f25
Revert "Don't install zuul_build_depends for pip"
Until we actually provide wheels for all dependencies, we have to
revert this.

This reverts commit 6f0e13b909.

Change-Id: I221a7474f5b52059125a7480f432a5ac3b3b648e
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-04-26 10:16:57 -04:00
Paul Belanger 0913ef63b1
Replace layout config with main.yaml
With zuulv3 there is only a single configuration file now for
projects, no more external python files. Remove zuul_file_layout with
zuul_file_main_yaml.

Change-Id: I63d592999684b1437bb240405a62af0cc362e977
Depends-On: https://review.openstack.org/561475
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-04-15 15:50:07 -04:00
Paul Belanger cd931ba37c
Pass list of packages directly to package task
There is no need to loop over the list of packages, this is actually
slower.

Change-Id: Ifd7d9b9608d25b7078a215bce57babf18c4abce6
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-04-14 16:41:25 -04:00
Paul Belanger cdba41e540
Default zuul_pip_executable to pip3
Moving forward, we'll only support zuul under python3.

Change-Id: I3fdabe07e6aceff68442dfb295fb3c24d6e05b58
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-04-13 13:00:49 -04:00
Paul Belanger 6f0e13b909
Don't install zuul_build_depends for pip
When installing zuul from pip (pypi.python.org) there is no need
to install the build dependenies as we download the wheel.

Change-Id: I2c33e0a0a92b5b7386b952626200473cc77fbb93
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-04-12 22:14:49 -04:00
Paul Belanger 83d425bdb3
Switch to template for zuul service files
We do this for ansible-role-nodepool, we might as well do it here.

Change-Id: I1976f05ec1ec6fdb69e255297dfa64ab00330e7c
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-04-04 20:27:49 -04:00
Paul Belanger 6ccb5af56e
Only zuul-scheduler support reloading
Currently all the other services in zuul do not support it, so we can
remove this logic as it is not needed.

Change-Id: I013c4331070491197a119ff2b2317efa2bce4bc4
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-04-04 15:56:41 -04:00
Paul Belanger 9167794c34
Add support to manage SSL cert
Since gear support SSL certs, add in some support to place them into
the SSL folder.  It is possible we might want to move this into an
ansible role, but for now it seems minimal to support it.

Change-Id: I5a3097a6026f648c6dbabb1e26e6a4d201f68c1c
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-04-03 22:36:28 -04:00
Paul Belanger 3a9c863212
Add fingergw support
In zuulv3 we added the fingergw process, update our role to support
that.

Change-Id: I2978bb3c53c2f0ed56a6536be110cb471f157ab2
Depends-On: https://review.openstack.org/551015
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-03-13 16:36:05 -04:00
Paul Belanger 7d5442f91f
Add support for zuul-web
Zuulv3 creates zuul-web which is needed for log streaming, secrets and
various other things.

Change-Id: Ib3378e6f726d0781750a48f80fe276d63c5c68f5
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-03-06 18:26:10 -05:00
Paul Belanger e10ff85f31
Merge OS-specific variables for ubuntu
Now that we are using systemd everywhere, for xenial++ there isn't a
need to release specific settings.

Change-Id: I41567021ccb1fe86016278f52b3f0b4356fce363
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-03-06 12:06:17 -05:00
Paul Belanger 34c2d13d82
Update zuul_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: I26b13d02b73aca798deb1bbb12ce982951e59cd4
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2018-03-04 19:39:25 -05:00
Paul Belanger 0d6f61e697
Add zuul_git_update setting
It is possible we do not want to update git repos or already have git
repos on disk.

Change-Id: I5095cdc3c0d25027164d98f36c8ecbeba426a6cb
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-11-01 12:16:37 -04:00
Paul Belanger 302faf4574
Create zuul_pip_executable
Allow the user to control the path to the pip executable.

Change-Id: I0622a8cf6ceb0b3fc2583dca106cecc759190207
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-05-31 11:58:00 -04:00
Paul Belanger 872043b873
Remove redundant pip install task
We can clean up our install task by using an include.

Change-Id: Ic703ec032a67efef65bc5f090ada688c08ebfd8a
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-05-26 22:01:06 -04:00
Paul Belanger 8e5b9d3ec6
Switch to systemd module to manage services
With this, we gain the ability to daemon-reload our services. Which
means, if we now upload our systemd files, systemd will properly
detect this and refresh the configuration.

Change-Id: I3fa7bcccbb02755870b665b60280d8c483cc4a18
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-05-26 19:53:40 -04:00
Paul Belanger fedc3c6666
Switch to systemd per service config files
The recommended way to setup service config files is with using:

  systemctl edit foo.service

This updates our systemd configuration files to support this.

Change-Id: I405d6063ad3d5fd529139d7ce17c3238924f2e45
Depends-On: I92801be5fadc91c72e562b4b8dfb2ed1af24a320
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-05-26 18:40:52 -04:00
Paul Belanger fbe33c05bd
Allow service / service_config to be optional
This allows the user more control over which files will be copied to
the remove server.

Change-Id: I67db12aa1fd71e898ce0772ec6adc34aaab333db
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-05-26 18:29:15 -04:00
Paul Belanger ac99248f69
Add zuul_pip_virtualenv_python variable
The Python executable used for creating the virtual environment. For example
python3.5, python2.7. When not specified, the Python version used to run the
ansible module is used.

Change-Id: I18a0f388e64ad30d3edd1240aa6ba3d5b6526d65
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-05-25 14:09:40 -04:00
Paul Belanger e7af59e895 Remove zuulv2.5 hacks
Now that zuulv3 is well into development, we can stop installing
things related to zuulv2.5.

Change-Id: Icd630871ad2991cdf884f6569237827100934138
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-03-15 15:44:29 -04:00
Paul Belanger dc3ac2381a Rename zuul-launcher to zuul-executor
Change-Id: Ibca96dec83f7a1a077ada9c8e001e9f173c6e050
Depends-On: I933ad76621b402701d418bcb693192713c79da41
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-03-15 13:53:04 -04:00
Paul Belanger 3fc94ec74a Switch to feature/zuulv3 as default branch
Now that we are running zuulv3-dev.o.o, we are in a good place to
switch to the feature/zuulv3 branch for our ansible role.

Switch out zuul-server with zuul-scheduler.

Add python2-dnf to bindep.txt for fedora-25 job.

Change-Id: Ib61063c9b542e04f2f14a165f23bc82062714bf8
Depends-On: Id54a479e2e1b406cd5fd526ec6d2ee118b28b8d7
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-02-28 12:46:55 -05:00
Paul Belanger 547f392b6b Just use redhat.yaml for now
No point running difference variables for RedHat yet, there is no
need.

Change-Id: I6d1be04671d385d481e2e930b28e93e146cf5e0a
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-12-08 16:18:45 -05:00
Paul Belanger 8ebb97e3e9 Support systemd for centos-7 and ubuntu-xenial
Because of a bug in ansible 2.2, it is easier for us to move to
systemd for ubuntu-xenial.

Change-Id: I0c4709f413b7beb131846b815a9e5c474b3221bb
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-11-24 15:26:14 -05:00
Adam Gandelman 747f3ba540 Migrate config installation from copy -> template
This migrates installation of config files from using 'copy' to 'template',
allowing downstream users of the role the ability to carry a template in their
playbooks and have it easily rendered out simply by overriding the
zuul_file_*_dest variables.

Note, this omits layout.yaml for the time being

Depends-on: I32cc11901bddd03125e1c4ce6f246d811f414cba

Change-Id: I9f5890a54ded2b0169aa76501828e7856e0d6583
2016-10-18 14:16:10 -07:00
Paul Belanger a196040868
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: I815564f9708a51ce13ea0397dd991aebbcad430e
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-10-04 13:24:23 -04:00
Paul Belanger cd9544c1c6
Pin JJB to 1.6.1
To avoid breakage with JJB and zuul-launcher, we're pinning to 1.6.1.
As soon as zuulv3 is released, we nolonger need the JJB dependency.

Change-Id: Ib74396403ba0b74ba32d424f087152522e8a0f8d
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-09-05 21:37:33 -04:00
Paul Belanger ad61a59119
Add virtualenv for missing depends workaround
We missed adding virtualenv to pip for our broken dependencies.

Change-Id: Iac68712906b5cd7e993d0b763ff90224d154edb3
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-08-30 12:01:25 -04:00
Paul Belanger 242a1c0460
Per service configurations
It is now possible to make configuration changes per service.

Change-Id: Ia59daa9859c22e4ff5e601528a63331d2eef93cf
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-08-28 16:29:59 -04:00
Paul Belanger 8bbca0e120
Simplify pip install options
Using the omit template, we can now better control which pip options
we set.

Change-Id: I8a3abc0b623a75e1f695441f96b922a2a72e41f7
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-08-28 13:11:48 -04:00
Paul Belanger bc0cb78b77
Remove epel-release / python-pip from role
These are dependencies our role requires. As such, they should be
installed by the user.

Change-Id: I736463187b3210ccada6b7c5f9202047ce6b0e86
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-08-27 18:15:57 -04:00
Paul Belanger 7af82ea854
Add zuul_task_manager to expose control of tasks
There might be a time were we only want run the pre task, so rather
then copying the code into another modules, just allow the user to
override the task list that runs.

Change-Id: I97a40294ac3332bcce20ca4e3458c9988816c6c7
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-08-27 17:49:21 -04:00
Paul Belanger 85371e9ad2
Initial support for zuulv2.5
Change-Id: Ic0629f3a7c957905c6241d4e7898a4f12e3ece75
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-05-14 15:09:43 -04:00
Paul Belanger 2063ed25a3
Stop templating configuration options
Simplify things by only passing the zuul.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.

Change-Id: Ibd599b3ece707682eff9650a2244c0fb092f601c
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-05-14 12:59:42 -04:00
Paul Belanger aa9be4df5d Fix deprecation warning
Change-Id: I10675381d420813e067eef7e0360eac63fc052ce
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-03-25 17:58:35 -04:00
Paul Belanger f8c83b0998 Drop synchronize support
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: I21089e2c2e9539931c3b780d1569af6e54a4a25c
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-03-02 16:06:51 -05:00
Paul Belanger 0268f33d65 Move user creation to pre step
Change-Id: I83475f38a8fe32f29488169c40e719ea131b6b9e
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-02-16 16:23:01 -05:00
Paul Belanger 95f45fc6df Simplify zuul_install_method include
Change-Id: Ie4999170b782c47a913795284d53f785b6bff531
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-02-13 18:48:44 -05:00
Paul Belanger 866e71d640 Add service manage variables
It is possible that a user will not want the roles to control the
service settings. For example, if a service dies and you don't want to
auto restart it.

Change-Id: I1d99a712984a71f41533cadda317c13f03b9f779
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-02-04 10:42:53 -05:00
Paul Belanger 0cd7181a63 Switch to package module
This will help reduce duplicate code.

Change-Id: Icf8729a53dfa046e8dbdcc15faa7579b995f4081
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-02-02 12:54:35 -05:00