Skip to content

Generate Kubernetes secrets from Google Secret Manager secrets

Notifications You must be signed in to change notification settings

reinoudk/krm-google-secret-manager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

krm-google-secret-manager

This is a KRM Function that generates Kubernetes Secrets from Google Secret Manager secret versions.

Usage

Due to mounting issues with containerized functions, the generator should be run as an exec function (for now). The Google credentials for fetching the secret version are found using Application Default Credentials.

apiVersion: kustomize.reinoud.dev/v1
kind: GoogleSecretManagerSecretGenerator
metadata:
  name: not-important
  annotations:
    config.kubernetes.io/function: |
      exec:
        path: ../../build/krm-google-secret-manager
spec:
  name: example
  project:
  secrets:
    - key: example-key
      source: projects/<your-project>/secrets/<your-secret>/versions/latest

See more details in examples/exec

Building the function

Simply call make to build the function and store the binary in build/.

About

Generate Kubernetes secrets from Google Secret Manager secrets

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published