Commit Graph

35 Commits

Author SHA1 Message Date
Akihiro Suda 9685938ad2 kubelet: config: add userNamespaces.idsPerPod
IDsPerPod is the mapping length of subids for UserNS.
The length must be multiple of 65536.
Default: 65536

Implements kubernetes/enhancements PR 5020 (addendum to KEP-127)

Signed-off-by: Akihiro Suda <akihiro.suda.cz@hco.ntt.co.jp>

Kubernetes-commit: 1592bfa4a81182ffb2ad599d600778e92564e3c0
2025-02-07 16:25:52 +09:00
Stanislav Láznička d47f656667 make update
Kubernetes-commit: 0ca233384622f8e5080f38db6b8a4c9e70db6dfa
2024-10-09 15:02:13 +02:00
vaibhav2107 2b1c54bf39 Added the mergeDefaultEvictionSettings Kubelet Config
Kubernetes-commit: a97c6a70451b9c3c9665235f5bd322895a895706
2024-09-24 01:54:07 +05:30
lauralorenz 3b14f64fe5 KEP-4603: Node specific kubelet config for maximum backoff down to 1 second (#128374)
* Add feature gate, API, and conflict validation tests for enablecrashloopbackoffmax

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Handle when current base is longer than node max

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Update pkg/features/kube_features.go

Co-authored-by: Tsubasa Nagasawa <toversus2357@gmail.com>

* Fix indentation

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Follow convention for success test

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Normalize casing, and change field to Duration

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Fix json name and some other casing errors

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Another one I missed before

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Don't clobber global max function

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Change to flat value in defaults.go

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Streamline validation and defaults

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Fix typecheck

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Lint

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Tighten up validation for subsecond values

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Rename field from MaxBackOffPeriod to MaxContainerRestartPeriod

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* A few missed references to renames

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Only compare flags in flags test

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Don't mess with SetDefault signature

Nobody messes with SetDefault signature

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Fix stale signature change, and update test data

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Inspect current feature gates at defaulting time

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Don't use the global feature gate for temp usage

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Expose default error, and some comments

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

* Hint fuzzer for less arbitrary values to FeatureGates

Signed-off-by: Laura Lorenz <lauralorenz@google.com>

---------

Signed-off-by: Laura Lorenz <lauralorenz@google.com>
Co-authored-by: Tsubasa Nagasawa <toversus2357@gmail.com>

Kubernetes-commit: 7fe41da5221b215d097e930c6b7aa52e88324f66
2024-11-08 17:44:43 -08:00
utam0k 59c28f5e21 kubelet: new kubelet config option for disabling group oom kill
Signed-off-by: utam0k <k0ma@utam0k.jp>

Kubernetes-commit: 4f909c14a0b32dba90d5c28f2937964aaf20677a
2024-10-14 14:46:28 +09:00
Harshal Patil 776d934bca Kubelet option to disable cgroup v1 support
Signed-off-by: Harshal Patil <harpatil@redhat.com>

Kubernetes-commit: fff2b7f5666d3bb9fadd2d3731b6072c83f0c2a8
2024-06-17 14:24:12 -04:00
Harsha Narayana 895dfa5e5a kubelet: enable configurable rotation duration and parallel rotate
Kubernetes-commit: ab8c784ee970d72b03fd1c2ed7c228914e17e954
2022-12-06 11:37:50 +05:30
Peter Hunt ea9e3fa84e kubelet: add and use ImageMaximumGCAge in KubeletConfiguration
Signed-off-by: Peter Hunt <pehunt@redhat.com>

Kubernetes-commit: d992ea4b309a30efed4feef21773e65d2d6477ea
2023-10-06 12:43:37 -04:00
Aravindh Puthiyaparambil 63e98f1aef api: Add EnableNodeLogQuery to KubeletConfiguration
Added EnableNodeLogQuery field to kubelet/apis/config/types.go and
staging/src/k8s.io/kubelet/config/v1beta1/types.go, then executed.
 `hack/update-codegen.sh`.

This new field will default to off and will need to be explicitly
enabled in addition to the NodeLogQuery gate to use the feature.

Kubernetes-commit: aadad094101e4b69f8b3fc245925ad630f90f337
2023-03-06 14:38:33 -08:00
ruiwen-zhao d187b24b59 Add MaxParallelImagePulls support
Signed-off-by: ruiwen-zhao <ruiwen@google.com>

Kubernetes-commit: 572e6e0ffb3d40cc9ac94dc6776c9381f0e0f358
2023-01-19 23:52:57 +00:00
PiotrProkop cc981e28e6 Improved multi-numa alignment in Topology Manager: add topology-manager-policy-options flag in Kubelet
This patch adds new Kubelet option topologyManagerPolicyOptions.
To introduce new TopologyManager options, first we need to introduce new
flag called `topology-manager-policy-options` to allow users to modify
behaviour of best-effort and restricted policies.

Signed-off-by: PiotrProkop <pprokop@nvidia.com>

Kubernetes-commit: daee219210afa5ae3a00fa4767f1f7ab9df8af62
2022-10-07 14:52:22 +02:00
jinxu c807a973da Promote Local storage capacity isolation feature to GA
This change is to promote local storage capacity isolation feature to GA

At the same time, to allow rootless system disable this feature due to
unable to get root fs, this change introduced a new kubelet config
"localStorageCapacityIsolation". By default it is set to true. For
rootless systems, they can set this configuration to false to disable
the feature. Once it is set, user cannot set ephemeral-storage
request/limit because capacity and allocatable will not be set.

Change-Id: I48a52e737c6a09e9131454db6ad31247b56c000a

Kubernetes-commit: 0064010cddfa009fe16ae23fcd0c57f4f15d227c
2022-07-28 08:03:20 -07:00
Sally O'Malley 3660344705 kubelet tracing: generated files
Signed-off-by: Sally O'Malley <somalley@redhat.com>

Kubernetes-commit: 5b4456ceeaa8db1a9e8e33c34d0e634ebd884188
2022-07-11 18:15:38 -04:00
Aditi Sharma f53431b6d9 Move feature flag credential provider to beta
Signed-off-by: Aditi Sharma <adi.sky17@gmail.com>

Kubernetes-commit: ed16ef22061a8246236e0049a34d7cf305462e34
2022-03-21 17:55:07 +05:30
Shiming Zhang 0dc0452847 Add field for KubeletConfiguration and Regenerate
Kubernetes-commit: d82f6069708ff25ecff48464bee82bc570b55641
2021-11-17 11:46:51 +08:00
caozhiyuan 394f21e52e migrate --register-with-taints to KubeletConfiguration
Kubernetes-commit: bad4faf1b9d69d3cb6e8de90dc5eee1d8cf0b6d3
2021-10-04 09:17:10 +08:00
Patrick Ohly 2902dcb6e5 component-base: configurable JSON output
This implements the replacement of klog output to different files per level
with optionally splitting JSON output into two streams: one for info messages
on stdout, one for error messages on stderr. The info messages can get buffered
to increase performance. Because stdout and stderr might be merged by the
consumer, the info stream gets flushed before writing an error, to ensure that
the order of messages is preserved.

This also ensures that the following code pattern doesn't leak info messages:
   klog.ErrorS(err, ...)
   os.Exit(1)

Commands explicitly have to flush before exiting via logs.FlushLogs. Most
already do. But buffered info messages can still get lost during an unexpected
program termination, therefore buffering is off by default.

The new options get added to the v1alpha1 LoggingConfiguration with new command
line flags. Because it is an alpha field, changing it inside the v1beta kubelet
config should be okay as long as the fields are clearly marked as alpha.

Kubernetes-commit: b22263d8351e873961aeff5d065faf3443de9acb
2021-09-10 18:02:23 +02:00
Haleygo 064333e8cd support null resolvConf in Kubelet Configuration
Kubernetes-commit: 46454ea9dcd2f48863518244ed687b0d880d7daf
2021-08-27 14:28:32 +08:00
Stephen Augustus 6036977e4a generated: Run hack/update-gofmt.sh
Signed-off-by: Stephen Augustus <foo@auggie.dev>

Kubernetes-commit: 481cf6fbe753b9eb2a47ced179211206b0a99540
2021-08-12 17:13:11 -04:00
Francesco Romani 6cc30db08d smtalign: add auto generated code
Files generate after running `make generated_files`.

Co-authored-by: Swati Sehgal <swsehgal@redhat.com>
Signed-off-by: Francesco Romani <fromani@redhat.com>

Kubernetes-commit: 6dccad45b4f8534ea1d0b0ecd8830b72e8e56dd4
2021-06-11 19:15:53 +02:00
Li Bo 8a01668e25 feature: support Memory QoS for cgroups v2
Kubernetes-commit: c3d9b10ca834b88516c6e059eb038eae19266ddf
2021-06-17 20:11:58 +08:00
Elana Hashman ed11bf5d95 Add generated files for swap API changes
Kubernetes-commit: d4041cb80f936799bff7d40e51d5028b8aa94bb5
2021-06-22 14:50:23 -07:00
Sascha Grunert 762f5ef191 Add SeccompDefault feature
This adds the gate `SeccompDefault` as new alpha feature. Seccomp path
and field fallbacks are now passed to the helper functions, whereas unit
tests covering those code paths have been added as well.

Beside enabling the feature gate, the feature has to be enabled by the
`SeccompDefault` kubelet configuration or its corresponding
`--seccomp-default` CLI flag.

Signed-off-by: Sascha Grunert <sgrunert@redhat.com>

Apply suggestions from code review

Co-authored-by: Paulo Gomes <pjbgf@linux.com>
Signed-off-by: Sascha Grunert <sgrunert@redhat.com>

Kubernetes-commit: 8b7003aff4c81f124851041eafb8899ea7e83ffd
2021-05-12 11:20:30 +02:00
Sri Saran Balaji Vellore Rajakumar de5214f74b Add support to disable /debug/pprof and /debug/flags/v endpoint
Co-authored-by: xiaofei.sun <sunxiaofei@kuaishou.com>
Co-authored-by: SaranBalaji90 <srisaranbalaji@gmail.com>

Kubernetes-commit: 51cdf4e97bbd03b353dcb852d6b9c39642f4f7a8
2021-01-23 09:16:39 -08:00
Artyom Lukianov 423143579b memory manager: update kubelet config API
Update kubelet config API to use slice of MemoryReservation
structs instead of slice of maps.

Signed-off-by: Artyom Lukianov <alukiano@redhat.com>

Kubernetes-commit: b7cfc40debe424837423052ba67f2be9ea633809
2020-11-18 00:15:35 +02:00
Artyom Lukianov e5cfd7f005 memory manager: add memory manager flag under kubelet options and kubelet config
The commit also includes generated files after `make generated_files`.

Signed-off-by: Byonggon Chun <bg.chun@samsung.com>

Kubernetes-commit: 93accb51e4c24bc36b730812a44381b7780ca918
2020-10-08 18:37:36 +03:00
David Porter 083baa13ba Implement shutdown manager in kubelet
Implements KEP 2000, Graceful Node Shutdown:
https://github.com/kubernetes/enhancements/tree/master/keps/sig-node/2000-graceful-node-shutdown

* Add new FeatureGate `GracefulNodeShutdown` to control
enabling/disabling the feature
* Add two new KubeletConfiguration options
  * `ShutdownGracePeriod` and `ShutdownGracePeriodCriticalPods`
* Add new package, `nodeshutdown` that implements the Node shutdown
manager
  * The node shutdown manager uses the systemd inhibit package, to
  create an system inhibitor, monitor for node shutdown events, and
  gracefully terminate pods upon a node shutdown.

Kubernetes-commit: 16f71c6d47843c359e78c0eea2f34814f4cf055b
2020-11-02 23:18:36 +00:00
Sri Saran Balaji Vellore Rajakumar 0062b169bd Add support for disabling /logs endpoint in kubelet
Kubernetes-commit: 05240c9218e84a3bfeb2ced62824b33b0b23efe5
2020-01-15 20:37:39 -08:00
amash bdcb3bc592 add LoggingConfiguration struct to component-base/config
Kubernetes-commit: 3ab25f18766d83ca56672880aae77fa4cece0e91
2020-06-26 01:03:27 +04:30
amash 063b0e8247 add loggingConfig struct to kubelet config
Kubernetes-commit: ac8d2e897876c3c823a91ce4ab9ae2a908aff8e3
2020-06-16 15:17:14 +04:30
Amim Knabben 1a56737875 Moving Kubelet --node-status-max-images flag to configuration
Kubernetes-commit: f6246aba6ea791eba239157efb51b2a2ba265f2e
2020-05-19 21:38:04 -04:00
Amim Knabben 17328d62fd Moving enable-server and provider-id
Kubernetes-commit: 8459c9b6f458f1e9e618e7be0d2ad63b5d434fd5
2020-04-25 19:01:17 -04:00
Seth Jennings 69c066f592 kubelet: add allowed sysctl to KubeletConfiguration
Kubernetes-commit: 0c7ce5a7d706613598ae3970504c4551094aee3e
2019-03-11 13:42:56 -05:00
Zhen Wang f6713d9bd0 Update kubelet node status report logic with node lease feature
When node lease feature is enabled, kubelet reports node status to api server
only if there is some change or it didn't report over last report interval.

Kubernetes-commit: 98fc4a107a8e6da008669b2792044a154f4a75a7
2018-10-01 11:32:56 -07:00
Lucas Käldström 6e39c8d9a8 autogenerated go code, godeps, bazel and gofmt
Kubernetes-commit: 8b6a7ee07569f2a14fb09c3a540c459467cc62ab
2018-09-02 14:38:59 +03:00