gravitational/gravity

RuntimeEnvironment overrides ClusterConfiguration

Ahmadabed83 opened this issue · 0 comments

Description

What happened:

The following cluster configurations have been applied to override the default feature-gates ( using the command gravity resource create -f cluster-config.yaml ):

kind: ClusterConfiguration
version: v1
spec:
  global:
    featureGates:
      AllAlpha: true
      RotateKubeletServerCertificate: false

Then, RuntimeEnvironment has been updated ( also using the gravity resource create -f runtime-config.yaml )

kind: RuntimeEnvironment
version: v1
spec:
  data:
    KUBE_CONTROLLER_MANAGER_FLAGS: "--allocate-node-cidrs=true --terminated-pod-gc-threshold=10"
    KUBE_APISERVER_FLAGS: "--request-timeout=300s --disable-admission-plugins=NamespaceLifecycle"

What you expected to happen:
RuntimeEnvironment should be applied and should not affect the old ClusterConfiguration applied in the previous step.
While what happened in our case is that KUBE_COMPONENT_FLAGS has been reset to the defaults after applying the RuntimeEnvironment changes.

How to reproduce it (as minimally and precisely as possible):

  • Create a cluster
  • Apply the mentioned ClusterConfiguration ( to change feature-gates )
  • Apply the mentioned RuntimeEnvironment ( to override some API/CONTROLLER envs )
  • Check kube-controller feature-gates ,

Environment

  • Gravity version [7.0.25]:
  • OS [Ubuntu 20.04]:
  • Platform [DigitalOcean VM]: