Documentation
¶
Overview ¶
Package k8s provides Kubernetes-specific implementations of the infra providers.
Package k8s provides Kubernetes-specific implementations of the infra providers.
Package k8s provides Kubernetes-specific implementations of the infra providers.
Package k8s provides Kubernetes-specific implementations of the infra providers.
Package k8s provides Kubernetes-specific implementations of the infra providers.
Package k8s provides Kubernetes-specific implementations of the infra providers.
Index ¶
- func NewClient() (kubernetes.Interface, error)
- func NewClientAndConfig() (kubernetes.Interface, *rest.Config, error)
- func NewClientForKubeConfig(path, kubeContext string) (kubernetes.Interface, *rest.Config, error)
- func NewSecretsProvider(client kubernetes.Interface, infraP *InfraProvider) (infra.SecretsProvider, error)
- func ResolveKubeConfig(path, kubeContext string) (string, string, error)
- type CollectorDeployer
- func (d *CollectorDeployer) Available(ctx context.Context) (infra.CollectorAvailability, error)
- func (d *CollectorDeployer) ConfigContext(context.Context) (infra.CollectorConfigContext, error)
- func (d *CollectorDeployer) Start(ctx context.Context, config infra.CollectorDeploymentConfig) (infra.CollectorInstance, error)
- type InfraProvider
- func (p *InfraProvider) ApplyDeltaWorkerRegistryRemap(ctx context.Context, registryURL string) error
- func (p *InfraProvider) BuiltinDatabaseWorkloadAvailable() bool
- func (p *InfraProvider) ExecInService(service infra.ServiceName, command []string) (string, error)
- func (p *InfraProvider) ExecInServiceWithStdin(service infra.ServiceName, command []string, stdin io.Reader) (string, error)
- func (p *InfraProvider) ExposeService(service infra.ServiceName, protocol string) (string, func(), error)
- func (p *InfraProvider) GetAPILoginToken() (string, error)
- func (p *InfraProvider) GetConfigValue(name, key string) (string, error)
- func (p *InfraProvider) GetDBConnectionParams() (infra.DBConnectionParams, error)
- func (p *InfraProvider) GetEncryptionConfig(service infra.ServiceName) (*internalconfig.EncryptionConfig, error)
- func (p *InfraProvider) GetEnvironmentType() string
- func (p *InfraProvider) GetExternalNamespace() string
- func (p *InfraProvider) GetInternalNamespace() string
- func (p *InfraProvider) GetSecretValue(name, key string) (string, error)
- func (p *InfraProvider) GetServiceConfig(service infra.ServiceName) (string, error)
- func (p *InfraProvider) GetServiceEndpoint(service infra.ServiceName) (string, int, error)
- func (p *InfraProvider) GetServiceLogs(ctx context.Context, service infra.ServiceName, tailLines int) (string, error)
- func (p *InfraProvider) GetServiceNamespaceAndMetadata(service infra.ServiceName) (deploymentName, label, namespace string, err error)
- func (p *InfraProvider) InvalidateExposeCache(service infra.ServiceName)
- func (p *InfraProvider) QueryDBExternal(sql string) (string, error)
- func (p *InfraProvider) ResetEncryptionKeys() error
- func (p *InfraProvider) ServiceExists(ctx context.Context, service infra.ServiceName) (bool, error)
- func (p *InfraProvider) SetEncryptionConfig(service infra.ServiceName, enc *internalconfig.EncryptionConfig) error
- func (p *InfraProvider) SetEncryptionKey(service infra.ServiceName, keyFileName string, keyBytes []byte) error
- func (p *InfraProvider) SetServiceConfig(service infra.ServiceName, configKey, content string) error
- type RBACProvider
- func (p *RBACProvider) AddUserToOrg(ctx context.Context, orgName, userName string) error
- func (p *RBACProvider) CreateClusterRole(ctx context.Context, spec *infra.RoleSpec) error
- func (p *RBACProvider) CreateClusterRoleBinding(ctx context.Context, spec *infra.RoleBindingSpec) error
- func (p *RBACProvider) CreateOrganization(ctx context.Context, name string) error
- func (p *RBACProvider) CreateRole(ctx context.Context, spec *infra.RoleSpec) error
- func (p *RBACProvider) CreateRoleBinding(ctx context.Context, spec *infra.RoleBindingSpec) error
- func (p *RBACProvider) DeleteClusterRole(ctx context.Context, name string) error
- func (p *RBACProvider) DeleteClusterRoleBinding(ctx context.Context, name string) error
- func (p *RBACProvider) DeleteOrganization(ctx context.Context, name string) error
- func (p *RBACProvider) DeleteRole(ctx context.Context, namespace, name string) error
- func (p *RBACProvider) DeleteRoleBinding(ctx context.Context, namespace, name string) error
- func (p *RBACProvider) GetClient() kubernetes.Interface
- func (p *RBACProvider) UpdateClusterRole(ctx context.Context, spec *infra.RoleSpec) error
- func (p *RBACProvider) UpdateRole(ctx context.Context, spec *infra.RoleSpec) error
- type SecretsProvider
- func (p *SecretsProvider) CreateSecret(ctx context.Context, namespace, name string, stringData map[string]string) error
- func (p *SecretsProvider) GetSecretData(ctx context.Context, namespace, secretName, key string) ([]byte, error)
- func (p *SecretsProvider) GetSecretDataForService(ctx context.Context, service infra.ServiceName, secretName, key string) ([]byte, error)
- type ServiceLifecycleProvider
- func (p *ServiceLifecycleProvider) AreServicesHealthy() (bool, error)
- func (p *ServiceLifecycleProvider) IsRunning(service infra.ServiceName) (bool, error)
- func (p *ServiceLifecycleProvider) RemoveDeploymentEnv(service infra.ServiceName, envName string) error
- func (p *ServiceLifecycleProvider) Restart(service infra.ServiceName) error
- func (p *ServiceLifecycleProvider) SetDeploymentEnv(service infra.ServiceName, envName, envValue string) error
- func (p *ServiceLifecycleProvider) Start(service infra.ServiceName) error
- func (p *ServiceLifecycleProvider) Stop(service infra.ServiceName) error
- func (p *ServiceLifecycleProvider) WaitForReady(service infra.ServiceName, timeout time.Duration) error
- type TPMProvider
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewClient ¶
func NewClient() (kubernetes.Interface, error)
NewClient creates a Kubernetes client from the default kubeconfig resolution. Used by infra when building K8s providers and exposed so the harness can set h.Cluster.
func NewClientAndConfig ¶
func NewClientAndConfig() (kubernetes.Interface, *rest.Config, error)
NewClientAndConfig returns a Kubernetes client and rest config from the default kubeconfig. The config is needed for port-forward and exec. Use NewClient() when only the interface is needed.
It takes no configured path or context; callers that have one should resolve it with ResolveKubeConfig and use NewClientForKubeConfig, so the command lines they build can be given the same values.
func NewClientForKubeConfig ¶ added in v1.4.0
NewClientForKubeConfig builds a Kubernetes client and rest config for an explicit kubeconfig file and context. An empty context selects the file's current context. Pair it with ResolveKubeConfig so the caller can hand the same two values to anything that shells out to kubectl or helm.
func NewSecretsProvider ¶
func NewSecretsProvider(client kubernetes.Interface, infraP *InfraProvider) (infra.SecretsProvider, error)
NewSecretsProvider creates a new K8s SecretsProvider. infraP is used to resolve namespace for GetSecretDataForService; pass nil only if not using that method. If client is nil, it is created from the default kubeconfig.
func ResolveKubeConfig ¶ added in v1.4.0
ResolveKubeConfig decides which kubeconfig file and context a run uses.
It exists so that the Go client and the kubectl/helm command lines can be given the same answer. Resolving them separately is how a run ends up with a client talking to the current context of one file while kubectl talks to a different file, or to a different context of the same file - and the two then disagree about what is deployed.
path wins over the KUBECONFIG environment variable, because a caller that set it programmatically means it. An empty result for the context means "whatever the file's current context is": that is what the client does by default, and callers that build command lines leave --context off, so their own defaults still apply.
Types ¶
type CollectorDeployer ¶ added in v1.4.0
type CollectorDeployer struct {
// contains filtered or unexported fields
}
CollectorDeployer deploys the catalog collector into a Kubernetes cluster from the chart it ships with.
It implements infra.CollectorDeployer. Everything cluster-shaped is here: the namespace, the mounted Secret and ConfigMap, the CA bundle lookup, the Helm values, the image load, the release, readiness, and teardown. Callers get a configuration context and an instance handle, and nothing else.
func NewCollectorDeployer ¶ added in v1.4.0
func NewCollectorDeployer(client kubernetes.Interface, infraP *InfraProvider, secrets infra.SecretsProvider) (*CollectorDeployer, error)
NewCollectorDeployer creates the Kubernetes catalog collector deployer.
infraP supplies the cluster coordinates and the namespace the Flight Control deployment runs in; secrets reads that deployment's CA bundle, so the collector trusts the endpoint it is pointed at without a caller handling trust material.
func (*CollectorDeployer) Available ¶ added in v1.4.0
func (d *CollectorDeployer) Available(ctx context.Context) (infra.CollectorAvailability, error)
Available reports whether a collector can be deployed into this cluster.
Two things can make it unavailable, and both are settled answers rather than errors: a deployment type whose nodes cannot be fed a locally built image, and no collector image to deploy. Anything else - an unparseable setting, a container runtime that cannot be reached - is returned as an error, so a broken environment never degrades into a skip.
func (*CollectorDeployer) ConfigContext ¶ added in v1.4.0
func (d *CollectorDeployer) ConfigContext(context.Context) (infra.CollectorConfigContext, error)
ConfigContext returns the endpoint and in-container paths a caller needs to render a collector configuration for this deployment.
func (*CollectorDeployer) Start ¶ added in v1.4.0
func (d *CollectorDeployer) Start(ctx context.Context, config infra.CollectorDeploymentConfig) (infra.CollectorInstance, error)
Start deploys the collector and waits for the release to roll out.
The instance is returned alongside every failure that happened after the first object was created: a start that failed partway still owns a namespace, a Secret, or a release, and the instance is the only handle the caller has to remove them.
type InfraProvider ¶
type InfraProvider struct {
// contains filtered or unexported fields
}
InfraProvider implements infra.InfraProvider for Kubernetes environments.
func NewInfraProvider ¶
func NewInfraProvider(namespace string) (*InfraProvider, error)
NewInfraProvider creates a new K8s InfraProvider. If namespace is empty, it will be auto-detected via the k8s client.
func NewInfraProviderWithConfig ¶
func NewInfraProviderWithConfig(namespace string, config *infra.EnvironmentConfig, client kubernetes.Interface) (*InfraProvider, error)
NewInfraProviderWithConfig creates a new K8s InfraProvider with explicit configuration. client is optional; when nil a client is created from default kubeconfig for namespace detection. External namespace: config.Namespace (e.g. FLIGHTCTL_NS) or detect from pods with label flightctl.service=flightctl-api. Internal namespace: FLIGHTCTL_INTERNAL_NS or detect from pods with label flightctl.service=flightctl-worker. No fallbacks; returns error if detection fails when override not set.
func (*InfraProvider) ApplyDeltaWorkerRegistryRemap ¶ added in v1.4.0
func (p *InfraProvider) ApplyDeltaWorkerRegistryRemap(ctx context.Context, registryURL string) error
func (*InfraProvider) BuiltinDatabaseWorkloadAvailable ¶
func (p *InfraProvider) BuiltinDatabaseWorkloadAvailable() bool
BuiltinDatabaseWorkloadAvailable reports whether a flightctl-db pod exists in the internal namespace. External PostgreSQL (Helm db.type=external) does not deploy this workload; backup tests that exec pg_dump into the DB pod must be skipped.
func (*InfraProvider) ExecInService ¶
func (p *InfraProvider) ExecInService(service infra.ServiceName, command []string) (string, error)
ExecInService executes a command in the context of a service's pod.
func (*InfraProvider) ExecInServiceWithStdin ¶
func (p *InfraProvider) ExecInServiceWithStdin(service infra.ServiceName, command []string, stdin io.Reader) (string, error)
ExecInServiceWithStdin executes a command in the context of a service's pod with stdin attached.
func (*InfraProvider) ExposeService ¶
func (p *InfraProvider) ExposeService(service infra.ServiceName, protocol string) (string, func(), error)
ExposeService makes an internal K8s service accessible from the test host via port-forwarding. Repeated calls for the same (service, protocol) return the same URL so polling (e.g. WaitForQueueAccessible) does not spawn a new port-forward every time. Port-forwards to svc/<ServiceName> in the service's namespace (internal for Redis/flightctl-kv). Returns the localhost URL and a cleanup function (no-op when cached; callers must not close the shared forward).
func (*InfraProvider) GetAPILoginToken ¶
func (p *InfraProvider) GetAPILoginToken() (string, error)
GetAPILoginToken returns a token for flightctl login --token. KIND: kubectl create token flightctl-admin -n <external namespace> (where API pods run, e.g. flightctl-external). OCP: oc whoami -t.
func (*InfraProvider) GetConfigValue ¶
func (p *InfraProvider) GetConfigValue(name, key string) (string, error)
GetConfigValue retrieves a configuration value from a ConfigMap.
func (*InfraProvider) GetDBConnectionParams ¶ added in v1.4.0
func (p *InfraProvider) GetDBConnectionParams() (infra.DBConnectionParams, error)
GetDBConnectionParams reads DB connection parameters from the API ConfigMap and the flightctl-db-app-secret Secret in the internal namespace.
func (*InfraProvider) GetEncryptionConfig ¶ added in v1.3.0
func (p *InfraProvider) GetEncryptionConfig(service infra.ServiceName) (*internalconfig.EncryptionConfig, error)
GetEncryptionConfig reads the current encryption block from the service's ConfigMap config.yaml and returns a typed EncryptionConfig. If no encryption block is present, a synthesized default is returned (activeKeyID=default, path=EncryptionKeyDir/key).
func (*InfraProvider) GetEnvironmentType ¶
func (p *InfraProvider) GetEnvironmentType() string
GetEnvironmentType returns "kind" or "ocp".
func (*InfraProvider) GetExternalNamespace ¶
func (p *InfraProvider) GetExternalNamespace() string
GetExternalNamespace returns the namespace where external services (API, UI, etc.) run (release namespace).
func (*InfraProvider) GetInternalNamespace ¶
func (p *InfraProvider) GetInternalNamespace() string
GetInternalNamespace returns the namespace where internal services (worker, db, kv, etc.) run.
func (*InfraProvider) GetSecretValue ¶
func (p *InfraProvider) GetSecretValue(name, key string) (string, error)
GetSecretValue retrieves a secret value from a Secret (base64 decoded).
func (*InfraProvider) GetServiceConfig ¶
func (p *InfraProvider) GetServiceConfig(service infra.ServiceName) (string, error)
GetServiceConfig retrieves the full configuration content for a service.
func (*InfraProvider) GetServiceEndpoint ¶
func (p *InfraProvider) GetServiceEndpoint(service infra.ServiceName) (string, int, error)
GetServiceEndpoint returns the host and port for a named service. For K8s, this returns the service DNS name and port within the cluster.
func (*InfraProvider) GetServiceLogs ¶ added in v1.4.0
func (p *InfraProvider) GetServiceLogs(ctx context.Context, service infra.ServiceName, tailLines int) (string, error)
GetServiceLogs returns recent logs from all pods for a Flight Control service.
func (*InfraProvider) GetServiceNamespaceAndMetadata ¶
func (p *InfraProvider) GetServiceNamespaceAndMetadata(service infra.ServiceName) (deploymentName, label, namespace string, err error)
GetServiceNamespaceAndMetadata returns deployment name, pod label, and namespace for a service. Used by ServiceLifecycleProvider so all service/namespace resolution stays in InfraProvider.
func (*InfraProvider) InvalidateExposeCache ¶
func (p *InfraProvider) InvalidateExposeCache(service infra.ServiceName)
InvalidateExposeCache stops any cached port-forward for the service (kills the process) and removes it from the cache. Call after restarting a service so the next ExposeService creates a new port-forward.
func (*InfraProvider) QueryDBExternal ¶ added in v1.4.0
func (p *InfraProvider) QueryDBExternal(sql string) (string, error)
QueryDBExternal executes a SQL query against the external DB by spawning a short-lived batch/v1 Job in the internal namespace.
func (*InfraProvider) ResetEncryptionKeys ¶ added in v1.3.0
func (p *InfraProvider) ResetEncryptionKeys() error
ResetEncryptionKeys replaces the flightctl-encryption-key Secret with only the original "key" entry, removing any additional keys added during tests (e.g. after key rotation). After calling this, restart services so pods mount the updated Secret.
func (*InfraProvider) ServiceExists ¶ added in v1.3.0
func (p *InfraProvider) ServiceExists(ctx context.Context, service infra.ServiceName) (bool, error)
ServiceExists reports whether the backing Kubernetes Service for a logical service is present.
func (*InfraProvider) SetEncryptionConfig ¶ added in v1.3.0
func (p *InfraProvider) SetEncryptionConfig(service infra.ServiceName, enc *internalconfig.EncryptionConfig) error
SetEncryptionConfig writes the given encryption block into the service's ConfigMap config.yaml, preserving all other top-level keys.
func (*InfraProvider) SetEncryptionKey ¶ added in v1.3.0
func (p *InfraProvider) SetEncryptionKey(service infra.ServiceName, keyFileName string, keyBytes []byte) error
SetEncryptionKey patches the flightctl-encryption-key Secret to add/update a key entry, then triggers a rollout restart of the service's deployment so pods mount the updated Secret.
func (*InfraProvider) SetServiceConfig ¶
func (p *InfraProvider) SetServiceConfig(service infra.ServiceName, configKey, content string) error
SetServiceConfig updates a service's ConfigMap data key with the given content.
type RBACProvider ¶
type RBACProvider struct {
// contains filtered or unexported fields
}
RBACProvider implements infra.RBACProvider for Kubernetes environments.
func NewRBACProvider ¶
func NewRBACProvider(client kubernetes.Interface, releaseName string) (*RBACProvider, error)
NewRBACProvider creates a new K8s RBACProvider. releaseName is the external namespace (e.g. from InfraProvider.GetExternalNamespace()) used for CreateOrganization labels; may be empty. If client is nil, it will be created from the default kubeconfig.
func (*RBACProvider) AddUserToOrg ¶
func (p *RBACProvider) AddUserToOrg(ctx context.Context, orgName, userName string) error
AddUserToOrg grants the user access to the organization by binding them to the built-in view ClusterRole in that namespace.
func (*RBACProvider) CreateClusterRole ¶
CreateClusterRole creates a ClusterRole.
func (*RBACProvider) CreateClusterRoleBinding ¶
func (p *RBACProvider) CreateClusterRoleBinding(ctx context.Context, spec *infra.RoleBindingSpec) error
CreateClusterRoleBinding creates a ClusterRoleBinding.
func (*RBACProvider) CreateOrganization ¶
func (p *RBACProvider) CreateOrganization(ctx context.Context, name string) error
CreateOrganization creates a namespace with the release label so the API treats it as an organization.
func (*RBACProvider) CreateRole ¶
CreateRole creates a Role in the specified namespace.
func (*RBACProvider) CreateRoleBinding ¶
func (p *RBACProvider) CreateRoleBinding(ctx context.Context, spec *infra.RoleBindingSpec) error
CreateRoleBinding creates a RoleBinding in the specified namespace.
func (*RBACProvider) DeleteClusterRole ¶
func (p *RBACProvider) DeleteClusterRole(ctx context.Context, name string) error
DeleteClusterRole deletes a ClusterRole.
func (*RBACProvider) DeleteClusterRoleBinding ¶
func (p *RBACProvider) DeleteClusterRoleBinding(ctx context.Context, name string) error
DeleteClusterRoleBinding deletes a ClusterRoleBinding.
func (*RBACProvider) DeleteOrganization ¶
func (p *RBACProvider) DeleteOrganization(ctx context.Context, name string) error
DeleteOrganization deletes the namespace (organization).
func (*RBACProvider) DeleteRole ¶
func (p *RBACProvider) DeleteRole(ctx context.Context, namespace, name string) error
DeleteRole deletes a Role from the specified namespace.
func (*RBACProvider) DeleteRoleBinding ¶
func (p *RBACProvider) DeleteRoleBinding(ctx context.Context, namespace, name string) error
DeleteRoleBinding deletes a RoleBinding from the specified namespace.
func (*RBACProvider) GetClient ¶
func (p *RBACProvider) GetClient() kubernetes.Interface
GetClient returns the underlying Kubernetes client. This is useful for tests that need direct access.
func (*RBACProvider) UpdateClusterRole ¶
UpdateClusterRole updates a ClusterRole.
func (*RBACProvider) UpdateRole ¶
UpdateRole updates a Role in the specified namespace.
type SecretsProvider ¶
type SecretsProvider struct {
// contains filtered or unexported fields
}
SecretsProvider implements infra.SecretsProvider for Kubernetes environments.
func (*SecretsProvider) CreateSecret ¶
func (p *SecretsProvider) CreateSecret(ctx context.Context, namespace, name string, stringData map[string]string) error
CreateSecret creates a Secret with the given namespace, name, and string data. Idempotent: if the secret already exists, it is updated to match stringData.
func (*SecretsProvider) GetSecretData ¶
func (p *SecretsProvider) GetSecretData(ctx context.Context, namespace, secretName, key string) ([]byte, error)
GetSecretData returns the value of a key in a Kubernetes Secret. K8s API returns Secret.Data as decoded bytes.
func (*SecretsProvider) GetSecretDataForService ¶
func (p *SecretsProvider) GetSecretDataForService(ctx context.Context, service infra.ServiceName, secretName, key string) ([]byte, error)
GetSecretDataForService returns the value of a key in a secret for the given service. Namespace is resolved from the service (e.g. Redis/flightctl-kv uses internal namespace, same as Helm). For Redis use secretName "flightctl-kv-secret" and key "password" (Helm default).
type ServiceLifecycleProvider ¶
type ServiceLifecycleProvider struct {
// contains filtered or unexported fields
}
ServiceLifecycleProvider implements infra.ServiceLifecycleProvider for Kubernetes environments. All service and namespace resolution is delegated to InfraProvider.
func NewServiceLifecycleProviderWithConfig ¶
func NewServiceLifecycleProviderWithConfig(client kubernetes.Interface, infraP *InfraProvider) *ServiceLifecycleProvider
NewServiceLifecycleProviderWithConfig creates a new K8s ServiceLifecycleProvider. infraP is required; all service/namespace resolution comes from it.
func (*ServiceLifecycleProvider) AreServicesHealthy ¶
func (p *ServiceLifecycleProvider) AreServicesHealthy() (bool, error)
AreServicesHealthy checks if all flightctl services are healthy.
func (*ServiceLifecycleProvider) IsRunning ¶
func (p *ServiceLifecycleProvider) IsRunning(service infra.ServiceName) (bool, error)
IsRunning checks if a service is currently running.
func (*ServiceLifecycleProvider) RemoveDeploymentEnv ¶
func (p *ServiceLifecycleProvider) RemoveDeploymentEnv(service infra.ServiceName, envName string) error
RemoveDeploymentEnv removes an environment variable from a service's deployment and waits for rollout.
func (*ServiceLifecycleProvider) Restart ¶
func (p *ServiceLifecycleProvider) Restart(service infra.ServiceName) error
Restart restarts a service by deleting its pod and waiting for termination.
func (*ServiceLifecycleProvider) SetDeploymentEnv ¶
func (p *ServiceLifecycleProvider) SetDeploymentEnv(service infra.ServiceName, envName, envValue string) error
SetDeploymentEnv sets an environment variable on a service's deployment and waits for rollout.
func (*ServiceLifecycleProvider) Start ¶
func (p *ServiceLifecycleProvider) Start(service infra.ServiceName) error
Start starts a stopped service by scaling the deployment to 1 replica.
func (*ServiceLifecycleProvider) Stop ¶
func (p *ServiceLifecycleProvider) Stop(service infra.ServiceName) error
Stop stops a running service by scaling the deployment to 0 replicas.
func (*ServiceLifecycleProvider) WaitForReady ¶
func (p *ServiceLifecycleProvider) WaitForReady(service infra.ServiceName, timeout time.Duration) error
WaitForReady waits for a service to be ready: pod Running and Ready (K8s readiness).
type TPMProvider ¶
type TPMProvider struct {
// contains filtered or unexported fields
}
TPMProvider implements infra.TPMProvider for Kubernetes environments.
func NewTPMProvider ¶
func NewTPMProvider(client kubernetes.Interface, infraP *InfraProvider, lifecycle *ServiceLifecycleProvider) *TPMProvider
NewTPMProvider creates a new K8s TPMProvider.
func (*TPMProvider) CleanupCerts ¶
func (p *TPMProvider) CleanupCerts(ctx context.Context) error
CleanupCerts removes TPM CA certificates from the API server configuration.
func (*TPMProvider) InjectCerts ¶
InjectCerts configures TPM CA certificates for the API server. It skips the deployment restart if all certs, config, and volume/mount are already in place.