Options
All
  • Public
  • Public/Protected
  • All
Menu

External module "lib/kubernetes/secret"

Index

Functions

decryptSecret

  • decryptSecret(secret: V1Secret, key: string): Promise<V1Secret>
  • Return a copy of the provided secret with its data valued decrypted. The provided secret is not modified.

    Parameters

    • secret: V1Secret

      Kubernetes secret with encrypted data values

    • key: string

    Returns Promise<V1Secret>

    Kubernetes secret object with base64 encoded data values

encodeSecret

  • encodeSecret(name: string, data: object): V1Secret
  • Create encoded opaque secret object from key/value pairs.

    Parameters

    • name: string
    • data: object
      • [key: string]: string

    Returns V1Secret

    Kubernetes secret object

encryptSecret

  • encryptSecret(secret: V1Secret, key: string): Promise<V1Secret>
  • Return a copy of the provided secret with its data values encrypted. The provided secret should have its data values base64 encoded. The provided secret is not modified.

    Parameters

    • secret: V1Secret

      Kubernetes secret with base64 encoded data values

    • key: string

    Returns Promise<V1Secret>

    Kubernetes secret object with encrypted data values

handleDataStrings

  • handleDataStrings(secret: V1Secret): V1Secret
  • Return the provided secret with any data residing in the stringData section base64 encoded and moved into the data section. Keys in stringData will override existing keys in data.

    Parameters

    • secret: V1Secret

      Kubernetes secret with stringData elements

    Returns V1Secret

    Kubernetes secret with stringData elements encoded and moved to data

secretTemplate

upsertSecrets

  • Create application secrets if they do not exist. If a secret in req.secrets exists, the secret is patched. The provided secrets are merged through secretTemplate before creating/patching. If req.secrets is false or any empty array, no secrets are modified.

    Parameters

    Returns Promise<V1Secret[]>

    Array of secret specs created/patched, which array may be empty

Generated using TypeDoc