create-configmap

command
v0.0.1-beta07 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 13, 2022 License: Apache-2.0 Imports: 1 Imported by: 0

README

configmap

This function generates a ConfigMap resource from a set of given key/value mappings.

Values for each key can be provided verbatim in function configuration or read from a file.

The ConfigMap can also be marked as immutable if desired (see Kubernetes documentation on what immutable ConfigMap resources are).

Usage

apiVersion: kude.kfirs.com/v1alpha2
kind: Pipeline
resources:
  - deployment.yaml
steps:
  - image: ghcr.io/arikkfir/kude/functions/create-configmap
    config:
      name: my-config
      namespace: appX # optional
      immutable: true # optional (default in Kubernetes is false)
      contents:
        - key: foo
          value: bar
        - key: file-foo
          path: FOO.txt

Assuming the file FOO.txt contains file-bar, the pipeline above would add a ConfigMap resource that would look like this:

apiVersion: v1
data:
  file-foo: file-bar
  foo: bar
immutable: true
kind: ConfigMap
metadata:
  annotations:
    kude.kfirs.com/previous-name: my-config
  name: my-config-248ydjh28y42h3 # made-up hash here, mileage will vary
  namespace: appX

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL