Commit Graph

193 Commits

Author SHA1 Message Date
Andrei Kvapil
e8eb5fd397 Add opencost
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-08-05 15:35:56 +02:00
Andrei Kvapil
e54608d8dd Fix ingress forward both 80 and 443 ports to tenant clusters (#243) 2024-07-30 19:09:41 +02:00
Andrei Kvapil
4f6d33aaa8 remove kubeovn ependency from distro-full bundle (#240) 2024-07-26 18:31:01 +02:00
Mr Khachaturov
a17c622b00 Add snapshot-controller (#237)
Added snapshot-controller to system packages. 

It is included in pass-full bundle. 
Also added new cluster issuer `selfsigned-cluster-issuer`.
2024-07-26 18:27:34 +02:00
Andrei Kvapil
ac11056e0a Prepare release v0.10.1 (#238)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-26 13:58:08 +02:00
Andrei Kvapil
32f22adb26 ingress forward both 80 and 443 ports to tenant clusters (#235)
We need to separate HTTP and HTTPS traffic and send them into tenant
clusters.
Currently traffic was sending only on HTTPS port, this PR enables HTTP
traffic forwarding.

Nginx ingress does not support setting correct upstream according to
type of traffic (http or https)
There are set of issues in upstream.

- https://github.com/kubernetes/ingress-nginx/issues/1655
- https://github.com/kubernetes/ingress-nginx/issues/9061
- https://github.com/kubernetes/ingress-nginx/issues/11334

Good to know that we found reliable workaround

fixes:
https://github.com/aenix-io/cozystack/issues/209#issuecomment-2215021489
v0.10.1
2024-07-26 12:01:28 +02:00
Andrei Kvapil
4c5a37d75b Kubernetes: fix node-role labels propogation (#234)
fixes https://github.com/aenix-io/cozystack/issues/209
2024-07-26 12:01:13 +02:00
Andrei Kvapil
7ad3725dad Fix kubelet garbage collection and introduce ephemeralStorage parameter (#239)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-26 12:00:42 +02:00
Marian Koreniuk
9f61510543 Merge pull request #236 from aenix-io/upd-nginx-ingress
Update ingress-nginx-controller v1.11
2024-07-26 12:19:29 +03:00
Andrei Kvapil
757caee765 Update ingress-nginx v1.11
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-26 10:07:36 +02:00
Andrei Kvapil
e97160918f Prepare release v0.10.0 (#230)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
v0.10.0
2024-07-23 18:58:08 +02:00
Andrei Kvapil
95b11a1082 Update etcd-operator v0.4 (#232)
This update enables resize operation for etcd clusters

https://github.com/aenix-io/etcd-operator/pull/254
2024-07-23 17:53:49 +02:00
Andrei Kvapil
d0758692d1 Fix Kafka topics creation (#231)
this PR fixes an error:
```spec.replicas: Invalid value: "string": spec.replicas in body must be of type integer```

---------

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-23 12:15:16 +02:00
Andrei Kvapil
bad59ec444 Add option to enable dashboard in ingress-nginx (#229)
Add option to enable dashboard in ingress

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-22 23:35:16 +02:00
Andrei Kvapil
ceefae03e9 Add network policies to enforce tenant isolation (#228)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-22 23:32:54 +02:00
Andrei Kvapil
5b39ced0a1 Add NATS (#224)
Very basic NATS application

![Screenshot 2024-07-19 at 14 33
54](https://github.com/user-attachments/assets/3e4e1df3-b548-434e-aaca-a09fb2642284)

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-22 23:31:56 +02:00
Andrei Kvapil
ec283c33a4 postgres: automatically set schema permissions (#216)
This PR refactors postgress configuration script:
- Added event trigger on creating new schemas for automatically set
owner
- Refactored logic for fixing permissions for all objects in all schemas

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-22 23:31:32 +02:00
Mr Khachaturov
8319a00193 Nginx whitelist and clouflareProxy (#211)
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
Co-authored-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-22 12:43:32 +02:00
Marian Koreniuk
c6e1e4e4b8 Merge pull request #223 from aenix-io/cozy-rename
Rename system releases to have -system suffix
2024-07-19 13:32:31 +02:00
Andrei Kvapil
af75a32430 fix kubevirt infrastructure-provider version (#225)
Fix wrong version for KubeVirt CAPI provider

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-19 13:30:23 +02:00
Andrei Kvapil
c9e0d63b77 Rename system releases to have -system suffix
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-19 12:26:17 +02:00
Andrei Kvapil
7c77a6594a Unsuspend system helmreleases on cozystack restart (#219)
Developers ofthen forget to unsuspend helm releases after the local
development (I do!)
This change make ensure that all system helm charts are getting
reconciled by flux after cozystack container restart

Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-18 20:55:24 +03:00
Marian Koreniuk
9bbdb11aab Merge pull request #218 from aenix-io/logos
Ship all logos with Cozystack
2024-07-18 19:53:20 +02:00
Andrei Kvapil
bbd2ca81a3 fix: ferretdb set schedma owner (#220)
undefined
2024-07-17 12:48:43 +02:00
Andrei Kvapil
e265e8bc43 Ship all logos with Cozystack
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-16 17:31:52 +02:00
Marian Koreniuk
5261145b2d Merge pull request #217 from aenix-io/ferretdb
FerretDB
2024-07-16 12:52:37 +02:00
Andrei Kvapil
4ffa861534 add ferretdb
Signed-off-by: Andrei Kvapil <kvapss@gmail.com>
2024-07-16 10:23:27 +02:00
Andrei Kvapil
07d666c0be fix: scraping ingress-nginx metrics (#212)
Now grafana dashboards for ingress-nginx controller completely works!

![pic](https://github.com/user-attachments/assets/c2414cc7-9e0c-441e-9668-bf78ea3ef0c6)

![pic](https://github.com/user-attachments/assets/8ebe2488-0c53-4fc8-9e26-fc37e0047ebe)

![pic](https://github.com/user-attachments/assets/675a47b8-0304-4c58-9379-75e23c2db90f)
2024-07-16 08:06:16 +02:00
Andrei Kvapil
5bbc488e9c Prepare release 0.9.0 (#207) v0.9.0 2024-07-10 20:25:29 +02:00
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