180 Commits

Author SHA1 Message Date
Zuul
1c627c53c5 Merge "Switch logo color in docs pages to dark blue" 2024-11-13 00:55:16 +00:00
Jeremy Stanley
e45afea87c Switch logo color in docs pages to dark blue
The trademark for the logo, as filed, is specified as dark blue.
That logo needs to be displayed in a user guide or manual or
alongside a direct download of the software in order to demonstrate
continued use of the mark, and the foundation's trademark lawyers
have expressed concern that a white version is insufficient (but
they seem to be okay with the current background color as long as
the lines of the logo are colored similar to the version on file).

This is a copy of the equivalent change from the zuul repository.

Co-Authored-By: James E. Blair <jim@acmegating.com>
Depends-On: https://review.opendev.org/934443
Change-Id: I95e31e8ff4e91ef022a08d57b2763c5ec1e39e2d
2024-11-12 19:04:37 +00:00
Michael Kelly
9590d5a55b
conf: Handle app_key correctly for GitHub connections
app_key is expected to be a file path, not a value in the
configuration file.

Change-Id: Ibf0641cd31148749477003ced574410178cace7c
2024-11-07 17:56:58 -08:00
Michael Kelly
c1febff1ea
Fix CI failures
This change fixes a few CI failures in the zuul-operator

* nox docs: the regex expression wasn't accepted
* version.py was broken because pkg_resources is removed from newer
  pythons
* the /api/tenants endpoint no longer appears to return projects or
  queue items so the functional test was failing

Change-Id: Ia492fa48ff682454553d9c1b04d4e83b40a276cf
2024-11-07 17:55:22 -08:00
Clark Boylan
3cff35ce48 Convert container to Bookworm + Python3.11
This matches what Zuul and Nodepool are doing. Getting off the older
images will alos allow OpenDev to stop building them. We update the
unittest job to python 3.11 in the process to better cover what people
will deploy.

Change-Id: Id631909640b015ffff9660f33a85c1b1bac375f8
2024-10-07 13:50:13 +00:00
Damian Fajfer
fef7c272f7 Fix schema for env variables
Operator expects a {name,value} object, so we were unable to set envs with the existing CRD schema

Change-Id: Icf81caea3e141c56b0669e901dd1175c2b3465fe
2024-08-22 12:23:32 +00:00
Jan Gutter
b723bc761b
Publish zuul-operator to quay.io
* non-ci tested scripts need updating - these are intended for
  local development workflows.
* This now publishes the operator to quay.io/zuul-ci
* This is mostly a rework of
  https://review.opendev.org/c/zuul/zuul-operator/+/881245 and
  https://review.opendev.org/c/zuul/zuul-operator/+/924870
  with much appreciation and credits to original authors

Change-Id: I0ffd39fceeaf4947ed329dd4ddb7283cdc98df86
2024-08-18 12:32:57 +01:00
Jan Gutter
c74b147fe7
CI Fixes and dependency updates
These are mostly CI fixes:

* Use podman+cri-o based minikube:
  * This is still considered experimental, but seems to be
    more supported than the 'none' driver.
* Fix an issue where ssh to the emulated static node fails:
  * PAM needed to be disabled for openssh
  * openssh needs more permissions to run - cri-o based minikube
    is more strict
* Rebase test container to Fedora 40
* Update the ingress definition to current API version
* Update zookeeper from 3.5.5 to 3.8.4:
  * required for nodepool 9.0.0+
* Update the percona operator from 1.11 to 1.14:
  * required for kubernetes 1.24+
* Update test node to Ubuntu Jammy from Ubuntu Bionic
* Update minikube to 1.33.1
* Added some more explicit logging to the k8s state, this
  could be split off into a role in future.

Depends-On: https://review.opendev.org/c/zuul/zuul-jobs/+/924970

Change-Id: I7bf27750073fa807069af6f85f2689173b278abe
2024-08-15 10:25:39 +01:00
Michael Kelly
273da661db
Add remaining nox sessions based on tox.ini
This change introduces venv and bindep sessions based on the same
testenvs from tox.ini.

Change-Id: I4d2c92d8cd9e96cbcd1b54c6b4b565aedc9a60e3
2023-02-24 21:04:59 -08:00
Michael Kelly
c6b7308c68
Convert linters from tox to nox
This expands the noxfile to include the linters session and switches
the tox-linters job with the nox-linters job.

Change-Id: If5ff34aded40c66667eaa468baea10fb2658e2b3
2023-02-24 21:00:46 -08:00
Michael Kelly
b653e6e20a
Convert docs from tox to nox
Using https://review.opendev.org/c/zuul/zuul/+/867057/13 and
https://review.opendev.org/c/zuul/zuul/+/868229/1 as rough templates,
introduced a noxfile and switched over the docs jobs to use nox
instead of tox.

Change-Id: I25e653189f37d28d4947ac90a6f5293939377192
2023-02-24 20:50:29 -08:00
Michael Kelly
ac2488d242
Allow the specification of storageClassName in PVCs
Not every cluster has a default storage class and even if they do, we
don't always want to use that default storage class for our persistent
volumes.  Instead, allow the user to specific this via the cluster
configuration itself for the three cases we require (zookeeper,
scheduler, and registry).

Change-Id: I948d57ce59d9b16c1c70fc52af2e22bd6131e6e2
2022-11-02 22:33:08 -07:00
Zuul
8b05b31a06 Merge "Update the docker images to python 3.10" 2022-10-18 19:07:15 +00:00
Clark Boylan
5873797641 Update the docker images to python 3.10
Do this to take advantage of python 3.10's speed improvements as
illustrated by Zuul proper. But als OpenDev is looking at dropping
python 3.8 image builds to make room for python 3.11.

Change-Id: I0bb4902d32003ab8e8fb35e6cc39e62ceed88aa8
2022-10-14 14:48:00 -07:00
Michael Kelly
d2b2393d52
Only listen for updates to known secrets
@kopf.on.update('secrets') will cause us to attempt to listen to
updates to every secret in the Kubernetes cluster in which we are
running.  This is negative because:

* kopf annotates every object it is watching to track last known
  state, which will be *every secret in the cluster* if with the
  current approach.  This is a somewhat obnoxious behaviour.

* if the operator is not running with elevated priviledges, this may
  not work correctly anyway, although the current deployment does
  provide the operator user with cluster-admin priviledges

Instead, we should only track the secrets that we've expressed
interest in, which is effectively what we're doing anyway, but this
will save us from annotating every secret in the cluster.

Change-Id: I540841ee8b053ae05ca7943aca3f1646b509cfd9
2022-10-14 08:39:51 -07:00
Michael Kelly
4f51fc7da3
kopf: Upgrade kopf to at least 1.35.0
Upgrade from 1.30.* to 1.35.0 or later.  The minimum bound is
introduced because earlier versions of kopf may not work correctly
with the operator.

Change-Id: I2b40e223f48aca6f45d901e1cc1ee67cf27e486f
2022-10-14 08:38:56 -07:00
Zuul
ab00ececc4 Merge "Update CRD apiVersion to v1 (from v1beta)" 2022-08-22 15:54:53 +00:00
Michael Kelly
a5da3f075e
Convert base64 encoded value to string
If we leave the value has as the result of b64decode(), we end up with
a bytes-like object that gets serialized into our zuul.conf as
b'.....', which is likely not what we actually want.  Instead, assume
this is a utf-8 encoded value and decode it that way.

Change-Id: Ie61ad82c022888000e72bedfea99123dda34d5c0
1.0.0
2022-08-17 20:49:22 -07:00
Tristan Cacqueray
8c6ad5f431 Update CRD apiVersion to v1 (from v1beta)
This change enables installing the zuul-operator on a recent cluster,
where CRD are no longer beta:

- Update apiVersion in the CRD
- Update cert-manager to v1.8.2
- Update pxc to v1.10.0
- Add openAPIV3Schema to zuul crd (from https://review.opendev.org/c/zuul/zuul-operator/+/800302)

Change-Id: I12ac02d609ea6a2806c734ca00023e4d1059af37
2022-06-30 18:45:23 +00:00
Zuul
a87052d3c7 Merge "Remove CONTRIBUTE.md documentation" 2022-06-30 18:31:08 +00:00
Zuul
c1852c5791 Merge "Remove gearman configuration" 2022-06-30 18:30:27 +00:00
Tristan Cacqueray
eddd0b72ea Remove gearman configuration
The service is no longer used.

Change-Id: Ifa0052356e9d143c8858e087e1f482c0fe804b44
2022-06-28 14:02:38 +00:00
Albin Vass
61ccd501c8 Gracefully shutdown executor on SIGTERM
Depends-On: https://review.opendev.org/c/zuul/zuul/+/799701
Change-Id: Id8d9208ee5d5c2c76b181657af0f7a4497c159ec
2022-06-27 22:41:18 +00:00
Tristan Cacqueray
ed3e8cd385 Remove CONTRIBUTE.md documentation
The file is outdated.

Change-Id: I5d1ab147c8b8265c658b53e306ff243aad8ecfb9
2022-06-27 22:08:03 +00:00
Tristan Cacqueray
63685df30b Pin pykube-ng and fix the CI
This change tries to fix the following issue:
  kubernetes.config.config_exception.ConfigException: Invalid kube-config file. No configuration found.

This change also provides input to the wsdump test to prevent the
command from hanging when testing the console stream connection.

Change-Id: I4880e0420b7a66639258aa84a8d61b5620313ee3
2022-06-27 22:04:14 +00:00
James E. Blair
88d532ea6e Correct tagged version docs build
A variable reassignment in conf.py caused errors when we try to build
release versions of docs.  Correct that by swapping the order of use
and assignment.

Change-Id: I971b04156e8e7be18fdec6859e4b696f5dd3d7da
2022-03-21 10:27:57 -07:00
Zuul
023f6f0f6c Merge "Fix zuulRegistryImageVersion" 2022-01-25 15:36:49 +00:00
Zuul
8e85b8968b Merge "Add support for imagePullSecrets" 2022-01-25 15:36:47 +00:00
James E. Blair
124f9ed670 Switch docs theme to versioned RTD
To match change I2870450ffd02f55509fcc1297d050b09deafbfb9 in Zuul.

Change-Id: I6a9ae9aafc92444191262010f039afa5d6229082
2021-12-16 11:22:21 -08:00
James E. Blair
547f6a1b4c Fix zuulRegistryImageVersion
This variable wasn't being used, but should be.

Change-Id: I6621b345cc44d782b5b654406b2747f758450fce
2021-10-01 16:46:43 -07:00
James E. Blair
fe827fbeb0 Add support for imagePullSecrets
Since we support custom image prefixes, we should also support
imagePullSecrets since they are likely to be in a private registry.

This also updates some nearby documentation which was out of date.

Change-Id: Id43382284a9adde877e2383644a31bda24030b2b
2021-10-01 16:38:36 -07:00
James E. Blair
d65ebc6bff Update doc theme settings to match Zuul
This makes the sidebar match the rest of Zuul.

Change-Id: I1ed6f71918d9a4d531ab953ba95e0232d3397e8a
2021-09-09 07:34:46 -07:00
James E. Blair
5bf96c1e30 Fix functional test job
* Pin minikube to 1.22.0

Version 1.23.0 is failing with
  error: unable to recognize "deploy/crds/zuul-ci_v1alpha2_zuul_crd.yaml":
    no matches for kind "CustomResourceDefinition" in version "apiextensions.k8s.io/v1beta1"

Until we learn more, pin to the previously working k8s version.

* Add debug log-level to the podman login test command

This change should improve the test failure debugging where it
currently may just prints "Shutting down, got signal: Terminated".

* Remove "https://" from registry login

f8136e70f9
Added path-based authentication to "podman login" which they argue
is incompatible with including https:// in the registry identifier.
Doing so now produces an error.

Co-Authored-By: Tristan Cacqueray <tdecacqu@redhat.com>
Change-Id: Ic44b56a2eb6ac15cc5f4af5312fa4e3956d6e457
2021-09-09 07:29:00 -07:00
Zuul
abf47aba32 Merge "Fix config update detection" 2021-08-18 22:03:50 +00:00
Zuul
346e3c19f7 Merge "Document externalConfig" 2021-08-18 21:58:52 +00:00
Zuul
b62faddca7 Merge "Fix wait for scheduler to settle in tests" 2021-08-17 23:36:11 +00:00
Zuul
8ad92f242e Merge "Make nodepool external_config mount more generic" 2021-08-17 11:53:35 +00:00
James E. Blair
3ee16a7b2f Fix wait for scheduler to settle in tests
The log line that we should wait for has changed in Zuul; this is
the new equivalent.

Change-Id: I34fc52729fa64bb36c72fe6661f0794620a25092
Depends-On: https://review.opendev.org/c/zuul/zuul/+/804806
2021-08-17 00:10:42 +00:00
Zuul
b977aa9e12 Merge "Configure debug logs for merger" 2021-08-05 17:42:54 +00:00
Zuul
954b4060a2 Merge "Set component command with args instead of command" 2021-08-05 17:42:53 +00:00
Zuul
345cda5b66 Merge "Mount connection sshkeys on executors and mergers" 2021-08-05 17:42:52 +00:00
Zuul
d79e4235dc Merge "Add static node to functional test" 2021-08-05 17:42:51 +00:00
James E. Blair
900528164e Fix config update detection
We are supposed to update zuul/nodepool when the relevant secrets
are updated.  We do that by subscribing to changes on all secrets
in the system, then check to see if they are ones that we're watching
and if so, run the appropriate operator methods.

We only updated the list of secrets to watch on startup, which means
that from a clean start where a zuul was added, we would not add
the new secrets to our list.  This change updates the list after every
time that the zuul resource is created or updated.

Change-Id: Ib6191367eb2596eba560b9c570140f33866c005f
2021-08-05 07:35:09 -07:00
James E. Blair
693cb8e5d8 Document externalConfig
Change-Id: I14c80386553570e4449e82170b0d924085742ee9
2021-08-05 07:35:08 -07:00
Albin Vass
5c3eca7d7f Make nodepool external_config mount more generic
This instead mounts every key under externalConfig to /etc/<key>

Change-Id: I6d95a7c71e7da4807cfe5621fc427c6762c58ecf
2021-08-05 07:35:07 -07:00
Albin Vass
40f13b5ca9 Configure debug logs for merger
Change-Id: I3552597d08b9e2fca04132f2a2b0b4d904973346
2021-08-05 07:35:06 -07:00
Albin Vass
da43acd1fd Set component command with args instead of command
Otherwise dumb-init is overriden as the entrypoint.

Change-Id: Ied532a3be46a40369f9bea758871cb3e2080bb51
2021-08-05 07:35:05 -07:00
Albin Vass
e39d82975e Mount connection sshkeys on executors and mergers
Change-Id: I1628b2d4efe4ed949c70a0a96a5a06c037495a09
2021-08-05 07:35:04 -07:00
James E. Blair
97aa27080f Add static node to functional test
So that we can better test functions related to ssh connectivity,
add a static node to the functional test.

Change-Id: I3dfdaca0b4e5dbfb35e4a645c7bcb56e0eec88c2
2021-08-05 07:34:49 -07:00
Zuul
d5c046d107 Merge "Add instructions and tools for running tests with kind" 2021-07-30 00:06:32 +00:00