Files
podinfo/cue
Stefan Prodan cb8c1fcec1 Release v6.1.6
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2022-05-31 13:04:28 +03:00
..
2022-04-17 15:43:09 +03:00
2022-04-17 15:43:09 +03:00
2022-04-17 15:43:09 +03:00
2022-04-17 15:43:09 +03:00
2022-05-31 13:04:28 +03:00
2022-04-17 15:43:09 +03:00

Podinfo CUE module

This directory contains a CUE module and tooling for generating podinfo's Kubernetes resources.

The module contains a podinfo.#Application definition which takes podinfo.#Config as input.

Prerequisites

Install CUE with:

brew install cue

Generate the Kubernetes API definitions required by this module with:

cue get go k8s.io/api/...

Configuration

Configure the application in main.cue:

app: podinfo.#Application & {
	config: {
		meta: {
			name:      "podinfo"
			namespace: "default"
		}
		image: tag: "6.1.3"
		resources: requests: {
			cpu:    "100m"
			memory: "16Mi"
		}
		hpa: {
			enabled:     true
			maxReplicas: 3
		}
		ingress: {
			enabled:   true
			className: "nginx"
			host:      "podinfo.example.com"
			tls:       true
			annotations: "cert-manager.io/cluster-issuer": "letsencrypt"
		}
		serviceMonitor: enabled: true
	}
}

Generate the manifests

cue gen