innago-vault-k8s-role-operator

by stand-sure

Helm chartv2.0.5App 2.0.3Apache-2.0Verified publisher

Kubernetes operator for managing HashiCorp Vault roles and policies

About this chart

innago-vault-k8s-role-operator

A Helm chart for Kubernetes

Prerequisites

Vault Policy and Role

The operator requires a Vault policy and Kubernetes auth role to manage application secrets.

1. Create the Vault policy:

# Policy name: innago-vault-k8s-role-operator

path "auth/kubernetes/login" {
  capabilities = ["create", "update"]
}

path "auth/kubernetes/role/*" {
  capabilities = ["create", "update"]
}

path "sys/policies/acl/*" {
  capabilities = ["create", "update"]
}
vault policy write innago-vault-k8s-role-operator - <<EOF
path "auth/kubernetes/login" {
  capabilities = ["create", "update"]
}
path "auth/kubernetes/role/*" {
  capabilities = ["create", "update"]
}
path "sys/policies/acl/*" {
  capabilities = ["create", "update"]
}
EOF

2. Create the Kubernetes auth role:

vault write auth/kubernetes/role/innago-vault-k8s-role-operator \
  bound_service_account_names=innago-vault-k8s-role-operator \
  bound_service_account_namespaces=innago-vault-k8s-role-operator \
  policies=innago-vault-k8s-role-operator \
  ttl=1h

Requirements

RepositoryNameVersion
oci://ghcr.io/innago-property-management/helm-chartsinnago-webapp(webapp)2.5.0

Values

KeyTypeDefaultDescription
innago-webappobject{"containerSecurityContext":{"allowPrivilegeEscalation":false,"capabilities":{"drop":["ALL"]},"runAsGroup":10001,"runAsNonRoot":true,"runAsUser":10001,"seccompProfile":{"type":"RuntimeDefault"}},"fullnameOverride":"innago-vault-k8s-role-operator","health":{"livenessProbe":{"httpGet":{"path":"/healthz","port":"http"}},"readinessProbe":{"httpGet":{"path":"/healthz","port":"http"}},"startupProbe":{"failureThreshold":30,"httpGet":{"path":"/healthz","port":"http"},"initialDelaySeconds":10,"periodSeconds":5,"timeoutSeconds":3}},"httpContainerPort":8080,"image":{"repository":"ghcr.io/innago-property-management/innago-vault-k8s-role-operator","tag":"1.0.0"},"innagoVaultK8sRoleOperator":{"use":false},"podAnnotations":{"keptn.sh/app":"innago-vault-k8s-role-operator","keptn.sh/version":"1.0.0","keptn.sh/workload":"innago-vault-k8s-role-operator","vault.security.banzaicloud.io/vault-addr":"https://vault.security.svc:8200","vault.security.banzaicloud.io/vault-tls-secret":"vault-tls"},"podDisruptionBudget":{"disabled":false,"minAvailable":1,"unhealthyPodEvictionPolicy":"IfHealthyBudget"},"resources":{"limits":{"cpu":"500m","memory":"256Mi"},"requests":{"cpu":"100m","memory":"128Mi"}},"topologySpreadConstraints":{"disabled":false,"maxSkew":1,"topologyKey":"kubernetes.io/hostname","whenUnsatisfiable":"ScheduleAnyway"},"vault":{"address":"https://vault.security.svc:8200","tlsSecret":"vault-tls"}}Settings for the innago-webapp.
innago-webapp.containerSecurityContextobject{"allowPrivilegeEscalation":false,"capabilities":{"drop":["ALL"]},"runAsGroup":10001,"runAsNonRoot":true,"runAsUser":10001,"seccompProfile":{"type":"RuntimeDefault"}}security context see https://kubernetes.io/docs/tasks/configure-pod-container/security-context/
innago-webapp.fullnameOverridestring"innago-vault-k8s-role-operator"A name to override the generated name of the kubernetes objects.
innago-webapp.healthobject{"livenessProbe":{"httpGet":{"path":"/healthz","port":"http"}},"readinessProbe":{"httpGet":{"path":"/healthz","port":"http"}},"startupProbe":{"failureThreshold":30,"httpGet":{"path":"/healthz","port":"http"},"initialDelaySeconds":10,"periodSeconds":5,"timeoutSeconds":3}}Liveness and readiness probe settings. See https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
innago-webapp.health.livenessProbeobject{"httpGet":{"path":"/healthz","port":"http"}}Liveness probe settings.
innago-webapp.health.livenessProbe.httpGet.pathstring"/healthz"The path for the health probe.
innago-webapp.health.livenessProbe.httpGet.portstring"http"The port for the health probe.
innago-webapp.health.readinessProbeobject{"httpGet":{"path":"/healthz","port":"http"}}Readiness probe settings.
innago-webapp.health.readinessProbe.httpGet.pathstring"/healthz"The path for the health probe.
innago-webapp.health.readinessProbe.httpGet.portstring"http"The port for the health probe.
innago-webapp.health.startupProbeobject{"failureThreshold":30,"httpGet":{"path":"/healthz","port":"http"},"initialDelaySeconds":10,"periodSeconds":5,"timeoutSeconds":3}Startup probe settings (operators need time for leader election).
innago-webapp.health.startupProbe.failureThresholdint30Number of failures before pod is considered unhealthy.
innago-webapp.health.startupProbe.httpGet.pathstring"/healthz"The path for the health probe.
innago-webapp.health.startupProbe.httpGet.portstring"http"The port for the health probe.
innago-webapp.health.startupProbe.initialDelaySecondsint10Initial delay before first check (seconds).
innago-webapp.health.startupProbe.periodSecondsint5How often to perform the probe (seconds).
innago-webapp.health.startupProbe.timeoutSecondsint3Timeout for the probe (seconds).
innago-webapp.httpContainerPortint8080http container port
innago-webapp.imageobject{"repository":"ghcr.io/innago-property-management/innago-vault-k8s-role-operator","tag":"1.0.0"}Image settings.
innago-webapp.image.repositorystring"ghcr.io/innago-property-management/innago-vault-k8s-role-operator"The repository for the application image.
innago-webapp.image.tagstring"1.0.0"The tag for the application image.
innago-webapp.podAnnotationsobject{"keptn.sh/app":"innago-vault-k8s-role-operator","keptn.sh/version":"1.0.0","keptn.sh/workload":"innago-vault-k8s-role-operator","vault.security.banzaicloud.io/vault-addr":"https://vault.security.svc:8200","vault.security.banzaicloud.io/vault-tls-secret":"vault-tls"}Annotations to add to the primary pod
innago-webapp.podDisruptionBudgetobject{"disabled":false,"minAvailable":1,"unhealthyPodEvictionPolicy":"IfHealthyBudget"}Pod Disruption Budget settings. See https://kubernetes.io/docs/concepts/workloads/pods/disruptions/#pod-disruption-budgets
innago-webapp.podDisruptionBudget.disabledboolfalseIf true, a PodDisruptionBudget will not be created.
innago-webapp.podDisruptionBudget.minAvailableint1The minimum number of pods that must be available after an eviction. IMPORTANT: Set to 1 for production to ensure high availability during maintenance. NOTE: Only set minAvailable OR maxUnavailable, not both.
innago-webapp.podDisruptionBudget.unhealthyPodEvictionPolicystring"IfHealthyBudget"The policy for evicting unhealthy pods.
innago-webapp.resourcesobject{"limits":{"cpu":"500m","memory":"256Mi"},"requests":{"cpu":"100m","memory":"128Mi"}}Resource requests and limits for the operator. CRITICAL: Prevents OOM kills and ensures stable operation.
innago-webapp.topologySpreadConstraintsobject{"disabled":false,"maxSkew":1,"topologyKey":"kubernetes.io/hostname","whenUnsatisfiable":"ScheduleAnyway"}Topology spread constraints settings. See https://kubernetes.io/docs/concepts/scheduling-eviction/topology-spread-constraints/
innago-webapp.topologySpreadConstraints.disabledboolfalseIf true, topology spread constraints will not be applied.
innago-webapp.topologySpreadConstraints.maxSkewint1The maximum skew between topologies.
innago-webapp.topologySpreadConstraints.topologyKeystring"kubernetes.io/hostname"The key for topology domain.
innago-webapp.topologySpreadConstraints.whenUnsatisfiablestring"ScheduleAnyway"What to do when a pod doesn't satisfy the spread constraint.
innago-webapp.vaultobject{"address":"https://vault.security.svc:8200","tlsSecret":"vault-tls"}Vault configuration
innago-webapp.vault.addressstring"https://vault.security.svc:8200"Vault server address (protocol://host:port) IMPORTANT: Configure this for your environment. Default assumes Vault in 'security' namespace.
innago-webapp.vault.tlsSecretstring"vault-tls"Name of the secret containing the Vault TLS certificate Recommendation: Use https://github.com/emberstack/kubernetes-reflector to replicate the secret into all namespaces
serviceAccountobject{"annotations":{"app":"innago-vault-k8s-role-operator","app.kubernetes.io/name":"innago-vault-k8s-role-operator"},"create":true,"name":"innago-vault-k8s-role-operator"}Service account settings.
serviceAccount.annotationsobject{"app":"innago-vault-k8s-role-operator","app.kubernetes.io/name":"innago-vault-k8s-role-operator"}Annotations to add to the service account.
serviceAccount.createbooltrueIf true, a service account will be created.
serviceAccount.namestring"innago-vault-k8s-role-operator"The name of the service account to use.

Autogenerated from chart metadata using helm-docs v1.14.2

Deploy innago-vault-k8s-role-operator with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has innago-vault-k8s-role-operator on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartinnago-vault-k8s-role-operator is pinned at v2.0.5 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply