Avoid getting irrelevant logs from rancher-turtles
What does this MR do and why?
Rancher-turtles is the solution responsible to import new workload clusters into rancher, in addition could be use to create/manage clusters throught capi-operator. This feature is disabled in our case, but the application behaviour is to always check if the CRDs related to capi-operator are installed and generate multiple warnings logs which are finally shipped into grafana.
I0724 08:38:52.570224 1 import_controller_v3.go:146] "Reconciling CAPI cluster" controller="cluster" controllerGroup="cluster.x-k8s.io" controllerKind="Cluster" Cluster="ba-rke2/ba-rke2" namespace="ba-rke2" name="ba-rke2" reconcileID="04446194-c0ed-4f6b-98df-21d0d32513ed" <= imported cluster
I0724 08:38:52.570406 1 import_controller_v3.go:333] "agent is ready, no action needed" controller="cluster" controllerGroup="cluster.x-k8s.io" controllerKind="Cluster" Cluster="ba-rke2/ba-rke2" namespace="ba-rke2" name="ba-rke2" reconcileID="04446194-c0ed-4f6b-98df-21d0d32513ed"<= imported cluster
E0724 08:38:59.637111 1 kind.go:71] "if kind is a CRD, it should be installed before calling Start" err="no matches for kind \"AddonProvider\" in version \"operator.cluster.x-k8s.io/v1alpha2\"" logger="controller-runtime.source.EventHandler" kind="AddonProvider.operator.cluster.x-k8s.io" <= warning logs
E0724 08:38:59.642791 1 kind.go:71] "if kind is a CRD, it should be installed before calling Start" err="no matches for kind \"ControlPlaneProvider\" in version \"operator.cluster.x-k8s.io/v1alpha2\"" logger="controller-runtime.source.EventHandler" kind="ControlPlaneProvider.operator.cluster.x-k8s.io"
E0724 08:38:59.647389 1 kind.go:71] "if kind is a CRD, it should be installed before calling Start" err="no matches for kind \"CoreProvider\" in version \"operator.cluster.x-k8s.io/v1alpha2\"" logger="controller-runtime.source.EventHandler" kind="CoreProvider.operator.cluster.x-k8s.io"
The aim of this MR is to exclude those logs and just focus on relevant logs for us ( those ones related to importing phase) and avoid storing useless logs.
Related reference(s)
Test coverage
Only logs about imported clusters state are now present in grafana:
CI configuration
Below you can choose test deployment variants to run in this MR's CI.
Click to open to CI configuration
Legend:
| Icon | Meaning | Available values |
|---|---|---|
| Infra Provider |
capd, capo, capm3
|
|
| Bootstrap Provider |
kubeadm (alias kadm), rke2
|
|
| Node OS |
ubuntu, suse
|
|
| Deployment Options |
light-deploy, dev-sources, ha, misc, maxsurge-0, logging, no-logging
|
|
| Pipeline Scenarios | Available scenario list and description |
-
🎬 preview☁️ capd🚀 kadm🐧 ubuntu -
🎬 preview☁️ capo🚀 rke2🐧 suse -
🎬 preview☁️ capm3🚀 rke2🐧 ubuntu -
☁️ capd🚀 kadm🛠️ light-deploy🐧 ubuntu -
☁️ capd🚀 rke2🛠️ light-deploy🐧 suse -
☁️ capo🚀 rke2🛠️ ha,logging🐧 suse -
☁️ capo🚀 kadm🐧 ubuntu -
☁️ capo🚀 rke2🎬 rolling-update🛠️ ha🐧 ubuntu -
☁️ capo🚀 kadm🎬 wkld-k8s-upgrade🐧 ubuntu -
☁️ capo🚀 rke2🎬 rolling-update-no-wkld🛠️ ha🐧 suse -
☁️ capo🚀 rke2🎬 sylva-upgrade-from-1.4.x🛠️ ha🐧 ubuntu -
☁️ capo🚀 rke2🎬 sylva-upgrade-from-1.4.x🛠️ ha,misc🐧 ubuntu -
☁️ capo🚀 rke2🛠️ ha,misc🐧 ubuntu -
☁️ capm3🚀 rke2🐧 suse -
☁️ capm3🚀 kadm🛠️ ha,logging🐧 ubuntu -
☁️ capm3🚀 kadm🎬 rolling-update-no-wkld🛠️ ha,misc🐧 ubuntu -
☁️ capm3🚀 rke2🎬 wkld-k8s-upgrade🛠️ ha🐧 suse -
☁️ capm3🚀 kadm🎬 rolling-update🛠️ ha🐧 ubuntu -
☁️ capm3🚀 rke2🎬 sylva-upgrade-from-1.4.x🛠️ ha🐧 suse -
☁️ capm3🚀 rke2🛠️ misc,ha🐧 suse -
☁️ capm3🚀 rke2🎬 sylva-upgrade-from-1.4.x🛠️ ha,misc🐧 suse -
☁️ capm3🚀 kadm🎬 rolling-update🛠️ ha🐧 suse -
☁️ capm3🚀 ck8s🎬 no-wkld🛠️ light-deploy🐧 ubuntu
Global config for deployment pipelines
-
autorun pipelines -
allow failure on pipelines -
record sylvactl events
Notes:
- Enabling
autorunwill make deployment pipelines to be run automatically without human interaction - Disabling
allow failurewill make deployment pipelines mandatory for pipeline success. - if both
autorunandallow failureare disabled, deployment pipelines will need manual triggering but will be blocking the pipeline
Be aware: after configuration change, pipeline is not triggered automatically.
Please run it manually (by clicking the run pipeline button in Pipelines tab) or push new code.
