Skip to content

This document outlines how to customize the build output through Helm overrides and package.json configurations.

By default, the store values are displayed in logs, to redact them you can set the PEPR_STORE_REDACT_VALUES environment variable to true in the package.json file or directly on the Watcher or Admission Deployment. The default value is undefined.

{
"env": {
"PEPR_STORE_REDACT_VALUES": "true"
}
}

You can display warnings in the logs by setting the PEPR_NODE_WARNINGS environment variable to true in the package.json file or directly on the Watcher or Admission Deployment. The default value is undefined.

{
"env": {
"PEPR_NODE_WARNINGS": "true"
}
}

The log format can be customized by setting the PINO_TIME_STAMP environment variable in the package.json file or directly on the Watcher or Admission Deployment. The default value is a partial JSON timestamp string representation of the time. If set to iso, the timestamp is displayed in an ISO format.

Caution: attempting to format time in-process will significantly impact logging performance.

{
"env": {
"PINO_TIME_STAMP": "iso"
}
}

With ISO:

{"level":30,"time":"2024-05-14T14:26:03.788Z","pid":16,"hostname":"pepr-static-test-7f4d54b6cc-9lxm6","method":"GET","url":"/healthz","status":200,"duration":"1 ms"}

Default (without):

{"level":30,"time":"1715696764106","pid":16,"hostname":"pepr-static-test-watcher-559d94447f-xkq2h","method":"GET","url":"/healthz","status":200,"duration":"1 ms"}

The Watch configuration is a part of the Pepr module that allows you to watch for specific resources in the Kubernetes cluster. The Watch configuration can be customized by specific environment variables of the Watcher Deployment and can be set in the field in the package.json or in the helm values.yaml file.

FieldDescriptionExample Values
PEPR_RESYNC_FAILURE_MAXThe maximum number of times to fail on a resync interval before re-establishing the watch URL and doing a relist.default: "5"
PEPR_RETRY_DELAY_SECONDSThe delay between retries in seconds.default: "10"
PEPR_LAST_SEEN_LIMIT_SECONDSMax seconds to go without receiving a watch event before re-establishing the watchdefault: "300" (5 mins)
PEPR_RELIST_INTERVAL_SECONDSAmount of seconds to wait before a relist of the watched resourcesdefault: "600" (10 mins)

The admission webhook server’s HTTP timeouts can be tuned via environment variables on the Admission Deployment.

FieldDescriptionExample Values
PEPR_KEEP_ALIVE_TIMEOUT_MSIdle timeout on persistent connections (server.keepAliveTimeout)default: "90000" (90s)
PEPR_HEADERS_TIMEOUT_MSMax time to receive full HTTP headers (server.headersTimeout)default: "32000" (32s)

The Reconcile Action allows you to maintain ordering of resource updates processed by a Pepr controller. The Reconcile configuration can be customized via environment variable on the Watcher Deployment, which can be set in the package.json or in the helm values.yaml file.

FieldDescriptionExample Values
PEPR_RECONCILE_STRATEGYHow Pepr should order resource updates being Reconcile()‘d.default: "kindNsName"

| Available Options | | - | - | | kind | separate queues of events for Reconcile()‘d resources of a kind | | kindNs | separate queues of events for Reconcile()‘d resources of a kind, within a namespace | | kindNsName | separate queues of events for Reconcile()‘d resources of a kind, within a namespace, per name | | global | a single queue of events for all Reconcile()‘d resources |

Below are the available Helm override configurations after you have built your Pepr module that you can put in the values.yaml. Generated internal values such as uuid, hash, and secrets are intentionally omitted.

PathTypeDefaultDescription
additionalIgnoredNamespaceslist[]Extra namespaces to ignore in addition to configured ignored namespaces.
admission.affinityobject{}Admission pod affinity settings.
admission.annotations.pepr.dev/descriptionstring<from package.json>Admission Deployment description annotation.
admission.antiAffinitybooleanfalseWhether admission pods should be scheduled on separate nodes.
admission.containerSecurityContext.allowPrivilegeEscalationbooleanfalseAdmission container privilege escalation setting.
admission.containerSecurityContext.capabilities.droplist["ALL"]Linux capabilities dropped from the admission container.
admission.containerSecurityContext.runAsGroupinteger65532Group ID for the admission container process.
admission.containerSecurityContext.runAsNonRootbooleantrueWhether the admission container must run as non-root.
admission.containerSecurityContext.runAsUserinteger65532User ID for the admission container process.
admission.enabledbooleantrueWhether to render the admission controller resources.
admission.envlist<from package.json>Environment variables for the admission container.
admission.envFromlist[]Additional envFrom sources for the admission container.
admission.extraVolumeMountslist[]Additional volume mounts for the admission container.
admission.extraVolumeslist[]Additional volumes for the admission pod.
admission.failurePolicystring<from package.json>Admission webhook failure policy.
admission.imagestring<from build>Admission controller image.
admission.labels.appstring<generated>Generated app label for the admission Deployment.
admission.labels.pepr.dev/controllerstring<generated>Generated controller label for the admission Deployment.
admission.labels.pepr.dev/uuidstring<generated>Generated module UUID label for the admission Deployment.
admission.livenessProbe.failureThresholdinteger3Admission liveness probe failure threshold.
admission.livenessProbe.httpGet.pathstring"/healthz"Admission liveness probe HTTP path.
admission.livenessProbe.httpGet.portinteger3000Admission liveness probe HTTP port.
admission.livenessProbe.httpGet.schemestring"HTTPS"Admission liveness probe HTTP scheme.
admission.livenessProbe.initialDelaySecondsinteger10Admission liveness probe initial delay.
admission.livenessProbe.periodSecondsinteger10Admission liveness probe interval.
admission.livenessProbe.successThresholdinteger1Admission liveness probe success threshold.
admission.livenessProbe.timeoutSecondsinteger1Admission liveness probe timeout.
admission.nodeSelectorobject{}Admission pod node selector.
admission.podAnnotationsobject{}Additional annotations for the admission pod.
admission.podLabelsobject{}Additional labels for the admission pod.
admission.readinessProbe.failureThresholdinteger3Admission readiness probe failure threshold.
admission.readinessProbe.httpGet.pathstring"/healthz"Admission readiness probe HTTP path.
admission.readinessProbe.httpGet.portinteger3000Admission readiness probe HTTP port.
admission.readinessProbe.httpGet.schemestring"HTTPS"Admission readiness probe HTTP scheme.
admission.readinessProbe.initialDelaySecondsinteger10Admission readiness probe initial delay.
admission.readinessProbe.periodSecondsinteger10Admission readiness probe interval.
admission.readinessProbe.successThresholdinteger1Admission readiness probe success threshold.
admission.readinessProbe.timeoutSecondsinteger1Admission readiness probe timeout.
admission.resources.limits.cpustring"500m"Admission container CPU limit.
admission.resources.limits.memorystring"512Mi"Admission container memory limit.
admission.resources.requests.cpustring"200m"Admission container CPU request.
admission.resources.requests.memorystring"256Mi"Admission container memory request.
admission.securityContext.fsGroupinteger<image-dependent>Admission pod filesystem group.
admission.securityContext.runAsGroupinteger<image-dependent>Admission pod group ID.
admission.securityContext.runAsNonRootbooleantrueWhether the admission pod must run as non-root.
admission.securityContext.runAsUserinteger<image-dependent>Admission pod user ID.
admission.serviceMonitor.annotationsobject{}Admission ServiceMonitor annotations.
admission.serviceMonitor.enabledbooleanfalseWhether to render the admission ServiceMonitor.
admission.serviceMonitor.labelsobject{}Admission ServiceMonitor labels.
admission.startupProbe.failureThresholdinteger3Admission startup probe failure threshold.
admission.startupProbe.httpGet.pathstring"/healthz"Admission startup probe HTTP path.
admission.startupProbe.httpGet.portinteger3000Admission startup probe HTTP port.
admission.startupProbe.httpGet.schemestring"HTTPS"Admission startup probe HTTP scheme.
admission.startupProbe.initialDelaySecondsinteger10Admission startup probe initial delay.
admission.startupProbe.periodSecondsinteger10Admission startup probe interval.
admission.startupProbe.successThresholdinteger1Admission startup probe success threshold.
admission.startupProbe.timeoutSecondsinteger1Admission startup probe timeout.
admission.terminationGracePeriodSecondsinteger5Admission pod termination grace period.
admission.tolerationslist[]Admission pod tolerations.
admission.webhookAnnotationsobject{}Admission webhook resource annotations.
admission.webhookLabelsobject{}Admission webhook resource labels.
admission.webhookTimeoutinteger<from package.json>Admission webhook timeout in seconds.
imagePullSecretslist[]Image pull secrets used by generated controller pods.
namespace.annotationsobject{}Namespace annotations.
namespace.labels.pepr.devstring""Default namespace label value.
rbaclist[]RBAC rules rendered into the chart.
watcher.affinityobject{}Watcher pod affinity settings.
watcher.annotations.pepr.dev/descriptionstring<from package.json>Watcher Deployment description annotation.
watcher.containerSecurityContext.allowPrivilegeEscalationbooleanfalseWatcher container privilege escalation setting.
watcher.containerSecurityContext.capabilities.droplist["ALL"]Linux capabilities dropped from the watcher container.
watcher.containerSecurityContext.runAsGroupinteger65532Group ID for the watcher container process.
watcher.containerSecurityContext.runAsNonRootbooleantrueWhether the watcher container must run as non-root.
watcher.containerSecurityContext.runAsUserinteger65532User ID for the watcher container process.
watcher.enabledbooleantrueWhether to render the watcher controller resources.
watcher.envlist<from package.json>Environment variables for the watcher container.
watcher.envFromlist[]Additional envFrom sources for the watcher container.
watcher.extraVolumeMountslist[]Additional volume mounts for the watcher container.
watcher.extraVolumeslist[]Additional volumes for the watcher pod.
watcher.imagestring<from build>Watcher controller image.
watcher.labels.appstring<generated>Generated app label for the watcher Deployment.
watcher.labels.pepr.dev/controllerstring<generated>Generated controller label for the watcher Deployment.
watcher.labels.pepr.dev/uuidstring<generated>Generated module UUID label for the watcher Deployment.
watcher.livenessProbe.failureThresholdinteger3Watcher liveness probe failure threshold.
watcher.livenessProbe.httpGet.pathstring"/healthz"Watcher liveness probe HTTP path.
watcher.livenessProbe.httpGet.portinteger3000Watcher liveness probe HTTP port.
watcher.livenessProbe.httpGet.schemestring"HTTPS"Watcher liveness probe HTTP scheme.
watcher.livenessProbe.initialDelaySecondsinteger10Watcher liveness probe initial delay.
watcher.livenessProbe.periodSecondsinteger10Watcher liveness probe interval.
watcher.livenessProbe.successThresholdinteger1Watcher liveness probe success threshold.
watcher.livenessProbe.timeoutSecondsinteger1Watcher liveness probe timeout.
watcher.nodeSelectorobject{}Watcher pod node selector.
watcher.podAnnotationsobject{}Additional annotations for the watcher pod.
watcher.podLabelsobject{}Additional labels for the watcher pod.
watcher.readinessProbe.failureThresholdinteger3Watcher readiness probe failure threshold.
watcher.readinessProbe.httpGet.pathstring"/healthz"Watcher readiness probe HTTP path.
watcher.readinessProbe.httpGet.portinteger3000Watcher readiness probe HTTP port.
watcher.readinessProbe.httpGet.schemestring"HTTPS"Watcher readiness probe HTTP scheme.
watcher.readinessProbe.initialDelaySecondsinteger10Watcher readiness probe initial delay.
watcher.readinessProbe.periodSecondsinteger10Watcher readiness probe interval.
watcher.readinessProbe.successThresholdinteger1Watcher readiness probe success threshold.
watcher.readinessProbe.timeoutSecondsinteger1Watcher readiness probe timeout.
watcher.resources.limits.cpustring"500m"Watcher container CPU limit.
watcher.resources.limits.memorystring"512Mi"Watcher container memory limit.
watcher.resources.requests.cpustring"200m"Watcher container CPU request.
watcher.resources.requests.memorystring"256Mi"Watcher container memory request.
watcher.securityContext.fsGroupinteger<image-dependent>Watcher pod filesystem group.
watcher.securityContext.runAsGroupinteger<image-dependent>Watcher pod group ID.
watcher.securityContext.runAsNonRootbooleantrueWhether the watcher pod must run as non-root.
watcher.securityContext.runAsUserinteger<image-dependent>Watcher pod user ID.
watcher.serviceMonitor.annotationsobject{}Watcher ServiceMonitor annotations.
watcher.serviceMonitor.enabledbooleanfalseWhether to render the watcher ServiceMonitor.
watcher.serviceMonitor.labelsobject{}Watcher ServiceMonitor labels.
watcher.startupProbe.failureThresholdinteger3Watcher startup probe failure threshold.
watcher.startupProbe.httpGet.pathstring"/healthz"Watcher startup probe HTTP path.
watcher.startupProbe.httpGet.portinteger3000Watcher startup probe HTTP port.
watcher.startupProbe.httpGet.schemestring"HTTPS"Watcher startup probe HTTP scheme.
watcher.startupProbe.initialDelaySecondsinteger10Watcher startup probe initial delay.
watcher.startupProbe.periodSecondsinteger10Watcher startup probe interval.
watcher.startupProbe.successThresholdinteger1Watcher startup probe success threshold.
watcher.startupProbe.timeoutSecondsinteger1Watcher startup probe timeout.
watcher.terminationGracePeriodSecondsinteger5Watcher pod termination grace period.
watcher.tolerationslist[]Watcher pod tolerations.
FieldDescriptionExample Values
uuidUnique identifier for the modulehub-operator
onErrorBehavior of the webhook failure policyaudit, ignore, reject
webhookTimeoutWebhook timeout in seconds1 - 30
customLabelsCustom labels for namespaces{namespace: {}}
alwaysIgnoreConditions to always ignore{namespaces: []}
admissionadmission namespaces to always ignore{alwaysIgnore: {namespaces: []}}
watchwatcher namespaces to always ignore{alwaysIgnore: {namespaces: []}}
includedFilesFor working with WebAssembly[“main.wasm”, “wasm_exec.js”]
envEnvironment variables for the container{LOG_LEVEL: "warn"}
rbacCustom RBAC rules[{"apiGroups": ["<apiGroups>"], "resources": ["<resources>"], "verbs": ["<verbs>"]}]
rbacModeRBAC modescoped, admin
additionalWebhooksAdditional webhooks configuration[{"failurePolicy": "Fail", "namespace": "example-namespace"}]