2 Commits

Author SHA1 Message Date
Andrey Smirnov
dd196d3006
refactor: prepare for move of pkg/resources to machinery
Start enforcing importvet rules, the very first cleanup is breaking
dependency of `pkg/resources` on `pkg/kernel` (only machinery imports
are allowed).

Follow-up PRs will address other problematic imports.

Signed-off-by: Andrey Smirnov <andrey.smirnov@talos-systems.com>
2021-10-29 12:09:40 +03:00
Artem Chernyshev
e08b4f8f9e feat: implement sysctl controllers
Fixed: https://github.com/talos-systems/talos/issues/3686

Replaced sequencer tasks for KSPP and Kubernetes required sysctl props
by the ones set by controllers.

KernelParam flow includes of 3 controllers and 2 resources:
- `KernelParamConfigController` - handles user sysctls coming from v1alpha1
config.
- `KernelParamDefaultsController` - handles our built-in KSPP and K8s
required sysctls.
- `KernelParamSpecController` - consumes `KernelParamSpec`s created by the
previous two controllers, applies them and updates the corresponding
`KernelParamStatus`.

Signed-off-by: Artem Chernyshev <artem.0xD2@gmail.com>
2021-08-10 13:21:49 -07:00