Expand description
Utilities for Kubernetes controllers built on kube
§Crate Features
What functionality is provided by kubert
is controlled by a number of
Cargo features. All feature flags are disabled by default, so in order to
use the crate, the user must enable one or more feature flags. The following
feature flags are available:
§Module Features
These features control which of kubert
’s modules are enabled.
- admin: Enabled the
admin
module. - client: Enables the
client
module. - errors: Enables the
errors
module. - index: Enables the
index
module. - initialized: Enables the
initialized
module. - lease: Enables the
lease
module. - log: Enables the
log
module. - requeue: Enables the
requeue
module. - runtime: Enables the
runtime
module. Enabling this feature flag also enables the admin, client, initialized, and log features. - server: Enables the
server
module, and server-related functionality in theruntime
module (if the runtime feature is also enabled). - shutdown: Enables the
shutdown
module.
§Optional Dependencies
These features enable optional dependencies on other crates.
- clap: Enables support for command-line argument parsing using
clap
. When this feature is enabled, implementations of theclap::Parser
trait are enabled for the [AdminArgs
],ClientArgs
, andServerArgs
types, allowing them to be parsed from command-line arguments.
§TLS Features
These feature flags determine which TLS implementation is used by kubert
’s
client
and server
modules. If neither feature is enabled, kubert
’s
client
module will use whatever TLS implementation is provided by the
kube-client
crate’s feature flags, and kubert
’s server
module will
panic when starting the server.
- rustls-tls: Use
rustls
as the TLS implementation. - openssl-tls: Use OpenSSL (via the
openssl
crate) as the TLS implementation. This feature takes priority over the rustls-tls feature flag. If both are enabled, OpenSSL will be used instead of Rustls.
If the client
feature flag is enabled, these features will also enable the
corresponding feature flags on the kube-client
crate, to configure which
TLS implementation is used by the underlying Kubernetes API client.
Re-exports§
pub use self::client::ClientArgs;
pub use self::initialized::Initialized;
pub use self::lease::LeaseManager;
pub use self::log::LogFilter;
pub use self::log::LogFormat;
pub use self::runtime::Runtime;
pub use self::runtime::RuntimeMetrics;
pub use self::server::ServerArgs;
Modules§
- admin
admin
Admin server utilities. - client
client
Utilities for configuring akube_client::Client
from the command line - errors
errors
Utilities for handling errors - index
index
Utilities for maintaining a shared index derived from Kubernetes resources. - initialized
initialized
A utility for waiting for components to be initialized. - lease
lease
A distributed, advisory lock implementation for Kubernetes - log
log
Configures the global default tracing subscriber - requeue
requeue
A bounded, delayed, multi-producer, single-consumer queue for deferring work in response to scheduler updates. - runtime
runtime
A controller runtime - server
server
Helpers for configuring and running an HTTPS server, especially for admission controllers and API extensions - shutdown
shutdown
Drives graceful shutdown when the process receives a signal.
Structs§
- Error returned by
try_init
if a global default subscriber could not be initialized.