vault-token-injector

by joaquinito2051

Helm chartv4.0.0App v2.1.0

A Helm chart for Fairwinds vault-token-injector This will inject vault tokens and address variables into circle builds, terraform cloud workspaces, or spacelift stacks on a schedule

About this chart

Vault Token Injector Chart

A Helm chart for Fairwinds vault-token-injector

This will inject vault tokens and address variables into circle builds, terraform cloud workspaces, or spacelift stacks on a schedule

Upgrading

v2.0.0

Chart version 2.0.0 introduced a metrics endpoint by default.

Values

KeyTypeDefaultDescription
deployment.enabledbooltrueIf true, will be run as a deployment. Technically both cronjob and deployment can be enabled at the same time, but why?
deployment.replicaCountint1We currently only recommend a single instance
deployment.probes.liveness.enabledboolfalseIf true, a liveness probe will be set on the deployment pods. This probe fails if any errors are encountered.
deployment.metrics.enabledbooltrueIf true, a prometheus endpoint will be enabled on port 4329
deployment.metrics.service.enabledbooltrue
deployment.metrics.serviceMonitor.enabledboolfalse
deployment.metrics.serviceMonitor.intervalstring"60s"
deployment.metrics.serviceMonitor.scrapeTimeoutstring"30s"
deployment.metrics.serviceMonitor.labelsobject{}
cronjob.enabledboolfalseIf true, will be run as a cronjob. Technically both cronjob and deployment can be enabled at the same time, but why?
cronjob.schedulestring"7 * * * *"The schedule for the cronjob
cronjob.failedJobsHistoryLimitint1The number of failed jobs to keep around
cronjob.activeDeadlineSecondsint120The amount of time to allow the job to run
cronjob.backoffLimitint1the cronjob backoffLimit
cronjob.successfulJobsHistoryLimitint1The number of successful jobs to keep around
cronjob.restartPolicystring"OnFailure"restartPolicy
circleTokenstring"replaceme"A token for interacting with CircleCI
tfCloudTokenstring"replaceme"A token for interacting with TFCloud
existingSecretstring""An existing secret that contains the environment variables CIRCLEC_CI_TOKEN and TFCLOUD_TOKEN
vaultAddressstring"https://vault.example.com"The vault address to get tokens from
vaultTokenFilestring""A file containing a vault token. Optional.
configobject{"circleci":[{"env_variable":"VAULT_TOKEN","name":"FairwindsOps/example","vault_role":"some-vault-role"}],"vaultAddress":"https://vault.example.com"}The configuration of the vault-token-injector
logLevelint1The klog log level (1-10). WARNING: Log level 10 will print secrets to logs
image.repositorystring"us-docker.pkg.dev/fairwinds-ops/oss/vault-token-injector"The image repository to pull the vault-token-injector image from
image.pullPolicystring"Always"This is recommended to be set as Always
image.tagstring""Overrides the image tag whose default is the chart appVersion.
imagePullSecretslist[]A list of imagePullSecrets to use
nameOverridestring""Overrides the name in the main template
fullnameOverridestring""Overrides the fullname in the main template
serviceAccount.createbooltrueSpecifies whether a service account should be created
serviceAccount.annotationsobject{}Annotations to add to the service account
serviceAccount.namestring""The name of the service account to use. If not set and create is true, a name is generated using the fullname template
podAnnotationsobject{}Annotations to add to the pod
podSecurityContextobject{}a podSecurityContext to apply
securityContextobject{"capabilities":{"drop":["ALL"]},"readOnlyRootFilesystem":true,"runAsNonRoot":true,"runAsUser":10000}securityContext for the containers
resourcesobject{"limits":{"cpu":"20m","memory":"128Mi"},"requests":{"cpu":"20m","memory":"128Mi"}}resources block for the pod
nodeSelectorobject{}A nodeSelector block for the pod
tolerationslist[]tolerations block for the pod
affinityobject{}affinity block for the pod

Deploy vault-token-injector with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has vault-token-injector 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 chartvault-token-injector is pinned at v4.0.0 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