Skip to content

Connection resources · Kind catalogue · Examples

OpenBaoServer

API version: core.openbaoconfig.io/v1alpha1
Scope: Cluster
Resource: openbaoservers.core.openbaoconfig.io
Categories: openbao

OpenBaoServer is a cluster-scoped OpenBao server that the platform team makes available to connections. It is the only place that sets the address, CA bundle, request rate and timeout the operator uses, and it decides which namespaces and token audiences tenants' OpenBaoConnections may use. It writes nothing to OpenBao; the operator probes sys/health and sys/seal-status and reports the version and seal state.

Example:

spec:
  address: https://openbao.openbao.svc:8200
  caBundle:
    configMapRef:
      namespace: openbao
      name: openbao-ca
  allowedNamespaces:
    matchLabels:
      openbao.io/tenant: "true"
  allowedAudiences: ["openbao"]

Example

examples/core/openbaoserver.yaml
# The platform team declares the OpenBao server once. Tenants in namespaces labelled
# openbaoconfig.io/tenant=true may connect to it with OpenBaoConnections that request the openbao token audience;
# the Kubernetes API server's own audiences are always refused.
apiVersion: core.openbaoconfig.io/v1alpha1
kind: OpenBaoServer
metadata:
  name: openbao
spec:
  address: https://openbao.openbao.svc:8200
  caBundle:
    configMapRef:
      namespace: openbao
      name: openbao-ca
  allowedNamespaces:
    matchLabels:
      openbaoconfig.io/tenant: "true"
  allowedAudiences:
    - openbao
  rateLimit:
    qps: 50
    burst: 100
  requestTimeout: 30s

On GitHub: openbaoserver.yaml, generated sample with every field.

Fields

Defaults below are CRD schema defaults. A blank cell does not imply zero, false or an empty value; see the field description for omission behaviour. Required fields inside an optional object apply only when that object is set.

FieldTypeRequiredDefaultDescriptionValidation
specobjectyesDesired state of the server: address, trust, tenant allow-lists and request limits.
ConstraintsCEL: self.address.startsWith('https://') || (has(self.allowInsecureHTTP) && self.allowInsecureHTTP) (address must use https unless allowInsecureHTTP is true)
spec.addressstringyesURL of the OpenBao API, without the /v1 suffix and without credentials (user:password@). Must be https unless allowInsecureHTTP is true. Only an OpenBaoServer sets the address the operator calls; connections reference the server. Example: https://openbao.openbao.svc:8200
Constraintspattern: ^https?://[^\s/?#@]+(/[^\s?#]*)?$
length: <=2048
CEL: !self.matches('/v1/?$') (address must not end with /v1)
spec.allowInsecureHTTPbooleannoAllow an http:// address. Tokens, login JWTs and every secret input then cross the network in clear text: use it only for a local development server. Default: false.
spec.allowedAudiences[]stringnoToken audiences an OpenBaoConnection may request for its ServiceAccount; every audience a connection asks for must be listed. The audiences of the Kubernetes API server are always refused, even when listed, because such a token is a Kubernetes credential. At most 16 entries. Example: ["openbao"]
Constraintsitems: <=16
list type: set
each item: length: >=1, <=256
spec.allowedNamespacesobjectnoLabel selector over Kubernetes namespaces whose OpenBaoConnections may use this server. Unset allows no namespace; an empty selector ({}) allows every namespace. ClusterOpenBaoConnections are not restricted by it. Example: {matchLabels: {openbao.io/tenant: "true"}}
Constraintsmap type: atomic
spec.allowedNamespaces.matchExpressions[]objectnomatchExpressions is a list of label selector requirements. The requirements are ANDed.
Constraintslist type: atomic
spec.allowedNamespaces.matchExpressions[]objectnoA label selector requirement is a selector that contains values, a key, and an operator that relates the key and values.
spec.allowedNamespaces.matchExpressions[].keystringyeskey is the label key that the selector applies to.
spec.allowedNamespaces.matchExpressions[].operatorstringyesoperator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.
spec.allowedNamespaces.matchExpressions[].values[]stringnovalues is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.
Constraintslist type: atomic
spec.allowedNamespaces.matchLabelsmap[string]stringnomatchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is "key", the operator is "In", and the values array contains only "value". The requirements are ANDed.
spec.caBundleobjectnoPEM CA bundle that verifies the server's TLS certificate, from exactly one of a Secret or a ConfigMap. Unset uses the operator's system roots.
ConstraintsCEL: [has(self.secretRef),has(self.configMapRef)].filter(x,x==true).size() == 1 (exactly one of the fields in [secretRef configMapRef] must be set)
spec.caBundle.configMapRefobjectnoConfigMap that holds the PEM CA bundle, for example one filled by trust-manager. Mutually exclusive with secretRef.
spec.caBundle.configMapRef.keystringno"ca.crt"Key that holds the PEM bundle. Default: ca.crt. Example: ca.crt
spec.caBundle.configMapRef.namestringyesName of the Secret or ConfigMap. Example: openbao-ca
Constraintslength: >=1
spec.caBundle.configMapRef.namespacestringyesKubernetes namespace of the Secret or ConfigMap. Example: openbao
Constraintslength: >=1
spec.caBundle.secretRefobjectnoSecret that holds the PEM CA bundle. Mutually exclusive with configMapRef.
spec.caBundle.secretRef.keystringno"ca.crt"Key that holds the PEM bundle. Default: ca.crt. Example: ca.crt
spec.caBundle.secretRef.namestringyesName of the Secret or ConfigMap. Example: openbao-ca
Constraintslength: >=1
spec.caBundle.secretRef.namespacestringyesKubernetes namespace of the Secret or ConfigMap. Example: openbao
Constraintslength: >=1
spec.rateLimitobjectnoClient-side token bucket for the requests the operator sends to this server, shared by every connection to it. Unset means no limit.
spec.rateLimit.burstinteger (int32)noNumber of requests that may be sent at once above the sustained rate, 1 to 100000. Default: the value of qps. Example: 100
Constraintsvalue: >=1, <=100000
spec.rateLimit.qpsinteger (int32)yesSustained number of requests per second, 1 to 100000. Example: 50
Constraintsvalue: >=1, <=100000
spec.requestTimeoutstringnoMaximum time one request to OpenBao may take, as a duration. Default: 60s. Example: 30s
statusobjectnoObserved state of the server, reported by the operator's periodic probe.
status.conditions[]objectnoCurrent state as conditions: Ready is True when the server is reachable, initialized and unsealed; otherwise the reason is Unreachable, Sealed, InvalidSpec or ReferenceNotReady (CA bundle missing).
Constraintslist type: map (keys: type)
status.conditions[]objectnoCondition contains details for one aspect of the current state of this API Resource.
status.conditions[].lastTransitionTimestring (date-time)yeslastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.
status.conditions[].messagestringyesmessage is a human readable message indicating details about the transition. This may be an empty string.
Constraintslength: <=32768
status.conditions[].observedGenerationinteger (int64)noobservedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.
Constraintsvalue: >=0
status.conditions[].reasonstringyesreason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.
Constraintspattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
length: >=1, <=1024
status.conditions[].statusstringyesstatus of the condition, one of True, False, Unknown.
Constraintsone of: True, False, Unknown
status.conditions[].typestringyestype of condition in CamelCase or in foo.example.com/CamelCase.
Constraintspattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
length: <=316
status.lastProbeTimestring (date-time)noWhen a probe last changed this status; probes (about every minute) that find nothing new do not update it.
status.observedGenerationinteger (int64)noThe metadata.generation of this server that the operator last probed against.
status.sealedbooleannoTrue when the server is sealed or not initialized; no connection to it is Ready then.
status.standbybooleannoTrue when the probed node is a standby rather than the active node.
status.versionstringnoOpenBao version reported by the server. Example: 2.7.2