Commit Graph

164 Commits

Author SHA1 Message Date
Andrei Kvapil
4cbc8a2c33 Upgrade tenant Kubernetes v1.30.1 (#206)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-08 22:51:50 +02:00
Andrei Kvapil
9709059fb7 kubernetes: Allow upgrading existing node groups (#205)
This PR introduces change to allow upgrading existing node groups for
tenant Kubernetes cluster:

This fixes the error:
```
Status: Failed (UpgradeFailed: Helm upgrade failed for release tenant-test0/kubernetes-test0 with chart kubernetes@0.3.0: cannot patch "kubernetes-test0-md0" with kind KubevirtMachineTemplate: admission webhook "validation.kubevirtmachinetemplate.infrastructure.cluster.x-k8s.io" denied the request: KubevirtMachineTemplateSpec is immutable)
```

This is done by generating unique names for KubevirtMachineTemplate
based on hash from spec. Old KubevirtMachineTemplates keep existing in
the cluster until some MachineSet continues using them.

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-08 22:49:35 +02:00
Andrei Kvapil
4ec770996e Update Piraeus v2.5.1 (#204) 2024-07-08 22:47:10 +02:00
Andrei Kvapil
4972906e7a Update Cluster API and hardcode versions (#203)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-08 22:44:49 +02:00
Andrei Kvapil
2ea5e8b1a6 Update Kamaji v1.0.0 (#202)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-08 20:16:23 +02:00
Andrei Kvapil
db1d5cdf4f Update KubeVirt v1.2.2 (#201)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-08 20:16:12 +02:00
Kingdon Barrett
8664d5748e Fix nginx error related to passthrough TLS (#208)
I don't understand why "true" value isn't accepted here, but I have seen
this before. The `--enable-ssl-passthrough` parameter is not supposed to
accept any value, it's a stand-alone argument.

With this change I get my traffic appropriately passed through to
backend ingress on a kubevirt cluster that enabled TLS

Without it (the change is made on the addon ingress, which is very
strange, because that one isn't even configured to use a passthrough
annotation... the root ingress controller doesn't seem to care) I get
this error:

> 400 Bad Request
> The plain HTTP request was sent to HTTPS port
> ---
> nginx

Signed-off-by: Kingdon Barrett <kingdon+github@tuesdaystudios.com>
2024-07-08 18:46:40 +02:00
Kingdon Barrett
7a3e9f574c Fix nginx config error parsing configmap (#200)
The error manifests as:

W0705 16:07:35.694677 7 configmap.go:431] unexpected error merging
defaults: 2 error(s) decoding:

* cannot parse 'proxy-connect-timeout' as int: strconv.ParseInt: parsing
"10s": invalid syntax
* cannot parse 'proxy-read-timeout' as int: strconv.ParseInt: parsing
"10s": invalid syntax

I came across this trying to understand why my nginx ingress addon
config isn't working, (this didn't help, but at least the warning is
gone now.)

I'll continue to try to debug, but I think this can merge any time

Signed-off-by: Kingdon Barrett <kingdon+github@tuesdaystudios.com>
2024-07-08 18:02:56 +02:00
Andrei Kvapil
dfbc210bbd hotfix: handle missing flux-operator release during upgrade (#198)
image to test:

```
ghcr.io/aenix-io/cozystack/cozystack:v0.8.0@sha256:48e9f676f4eca5f7036648a56767c31beb0aca8fdc6d6798bd65de74886ed1ef
```


this PR should fix a problem of upgrading from older cozystack version

```
make: Leaving directory '/cozystack/packages/core/platform'
deployment.apps/source-controller condition met
deployment.apps/helm-controller condition met
Error from server (NotFound): helmreleases.helm.toolkit.fluxcd.io "fluxcd" not found
NAME                                        CREATED AT
helmreleases.helm.toolkit.fluxcd.io         2024-05-29T11:00:16Z
helmrepositories.source.toolkit.fluxcd.io   2024-05-29T11:00:17Z
make: Entering directory '/cozystack/packages/system/fluxcd-operator'
kubectl patch hr -n cozy-fluxcd fluxcd-operator -p '{"spec": {"suspend": true}}' --type=merge --field-manager=flux-client-side-apply
Error from server (NotFound): helmreleases.helm.toolkit.fluxcd.io "fluxcd-operator" not found
make: *** [../../../scripts/package-system.mk:20: suspend] Error 1
make: Leaving directory '/cozystack/packages/system/fluxcd-operator'
time="2024-07-04T12:50:05Z" level=fatal msg="failed to run" err="exit status 2"
```
v0.8.0
2024-07-04 16:18:02 +03:00
Andrei Kvapil
3ac170184e Fix: kafka replicas and partitions (#192)
Fix kafka app to unhardcode partitions number
fixes problem with unability to specify number of partitions and
replicas for them

also possible fixes https://github.com/aenix-io/cozystack/issues/163

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-04 14:16:23 +02:00
Andrei Kvapil
15478a8807 Prepare release v0.8.0 (#194)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-04 10:32:26 +02:00
Andrei Kvapil
b23ad47f51 Update etcd-operator v0.3.1 (#197) 2024-07-04 10:25:58 +02:00
Kingdon Barrett
2ab9a386cd Fine-tuning Flux configuration (#196)
Fix #195

Don't set the `interval` so short on HelmReleases, with this many
HelmReleases that really hamstrings the control plane.

Also, copy the install/upgrade remediation config from system packages
to the Kubernetes templates for addon packages (cilium, flux, ingress) -
in my testing the ingress-nginx chart fails every time the first time.
Maybe that should be filed as a separate issue, I haven't looked into
detail, it is some issue related to a secret not being created, I think
it said something related to an admission controller.

Looks as though it's a conflict with being installed at the same time as
the cert-manager addon.

Signed-off-by: Kingdon Barrett <kingdon+github@tuesdaystudios.com>
2024-07-04 02:28:57 +02:00
Marian Koreniuk
7072ed98be Merge pull request #193 from aenix-io/upd-etcd-operator
Update etcd-operator v0.3.0
2024-07-03 16:36:04 +02:00
Andrei Kvapil
a798afc7e8 Update etcd-operator v0.3.0
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-03 16:28:24 +02:00
Marian Koreniuk
60c608cb00 Merge pull request #186 from aenix-io/tenant-nginx-ingress
Update Tenant Kubernetes Addons
2024-06-28 09:04:06 +02:00
Kingdon Barrett
07384c40f8 Tenant nginx ingress (fixes) (#191)
I am testing install with this PR #183 and I had some issues, these
should help

---------

Signed-off-by: Kingdon Barrett <kingdon+github@tuesdaystudios.com>
2024-06-28 09:02:41 +02:00
Andrei Kvapil
7462be79be add fluxcd addon 2024-06-26 03:12:21 +02:00
Andrei Kvapil
c01604fb7f fix typo in cert-manager addon 2024-06-26 03:10:09 +02:00
Andrei Kvapil
c22a6792c2 add tenant nginx-ingress
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-26 03:09:35 +02:00
Andrei Kvapil
a2cc83ddc4 move fluxcd and operator back to system (#188)
Separate and move fluxcd and fluxcd-operator from `core` to `system`.

It should not be problem with self-update now, since we correctly set
dependsOn option, it ensures ordered update of flux instance right after
flux-operator.

As part of https://github.com/aenix-io/cozystack/issues/184 and
https://github.com/aenix-io/cozystack/issues/185
fixes https://github.com/aenix-io/cozystack/issues/169

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-26 02:49:14 +02:00
Andrei Kvapil
cf1d9fabf4 add fluxcd labels post processor (#180)
This PR introduces a new fluxcd-kustomize.sh script that can be used as
post-processor for helm for adding a common fluxcd labels.

This is very useful for `make diff`, so it will not include diff between
these labels anymore

Also for debugging specific kustomize cases, eg:
- https://github.com/fluxcd/helm-controller/issues/283
- https://github.com/fluxcd/flux2/issues/4368

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-25 19:23:20 +02:00
Andrei Kvapil
91a1f4917c fix: ingress-nginx duplicate template (#182)
in addition to https://github.com/aenix-io/cozystack/pull/181
2024-06-25 17:33:28 +02:00
Marian Koreniuk
18579abdcd Merge pull request #183 from aenix-io/tenant-nginx-ingress
Managed tenant nginx ingress controller
2024-06-25 17:32:31 +02:00
Andrei Kvapil
6bd2d45531 add tenant nginx-ingress
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-25 15:50:43 +02:00
Andrei Kvapil
2145f41c7f Use patch with --no-backup-if-mismatch (#181)
Add option `--no-backup-if-mismatch` to every patch command, so it will
not create .orig and .diff files anymore
2024-06-25 14:33:07 +02:00
Kingdon Barrett
d841a20635 Fix typo (#179)
Signed-off-by: Kingdon Barrett <kingdon+github@tuesdaystudios.com>
2024-06-25 11:53:31 +02:00
Andrei Kvapil
246b44945e add certManager addon
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-25 11:08:00 +02:00
Andrei Kvapil
352920ea7e Merge pull request #170 from aenix-io/upd-flux
This cumulative PR includes the following changes:

- Migrate from fluxcd-community charts to Flux-Operator #166
- Upgrade to Flux 2.3.x #167
- Refactor Flux 2.3 update #172
- Update flux plugin for dashboard #171
- Flux Operator 0.6 #178
2024-06-24 15:33:27 +02:00
Kingdon Barrett
73b6f7f962 Flux Operator 0.6 (#178)
This PR upgrades to Flux-Operator 0.6 released this morning, also includes:

* #170
which is an aggregate PR, so #171 #172 etc. I think this PR now basically subsumes #170 and can replace it.

I have at least 80% confidence there are no errors in this PR. It also restores the networkPolicy default and the deleted cozy-dashboard network policy, which we will see fixed (restored to install NetworkPolicy resources by default) in the next `flux-operator` release.

Ref: https://github.com/controlplaneio-fluxcd/flux-operator/pull/52
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-24 13:35:26 +02:00
Andrei Kvapil
b8e5309fc4 Refactor fluxcd 2.3 update (#172)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-24 13:14:11 +02:00
Andrei Kvapil
97bd1634a7 Merge branch 'main' into upd-flux 2024-06-24 13:13:54 +02:00
Marian Koreniuk
33a9cb7358 Merge pull request #176 from aenix-io/initial-arm
Add initial ARM support
2024-06-21 14:51:09 +02:00
Marian Koreniuk
e6d60886b4 Merge pull request #177 from aenix-io/postgres-quorum
postgres: option to enable quorum-based replication
2024-06-21 11:25:30 +02:00
Andrei Kvapil
995dea6f5c postgres: option to enable quorum-based replication
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-21 10:12:32 +02:00
Andrei Kvapil
f12e2c300a add initial arm support
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-20 13:51:56 +02:00
Marian Koreniuk
1519f40767 Merge pull request #171 from aenix-io/flux-plugin-for-dashboard
Update flux plugin for dashboard
2024-06-19 16:57:46 +02:00
Andrei Kvapil
02a41e126b fix kubeovn and cilium tags (#174)
* fix: kube-ovn tag

* fix: cilium tag
2024-06-19 16:55:16 +02:00
Marian Koreniuk
2d40c8507b Merge pull request #165 from aenix-io/e2e
Add e2e tests
2024-06-17 19:14:42 +02:00
Marian Koreniuk
bcd1ee1b4f Add masquerade 2024-06-17 19:13:54 +02:00
Andrei Kvapil
2dd2b079b2 Update flux-plugin for dashboard
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-17 19:00:30 +02:00
Andrei Kvapil
3a0bad04b9 add check for forwarding and masquerading
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-17 18:17:08 +02:00
Kingdon Barrett
931e39fb5c Upgrade to Flux 2.3.x (#167)
Signed-off-by: Kingdon Barrett <kingdon+github@tuesdaystudios.com>
Co-authored-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-17 16:02:32 +02:00
Kingdon Barrett
54017b6e3e Migrate from fluxcd-community charts to Flux-Operator (#166)
Signed-off-by: Kingdon Barrett <kingdon+github@tuesdaystudios.com>
2024-06-17 15:58:13 +02:00
Andrei Kvapil
838bee5d25 Allow specify externalIPs for nginx-ingress (#164) 2024-06-14 15:28:10 +02:00
Andrei Kvapil
eedc4ebce1 Add e2e tests
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-06-12 19:47:36 +02:00
Andrei Kvapil
b30a9a6fcf fix: dependsOn kubeovn and cilium in -hosted bundles (#161) 2024-05-30 23:54:39 +03:00
Andrei Kvapil
8019256dfc Fix: clickhouse user login (#160) 2024-05-29 17:57:03 +02:00
Andrei Kvapil
d7cfa53cd4 Prepare release v0.7.0 (#156) v0.7.0 2024-05-29 10:04:22 +02:00
Andrei Kvapil
d7147c7fe1 kube-ovn: disable cozystack image tag (#153)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-05-27 22:47:12 +02:00