Outdated documentation for addon-resizer command line parameters? [autoscaler] - TagMerge

Outdated documentation for addon-resizer command line parameters? [autoscaler]

kustodianAsked 4 months ago

Which component are you using?: addon-resizer

What version of the component are you using?: Component version: 1.8.13

What k8s version are you using (kubectl version)?:

kubectl version Output
$ kubectl version
Client Version: version.Info{Major:"1", Minor:"22", GitVersion:"v1.22.4", GitCommit:"b695d79d4f967c403a96986f1750a35eb75e75f1", GitTreeState:"archive", BuildDate:"2021-11-18T21:20:32Z", GoVersion:"go1.17.3", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.5-gke.1302", GitCommit:"639f3a74abf258418493e9b75f2f98a08da29733", GitTreeState:"clean", BuildDate:"2021-10-21T21:35:48Z", GoVersion:"go1.16.7b7", Compiler:"gc", Platform:"linux/amd64"}

What environment is this in?: GKE

What did you expect to happen?: If we compare the supported parameters at https://github.com/kubernetes/autoscaler/tree/master/addon-resizer with the output of pod_nanny --help we have a lot of discrepancies:

% podman run -it --rm gke.gcr.io/addon-resizer:1.8.13-gke.0 /pod_nanny --help           
ERROR: logging before flag.Parse: I0114 13:49:02.901812       1 pod_nanny.go:68] Invoked by [/pod_nanny --help]
ERROR: logging before flag.Parse: I0114 13:49:02.901846       1 pod_nanny.go:69] Version: 1.8.13
Usage of /pod_nanny:
      --config-dir string           Path of configuration containing base resource requirements. (default "MISSING")
      --container string            The name of the container to watch. This defaults to the nanny itself. (default "pod-nanny")
      --cpu string                  The base CPU resource requirement.
      --deployment string           The name of the deployment being monitored. This is required.
      --estimator string            The estimator to use. Currently supported: linear, exponential (default "linear")
      --extra-cpu string            The amount of CPU to add per node.
      --extra-memory string         The amount of memory to add per node.
      --extra-storage string        The amount of storage to add per node. (default "0Gi")
      --memory string               The base memory resource requirement.
      --minClusterSize uint         The smallest number of nodes resources will be scaled to. Must be > 1. This flag is used only when an exponential estimator is used. (default 16)
      --namespace string            The namespace of the ward. This defaults to the nanny pod's own namespace.
      --pod string                  The name of the pod to watch. This defaults to the nanny's own pod.
      --poll-period int             The time, in milliseconds, to poll the dependent container. (default 10000)
      --scale-down-delay duration   The time to wait after the addon-resizer start or last scaling operation before the scale down can be performed.
      --scale-up-delay duration     The time to wait after the addon-resizer start or last scaling operation before the scale up can be performed.
      --storage string              The base storage resource requirement. (default "MISSING")
      --threshold int               A number between 0-100. The dependent's resources are rewritten when they deviate from expected by more than threshold.
      --use-metrics                 Whether to use apiserver metrics to detect cluster size instead of the default method of listing node objects from the Kubernetes API.

For example --config-dir is not mentioned anywhere in the documentation.

Source: link

jbartosikAnswered 4 months ago

We don't release Addon Resizer from master, we release it from the addon-resizer-release-1.8 branch. And on https://github.com/kubernetes/autoscaler/tree/addon-resizer-release-1.8/addon-resizer you can find documentation there.

Recent Issues

    Programming Languages