Expand description
Bootstrap logic for bindy bootstrap.
Applies all prerequisites to a Kubernetes cluster in order:
- Namespace (
bindy-systemby default, or--namespace) - CRDs — generated from Rust types, always in sync with the operator
- ServiceAccount (
bindy) - ClusterRole (
bindy-role) — operator permissions - ClusterRole (
bindy-admin-role) — admin/destructive permissions - ClusterRoleBinding (
bindy-rolebinding) — binds SA to operator role
Constants§
- BINDY_
ADMIN_ ROLE_ YAML - BINDY_
ROLE_ YAML - Embedded RBAC YAML files — compiled into the binary so bootstrap is self-contained.
- CLUSTER_
ROLE_ BINDING_ NAME - ClusterRoleBinding name.
- DEFAULT_
IMAGE_ TAG - Default image tag for the operator Deployment.
- DEFAULT_
NAMESPACE - Default namespace for the bindy operator deployment.
- OPERATOR_
DEPLOYMENT_ NAME - Operator Deployment name.
- OPERATOR_
IMAGE_ BASE - Container image registry and repository (without tag).
- OPERATOR_
ROLE_ NAME - Operator ClusterRole name.
- SERVICE_
ACCOUNT_ NAME - ServiceAccount name created for the operator.
Functions§
- build_
all_ crds - Build all 12 CRDs in the same order as
crdgen. - build_
cluster_ role_ binding - Build the ClusterRoleBinding that binds the bindy ServiceAccount to
bindy-role. - build_
crd - Build a single CRD from a Rust type, ensuring
storage: trueandserved: true. - build_
deployment - Build the operator Deployment manifest.
- build_
namespace - Build the operator namespace object.
- build_
service_ account - Build the bindy ServiceAccount in the given namespace.
- parse_
cluster_ role - Parse a ClusterRole from embedded YAML.
- run_
bootstrap - Run the bootstrap process.