version

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2022 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func JWTSecrets

func JWTSecrets() cue.Value

JWTSecrets returns a cue.Value for injecting generated secret values to be used by JWT Security. This may not be needed later on if we can use custom template functions in cueutils.FromStrings (i.e. from Sprig). NOTE: Generation happens each time as this option is applied, which will cause a service restart to update envs.

func Load

func Load(loader cuemodule.Loader) (map[string]Version, error)

Load receives a cuemodule.Loader function and loads the Version map as an overlay on base install configuration.

func UserTokens

func UserTokens(users string) cue.Value

UserTokens returns a cue.Value for injecting user tokens to be added to JWT Security. Also injects an API key and private key used by the service.

Types

type ManifestGroup

type ManifestGroup struct {
	Deployment  *appsv1.Deployment  `json:"deployment"`
	StatefulSet *appsv1.StatefulSet `json:"statefulset"`
	Service     *corev1.Service     `json:"service"`
	ConfigMaps  []*corev1.ConfigMap `json:"configMaps"`
	Secrets     []*corev1.Secret    `json:"secrets"`
	Ingress     *netv1.Ingress      `json:"ingress"`
}

The manifests applied for a Grey Matter component or dependency.

type Sidecar

type Sidecar struct {
	Container    corev1.Container `json:"container"`
	Volumes      []corev1.Volume  `json:"volumes"`
	StaticConfig json.RawMessage  `json:"staticConfig"`
}

The manifests applied for Grey Matter sidecar injection.

type Version

type Version struct {
	// contains filtered or unexported fields
}

Version contains a cue.Value that holds all installation templates for a version of Grey Matter, plus options applied from a Mesh custom resource.

func (Version) Copy

func (v Version) Copy() Version

Copy deep copies a Version's cue.Value into a new Version.

func (Version) Manifests

func (v Version) Manifests() []ManifestGroup

Extracts manifests from a Version's cue.Value.

func (Version) SidecarTemplate

func (v Version) SidecarTemplate() func(string) Sidecar

Returns a function that extracts sidecar manifests from a Version's cue.Value.

func (*Version) Unify

func (v *Version) Unify(ws ...cue.Value)

Unify gets the lower bound cue.Value of Version.cue and all argument values.

Jump to

Keyboard shortcuts

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