Add OpenEBS v4.6.1 with images repointed to ghcr.io/wrktalk-tech - Loki and Alloy disabled
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
# Patterns to ignore when building packages.
|
||||
# This supports shell glob matching, relative path matching, and
|
||||
# negation (prefixed with !). Only one pattern per line.
|
||||
.DS_Store
|
||||
# Common VCS dirs
|
||||
.git/
|
||||
.gitignore
|
||||
.bzr/
|
||||
.bzrignore
|
||||
.hg/
|
||||
.hgignore
|
||||
.svn/
|
||||
# Common backup files
|
||||
*.swp
|
||||
*.bak
|
||||
*.tmp
|
||||
*.orig
|
||||
*~
|
||||
# Various IDEs
|
||||
.project
|
||||
.idea/
|
||||
*.tmproj
|
||||
.vscode/
|
||||
|
||||
# Don't package templates.
|
||||
README.md.gotmpl
|
||||
|
||||
# Don't packages the tests used for CI.
|
||||
/tests/
|
||||
@@ -0,0 +1,245 @@
|
||||
# Changelog
|
||||
|
||||
> _Contributors should read our [contributors guide][] for instructions on how
|
||||
> to update the changelog._
|
||||
|
||||
This document contains a historical list of changes between releases. Only
|
||||
changes that impact end-user behavior are listed; changes to documentation or
|
||||
internal API changes are not present.
|
||||
|
||||
Unreleased
|
||||
----------
|
||||
|
||||
1.0.1 (2025-04-10)
|
||||
----------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.8.1. (@dehaansa)
|
||||
|
||||
- Update default configreloader resources to match what is set in prometheus-operator project (@dehaansa)
|
||||
|
||||
- Add Vertical Pod Autoscaler support (@QuentinBisson)
|
||||
|
||||
1.0.0 (2025-04-09)
|
||||
----------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update version to `1.0.0`. This Helm chart is now covered with the [backward-compatibility](https://grafana.com/docs/alloy/latest/introduction/backward-compatibility/) policy.
|
||||
|
||||
- Update to Grafana Alloy v1.8.0. (@thampiotr)
|
||||
|
||||
0.12.6 (2025-04-03)
|
||||
----------
|
||||
### Breaking changes
|
||||
|
||||
- configReloader.customArgs are likely to break as the prometheus maintained config reloader does not have the same arguments as the previous image (@dehaansa)
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Change configReloader from jimmydyson/configmap-reload to prometheus-operator/prometheus-config-reloader (@dehaansa)
|
||||
- Update to Grafana Alloy v1.7.5. (@kimxogus)
|
||||
- Add `checksum/config` pod annotation (@kimxogus)
|
||||
|
||||
### Other changes
|
||||
|
||||
- Fix typo in values.yaml documentation (@petewall)
|
||||
|
||||
0.12.5 (2025-03-13)
|
||||
----------
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.7.4. (@dehaansa)
|
||||
|
||||
0.12.4 (2025-03-13)
|
||||
----------
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.7.3. (@dehaansa)
|
||||
|
||||
0.12.3 (2025-03-10)
|
||||
----------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Add support for adding livenessProbe to agent container (@slimes28)
|
||||
|
||||
0.12.2 (2025-03-10)
|
||||
----------
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- Set resource namespace correctly (@shinebayar-g)
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Add a new `automountServiceAccountToken` configuration value for `serviceAccount`. (@ptodev)
|
||||
- Update to Grafana Alloy v1.7.2. (@thampiotr)
|
||||
|
||||
0.12.1 (2025-02-26)
|
||||
----------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.7.1. (@thampiotr)
|
||||
|
||||
0.12.0 (2025-02-24)
|
||||
----------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.7.0. (@thampiotr)
|
||||
|
||||
0.11.0 (2025-01-23)
|
||||
----------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update jimmidyson/configmap-reload to 0.14.0. (@petewall)
|
||||
- Add the ability to deploy extra manifest files. (@dbluxo)
|
||||
|
||||
0.10.1 (2024-12-03)
|
||||
----------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.5.1. (@ptodev)
|
||||
|
||||
0.10.0 (2024-11-13)
|
||||
----------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Add support for adding hostAliases to the Helm chart. (@duncan485)
|
||||
- Update to Grafana Alloy v1.5.0. (@thampiotr)
|
||||
|
||||
0.9.2 (2024-10-18)
|
||||
------------------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.4.3. (@ptodev)
|
||||
|
||||
0.9.1 (2024-10-04)
|
||||
------------------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.4.2. (@ptodev)
|
||||
|
||||
0.9.0 (2024-10-02)
|
||||
------------------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Add lifecyle hook to the Helm chart. (@etiennep)
|
||||
- Add terminationGracePeriodSeconds setting to the Helm chart. (@etiennep)
|
||||
|
||||
0.8.1 (2024-09-26)
|
||||
------------------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.4.1. (@ptodev)
|
||||
|
||||
0.8.0 (2024-09-25)
|
||||
------------------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.4.0. (@ptodev)
|
||||
|
||||
0.7.0 (2024-08-26)
|
||||
------------------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Add PodDisruptionBudget to the Helm chart. (@itspouya)
|
||||
|
||||
0.6.1 (2024-08-23)
|
||||
----------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Add the ability to set --cluster.name in the Helm chart with alloy.clustering.name. (@petewall)
|
||||
- Add the ability to set appProtocol in extraPorts to help OpenShift users to expose gRPC. (@clementduveau)
|
||||
|
||||
### Other changes
|
||||
|
||||
- Update helm chart to use v1.3.1.
|
||||
|
||||
0.6.0 (2024-08-05)
|
||||
------------------
|
||||
|
||||
### Other changes
|
||||
|
||||
- Update helm chart to use v1.3.0.
|
||||
|
||||
- Set `publishNotReadyAddresses` to `true` in the service spec for clustering to fix a bug where peers could not join on startup. (@wildum)
|
||||
|
||||
0.5.1 (2023-07-11)
|
||||
------------------
|
||||
|
||||
### Other changes
|
||||
|
||||
- Update helm chart to use v1.2.1.
|
||||
|
||||
0.5.0 (2024-07-08)
|
||||
------------------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Only utilize spec.internalTrafficPolicy in the Service if deploying to Kubernetes 1.26 or later. (@petewall)
|
||||
|
||||
0.4.0 (2024-06-26)
|
||||
------------------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.2.0. (@ptodev)
|
||||
|
||||
0.3.2 (2024-05-30)
|
||||
------------------
|
||||
|
||||
### Bugfixes
|
||||
|
||||
- Update to Grafana Alloy v1.1.1. (@rfratto)
|
||||
|
||||
0.3.1 (2024-05-22)
|
||||
------------------
|
||||
|
||||
### Bugfixes
|
||||
|
||||
- Fix clustering on instances running within Istio mesh by allowing to change the name of the clustering port
|
||||
|
||||
0.3.0 (2024-05-14)
|
||||
------------------
|
||||
|
||||
### Enhancements
|
||||
|
||||
- Update to Grafana Alloy v1.1.0. (@rfratto)
|
||||
|
||||
0.2.0 (2024-05-08)
|
||||
------------------
|
||||
|
||||
### Other changes
|
||||
|
||||
- Support all [Kubernetes recommended labels](https://kubernetes.io/docs/concepts/overview/working-with-objects/common-labels/) (@nlamirault)
|
||||
|
||||
0.1.1 (2024-04-11)
|
||||
------------------
|
||||
|
||||
### Other changes
|
||||
|
||||
- Add missing Alloy icon to Chart.yaml. (@rfratto)
|
||||
|
||||
0.1.0 (2024-04-09)
|
||||
------------------
|
||||
|
||||
### Features
|
||||
|
||||
- Introduce a Grafana Alloy Helm chart. The Grafana Alloy Helm chart is
|
||||
backwards compatibile with the values.yaml from the `grafana-agent` Helm
|
||||
chart. Review the Helm chart README for a description on how to migrate.
|
||||
(@rfratto)
|
||||
@@ -0,0 +1,6 @@
|
||||
dependencies:
|
||||
- name: crds
|
||||
repository: ""
|
||||
version: 0.0.0
|
||||
digest: sha256:1980431a3d80822fca2e67e9cf16ff7a7f8d1dc87deb9e44d50e85e3e8e33a81
|
||||
generated: "2025-04-11T09:30:48.378858526Z"
|
||||
@@ -0,0 +1,12 @@
|
||||
apiVersion: v2
|
||||
appVersion: v1.8.1
|
||||
dependencies:
|
||||
- condition: crds.create
|
||||
name: crds
|
||||
repository: ""
|
||||
version: 0.0.0
|
||||
description: Grafana Alloy
|
||||
icon: https://raw.githubusercontent.com/grafana/alloy/main/docs/sources/assets/alloy_icon_orange.svg
|
||||
name: alloy
|
||||
type: application
|
||||
version: 1.0.1
|
||||
@@ -0,0 +1,342 @@
|
||||
# Grafana Alloy Helm chart
|
||||
|
||||
  
|
||||
|
||||
Helm chart for deploying [Grafana Alloy][] to Kubernetes.
|
||||
|
||||
[Grafana Alloy]: https://grafana.com/docs/alloy/latest/
|
||||
|
||||
## Usage
|
||||
|
||||
### Setup Grafana chart repository
|
||||
|
||||
```
|
||||
helm repo add grafana https://grafana.github.io/helm-charts
|
||||
helm repo update
|
||||
```
|
||||
|
||||
### Install chart
|
||||
|
||||
To install the chart with the release name my-release:
|
||||
|
||||
`helm install my-release grafana/alloy`
|
||||
|
||||
This chart installs one instance of Grafana Alloy into your Kubernetes cluster
|
||||
using a specific Kubernetes controller. By default, DaemonSet is used. The
|
||||
`controller.type` value can be used to change the controller to either a
|
||||
StatefulSet or Deployment.
|
||||
|
||||
Creating multiple installations of the Helm chart with different controllers is
|
||||
useful if just using the default DaemonSet isn't sufficient.
|
||||
|
||||
## Values
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| alloy.clustering.enabled | bool | `false` | Deploy Alloy in a cluster to allow for load distribution. |
|
||||
| alloy.clustering.name | string | `""` | Name for the Alloy cluster. Used for differentiating between clusters. |
|
||||
| alloy.clustering.portName | string | `"http"` | Name for the port used for clustering, useful if running inside an Istio Mesh |
|
||||
| alloy.configMap.content | string | `""` | Content to assign to the new ConfigMap. This is passed into `tpl` allowing for templating from values. |
|
||||
| alloy.configMap.create | bool | `true` | Create a new ConfigMap for the config file. |
|
||||
| alloy.configMap.key | string | `nil` | Key in ConfigMap to get config from. |
|
||||
| alloy.configMap.name | string | `nil` | Name of existing ConfigMap to use. Used when create is false. |
|
||||
| alloy.enableReporting | bool | `true` | Enables sending Grafana Labs anonymous usage stats to help improve Grafana Alloy. |
|
||||
| alloy.envFrom | list | `[]` | Maps all the keys on a ConfigMap or Secret as environment variables. https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#envfromsource-v1-core |
|
||||
| alloy.extraArgs | list | `[]` | Extra args to pass to `alloy run`: https://grafana.com/docs/alloy/latest/reference/cli/run/ |
|
||||
| alloy.extraEnv | list | `[]` | Extra environment variables to pass to the Alloy container. |
|
||||
| alloy.extraPorts | list | `[]` | Extra ports to expose on the Alloy container. |
|
||||
| alloy.hostAliases | list | `[]` | Host aliases to add to the Alloy container. |
|
||||
| alloy.lifecycle | object | `{}` | Set lifecycle hooks for the Grafana Alloy container. |
|
||||
| alloy.listenAddr | string | `"0.0.0.0"` | Address to listen for traffic on. 0.0.0.0 exposes the UI to other containers. |
|
||||
| alloy.listenPort | int | `12345` | Port to listen for traffic on. |
|
||||
| alloy.listenScheme | string | `"HTTP"` | Scheme is needed for readiness probes. If enabling tls in your configs, set to "HTTPS" |
|
||||
| alloy.livenessProbe | object | `{}` | Set livenessProbe for the Grafana Alloy container. |
|
||||
| alloy.mounts.dockercontainers | bool | `false` | Mount /var/lib/docker/containers from the host into the container for log collection. |
|
||||
| alloy.mounts.extra | list | `[]` | Extra volume mounts to add into the Grafana Alloy container. Does not affect the watch container. |
|
||||
| alloy.mounts.varlog | bool | `false` | Mount /var/log from the host into the container for log collection. |
|
||||
| alloy.resources | object | `{}` | Resource requests and limits to apply to the Grafana Alloy container. |
|
||||
| alloy.securityContext | object | `{}` | Security context to apply to the Grafana Alloy container. |
|
||||
| alloy.stabilityLevel | string | `"generally-available"` | Minimum stability level of components and behavior to enable. Must be one of "experimental", "public-preview", or "generally-available". |
|
||||
| alloy.storagePath | string | `"/tmp/alloy"` | Path to where Grafana Alloy stores data (for example, the Write-Ahead Log). By default, data is lost between reboots. |
|
||||
| alloy.uiPathPrefix | string | `"/"` | Base path where the UI is exposed. |
|
||||
| configReloader.customArgs | list | `[]` | Override the args passed to the container. |
|
||||
| configReloader.enabled | bool | `true` | Enables automatically reloading when the Alloy config changes. |
|
||||
| configReloader.image.digest | string | `""` | SHA256 digest of image to use for config reloading (either in format "sha256:XYZ" or "XYZ"). When set, will override `configReloader.image.tag` |
|
||||
| configReloader.image.registry | string | `"quay.io"` | Config reloader image registry (defaults to docker.io) |
|
||||
| configReloader.image.repository | string | `"prometheus-operator/prometheus-config-reloader"` | Repository to get config reloader image from. |
|
||||
| configReloader.image.tag | string | `"v0.81.0"` | Tag of image to use for config reloading. |
|
||||
| configReloader.resources | object | `{"requests":{"cpu":"10m","memory":"50Mi"}}` | Resource requests and limits to apply to the config reloader container. |
|
||||
| configReloader.securityContext | object | `{}` | Security context to apply to the Grafana configReloader container. |
|
||||
| controller.affinity | object | `{}` | Affinity configuration for pods. |
|
||||
| controller.autoscaling.enabled | bool | `false` | Creates a HorizontalPodAutoscaler for controller type deployment. Deprecated: Please use controller.autoscaling.horizontal instead |
|
||||
| controller.autoscaling.horizontal | object | `{"enabled":false,"maxReplicas":5,"minReplicas":1,"scaleDown":{"policies":[],"selectPolicy":"Max","stabilizationWindowSeconds":300},"scaleUp":{"policies":[],"selectPolicy":"Max","stabilizationWindowSeconds":0},"targetCPUUtilizationPercentage":0,"targetMemoryUtilizationPercentage":80}` | Configures the Horizontal Pod Autoscaler for the controller. |
|
||||
| controller.autoscaling.horizontal.enabled | bool | `false` | Enables the Horizontal Pod Autoscaler for the controller. |
|
||||
| controller.autoscaling.horizontal.maxReplicas | int | `5` | The upper limit for the number of replicas to which the autoscaler can scale up. |
|
||||
| controller.autoscaling.horizontal.minReplicas | int | `1` | The lower limit for the number of replicas to which the autoscaler can scale down. |
|
||||
| controller.autoscaling.horizontal.scaleDown.policies | list | `[]` | List of policies to determine the scale-down behavior. |
|
||||
| controller.autoscaling.horizontal.scaleDown.selectPolicy | string | `"Max"` | Determines which of the provided scaling-down policies to apply if multiple are specified. |
|
||||
| controller.autoscaling.horizontal.scaleDown.stabilizationWindowSeconds | int | `300` | The duration that the autoscaling mechanism should look back on to make decisions about scaling down. |
|
||||
| controller.autoscaling.horizontal.scaleUp.policies | list | `[]` | List of policies to determine the scale-up behavior. |
|
||||
| controller.autoscaling.horizontal.scaleUp.selectPolicy | string | `"Max"` | Determines which of the provided scaling-up policies to apply if multiple are specified. |
|
||||
| controller.autoscaling.horizontal.scaleUp.stabilizationWindowSeconds | int | `0` | The duration that the autoscaling mechanism should look back on to make decisions about scaling up. |
|
||||
| controller.autoscaling.horizontal.targetCPUUtilizationPercentage | int | `0` | Average CPU utilization across all relevant pods, a percentage of the requested value of the resource for the pods. Setting `targetCPUUtilizationPercentage` to 0 will disable CPU scaling. |
|
||||
| controller.autoscaling.horizontal.targetMemoryUtilizationPercentage | int | `80` | Average Memory utilization across all relevant pods, a percentage of the requested value of the resource for the pods. Setting `targetMemoryUtilizationPercentage` to 0 will disable Memory scaling. |
|
||||
| controller.autoscaling.maxReplicas | int | `5` | The upper limit for the number of replicas to which the autoscaler can scale up. |
|
||||
| controller.autoscaling.minReplicas | int | `1` | The lower limit for the number of replicas to which the autoscaler can scale down. |
|
||||
| controller.autoscaling.scaleDown.policies | list | `[]` | List of policies to determine the scale-down behavior. |
|
||||
| controller.autoscaling.scaleDown.selectPolicy | string | `"Max"` | Determines which of the provided scaling-down policies to apply if multiple are specified. |
|
||||
| controller.autoscaling.scaleDown.stabilizationWindowSeconds | int | `300` | The duration that the autoscaling mechanism should look back on to make decisions about scaling down. |
|
||||
| controller.autoscaling.scaleUp.policies | list | `[]` | List of policies to determine the scale-up behavior. |
|
||||
| controller.autoscaling.scaleUp.selectPolicy | string | `"Max"` | Determines which of the provided scaling-up policies to apply if multiple are specified. |
|
||||
| controller.autoscaling.scaleUp.stabilizationWindowSeconds | int | `0` | The duration that the autoscaling mechanism should look back on to make decisions about scaling up. |
|
||||
| controller.autoscaling.targetCPUUtilizationPercentage | int | `0` | Average CPU utilization across all relevant pods, a percentage of the requested value of the resource for the pods. Setting `targetCPUUtilizationPercentage` to 0 will disable CPU scaling. |
|
||||
| controller.autoscaling.targetMemoryUtilizationPercentage | int | `80` | Average Memory utilization across all relevant pods, a percentage of the requested value of the resource for the pods. Setting `targetMemoryUtilizationPercentage` to 0 will disable Memory scaling. |
|
||||
| controller.autoscaling.vertical | object | `{"enabled":false,"recommenders":[],"resourcePolicy":{"containerPolicies":[{"containerName":"alloy","controlledResources":["cpu","memory"],"controlledValues":"RequestsAndLimits","maxAllowed":{},"minAllowed":{}}]},"updatePolicy":null}` | Configures the Vertical Pod Autoscaler for the controller. |
|
||||
| controller.autoscaling.vertical.enabled | bool | `false` | Enables the Vertical Pod Autoscaler for the controller. |
|
||||
| controller.autoscaling.vertical.recommenders | list | `[]` | List of recommenders to use for the Vertical Pod Autoscaler. Recommenders are responsible for generating recommendation for the object. List should be empty (then the default recommender will generate the recommendation) or contain exactly one recommender. |
|
||||
| controller.autoscaling.vertical.resourcePolicy | object | `{"containerPolicies":[{"containerName":"alloy","controlledResources":["cpu","memory"],"controlledValues":"RequestsAndLimits","maxAllowed":{},"minAllowed":{}}]}` | Configures the resource policy for the Vertical Pod Autoscaler. |
|
||||
| controller.autoscaling.vertical.resourcePolicy.containerPolicies | list | `[{"containerName":"alloy","controlledResources":["cpu","memory"],"controlledValues":"RequestsAndLimits","maxAllowed":{},"minAllowed":{}}]` | Configures the container policies for the Vertical Pod Autoscaler. |
|
||||
| controller.autoscaling.vertical.resourcePolicy.containerPolicies[0].controlledResources | list | `["cpu","memory"]` | The controlled resources for the Vertical Pod Autoscaler. |
|
||||
| controller.autoscaling.vertical.resourcePolicy.containerPolicies[0].controlledValues | string | `"RequestsAndLimits"` | The controlled values for the Vertical Pod Autoscaler. Needs to be either RequestsOnly or RequestsAndLimits. |
|
||||
| controller.autoscaling.vertical.resourcePolicy.containerPolicies[0].maxAllowed | object | `{}` | The maximum allowed values for the pods. |
|
||||
| controller.autoscaling.vertical.resourcePolicy.containerPolicies[0].minAllowed | object | `{}` | Defines the min allowed resources for the pod |
|
||||
| controller.autoscaling.vertical.updatePolicy | string | `nil` | Configures the update policy for the Vertical Pod Autoscaler. |
|
||||
| controller.dnsPolicy | string | `"ClusterFirst"` | Configures the DNS policy for the pod. https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy |
|
||||
| controller.enableStatefulSetAutoDeletePVC | bool | `false` | Whether to enable automatic deletion of stale PVCs due to a scale down operation, when controller.type is 'statefulset'. |
|
||||
| controller.extraAnnotations | object | `{}` | Annotations to add to controller. |
|
||||
| controller.extraContainers | list | `[]` | Additional containers to run alongside the Alloy container and initContainers. |
|
||||
| controller.hostNetwork | bool | `false` | Configures Pods to use the host network. When set to true, the ports that will be used must be specified. |
|
||||
| controller.hostPID | bool | `false` | Configures Pods to use the host PID namespace. |
|
||||
| controller.initContainers | list | `[]` | |
|
||||
| controller.nodeSelector | object | `{}` | nodeSelector to apply to Grafana Alloy pods. |
|
||||
| controller.parallelRollout | bool | `true` | Whether to deploy pods in parallel. Only used when controller.type is 'statefulset'. |
|
||||
| controller.podAnnotations | object | `{}` | Extra pod annotations to add. |
|
||||
| controller.podDisruptionBudget | object | `{"enabled":false,"maxUnavailable":null,"minAvailable":null}` | PodDisruptionBudget configuration. |
|
||||
| controller.podDisruptionBudget.enabled | bool | `false` | Whether to create a PodDisruptionBudget for the controller. |
|
||||
| controller.podDisruptionBudget.maxUnavailable | string | `nil` | Maximum number of pods that can be unavailable during a disruption. Note: Only one of minAvailable or maxUnavailable should be set. |
|
||||
| controller.podDisruptionBudget.minAvailable | string | `nil` | Minimum number of pods that must be available during a disruption. Note: Only one of minAvailable or maxUnavailable should be set. |
|
||||
| controller.podLabels | object | `{}` | Extra pod labels to add. |
|
||||
| controller.priorityClassName | string | `""` | priorityClassName to apply to Grafana Alloy pods. |
|
||||
| controller.replicas | int | `1` | Number of pods to deploy. Ignored when controller.type is 'daemonset'. |
|
||||
| controller.terminationGracePeriodSeconds | string | `nil` | Termination grace period in seconds for the Grafana Alloy pods. The default value used by Kubernetes if unspecifed is 30 seconds. |
|
||||
| controller.tolerations | list | `[]` | Tolerations to apply to Grafana Alloy pods. |
|
||||
| controller.topologySpreadConstraints | list | `[]` | Topology Spread Constraints to apply to Grafana Alloy pods. |
|
||||
| controller.type | string | `"daemonset"` | Type of controller to use for deploying Grafana Alloy in the cluster. Must be one of 'daemonset', 'deployment', or 'statefulset'. |
|
||||
| controller.updateStrategy | object | `{}` | Update strategy for updating deployed Pods. |
|
||||
| controller.volumeClaimTemplates | list | `[]` | volumeClaimTemplates to add when controller.type is 'statefulset'. |
|
||||
| controller.volumes.extra | list | `[]` | Extra volumes to add to the Grafana Alloy pod. |
|
||||
| crds.create | bool | `true` | Whether to install CRDs for monitoring. |
|
||||
| extraObjects | list | `[]` | Extra k8s manifests to deploy |
|
||||
| fullnameOverride | string | `nil` | Overrides the chart's computed fullname. Used to change the full prefix of resource names. |
|
||||
| global.image.pullSecrets | list | `[]` | Optional set of global image pull secrets. |
|
||||
| global.image.registry | string | `""` | Global image registry to use if it needs to be overridden for some specific use cases (e.g local registries, custom images, ...) |
|
||||
| global.podSecurityContext | object | `{}` | Security context to apply to the Grafana Alloy pod. |
|
||||
| image.digest | string | `nil` | Grafana Alloy image's SHA256 digest (either in format "sha256:XYZ" or "XYZ"). When set, will override `image.tag`. |
|
||||
| image.pullPolicy | string | `"IfNotPresent"` | Grafana Alloy image pull policy. |
|
||||
| image.pullSecrets | list | `[]` | Optional set of image pull secrets. |
|
||||
| image.registry | string | `"docker.io"` | Grafana Alloy image registry (defaults to docker.io) |
|
||||
| image.repository | string | `"grafana/alloy"` | Grafana Alloy image repository. |
|
||||
| image.tag | string | `nil` | Grafana Alloy image tag. When empty, the Chart's appVersion is used. |
|
||||
| ingress.annotations | object | `{}` | |
|
||||
| ingress.enabled | bool | `false` | Enables ingress for Alloy (Faro port) |
|
||||
| ingress.extraPaths | list | `[]` | |
|
||||
| ingress.faroPort | int | `12347` | |
|
||||
| ingress.hosts[0] | string | `"chart-example.local"` | |
|
||||
| ingress.labels | object | `{}` | |
|
||||
| ingress.path | string | `"/"` | |
|
||||
| ingress.pathType | string | `"Prefix"` | |
|
||||
| ingress.tls | list | `[]` | |
|
||||
| nameOverride | string | `nil` | Overrides the chart's name. Used to change the infix in the resource names. |
|
||||
| namespaceOverride | string | `nil` | Overrides the chart's namespace. |
|
||||
| rbac.create | bool | `true` | Whether to create RBAC resources for Alloy. |
|
||||
| service.annotations | object | `{}` | |
|
||||
| service.clusterIP | string | `""` | Cluster IP, can be set to None, empty "" or an IP address |
|
||||
| service.enabled | bool | `true` | Creates a Service for the controller's pods. |
|
||||
| service.internalTrafficPolicy | string | `"Cluster"` | Value for internal traffic policy. 'Cluster' or 'Local' |
|
||||
| service.nodePort | int | `31128` | NodePort port. Only takes effect when `service.type: NodePort` |
|
||||
| service.type | string | `"ClusterIP"` | Service type |
|
||||
| serviceAccount.additionalLabels | object | `{}` | Additional labels to add to the created service account. |
|
||||
| serviceAccount.annotations | object | `{}` | Annotations to add to the created service account. |
|
||||
| serviceAccount.automountServiceAccountToken | bool | `true` | |
|
||||
| serviceAccount.create | bool | `true` | Whether to create a service account for the Grafana Alloy deployment. |
|
||||
| serviceAccount.name | string | `nil` | The name of the existing service account to use when serviceAccount.create is false. |
|
||||
| serviceMonitor.additionalLabels | object | `{}` | Additional labels for the service monitor. |
|
||||
| serviceMonitor.enabled | bool | `false` | |
|
||||
| serviceMonitor.interval | string | `""` | Scrape interval. If not set, the Prometheus default scrape interval is used. |
|
||||
| serviceMonitor.metricRelabelings | list | `[]` | MetricRelabelConfigs to apply to samples after scraping, but before ingestion. ref: https://github.com/prometheus-operator/prometheus-operator/blob/main/Documentation/api.md#relabelconfig |
|
||||
| serviceMonitor.relabelings | list | `[]` | RelabelConfigs to apply to samples before scraping ref: https://github.com/prometheus-operator/prometheus-operator/blob/main/Documentation/api.md#relabelconfig |
|
||||
| serviceMonitor.tlsConfig | object | `{}` | Customize tls parameters for the service monitor |
|
||||
|
||||
#### Migrate from `grafana/grafana-agent` chart to `grafana/alloy`
|
||||
|
||||
The `values.yaml` file for the `grafana/grafana-agent` chart is compatible with
|
||||
the chart for `grafana/alloy`, with two exceptions:
|
||||
|
||||
* The `agent` field in `values.yaml` is deprecated in favor of `alloy`. Support
|
||||
for the `agent` field will be removed in a future release.
|
||||
|
||||
* The default value for `alloy.listenPort` is `12345` to align with the default
|
||||
listen port in other installations. To retain the previous default, set
|
||||
`alloy.listenPort` to `80` when installing.
|
||||
|
||||
### alloy.stabilityLevel
|
||||
|
||||
`alloy.stabilityLevel` controls the minimum level of stability for what
|
||||
components can be created (directly or through imported modules). Note that
|
||||
setting this field to a lower stability may also enable internal behaviour of a
|
||||
lower stability, such as experimental memory optimizations.
|
||||
|
||||
Valid settings are `experimental`, `public-preview`, and `generally-available`.
|
||||
|
||||
### alloy.extraArgs
|
||||
|
||||
`alloy.extraArgs` allows for passing extra arguments to the Grafana Alloy
|
||||
container. The list of available arguments is documented on [alloy run][].
|
||||
|
||||
> **WARNING**: Using `alloy.extraArgs` does not have a stable API. Things may
|
||||
> break between Chart upgrade if an argument gets added to the template.
|
||||
|
||||
[alloy run]: https://grafana.com/docs/alloy/latest/reference/cli/run/
|
||||
|
||||
### alloy.extraPorts
|
||||
|
||||
`alloy.extraPorts` allows for configuring specific open ports.
|
||||
|
||||
The detained specification of ports can be found at the [Kubernetes Pod documents](https://kubernetes.io/docs/reference/kubernetes-api/workload-resources/pod-v1/#ports).
|
||||
|
||||
Port numbers specified must be 0 < x < 65535.
|
||||
|
||||
| ChartPort | KubePort | Description |
|
||||
|-----------|----------|-------------|
|
||||
| targetPort | containerPort | Number of port to expose on the pod's IP address. |
|
||||
| hostPort | hostPort | (Optional) Number of port to expose on the host. Daemonsets taking traffic might find this useful. |
|
||||
| name | name | If specified, this must be an `IANA_SVC_NAME` and unique within the pod. Each named port in a pod must have a unique name. Name for the port that can be referred to by services.
|
||||
| protocol | protocol | Must be UDP, TCP, or SCTP. Defaults to "TCP". |
|
||||
| appProtocol | appProtocol | Hint on application protocol. This is used to expose Alloy externally on OpenShift clusters using "h2c". Optional. No default value. |
|
||||
|
||||
### alloy.listenAddr
|
||||
|
||||
`alloy.listenAddr` allows for restricting which address Alloy listens on
|
||||
for network traffic on its HTTP server. By default, this is `0.0.0.0` to allow
|
||||
its UI to be exposed when port-forwarding and to expose its metrics to other
|
||||
Alloy instances in the cluster.
|
||||
|
||||
### alloy.configMap.config
|
||||
|
||||
`alloy.configMap.content` holds the Grafana Alloy configuration to use.
|
||||
|
||||
If `alloy.configMap.content` is not provided, a [default configuration file][default-config] is
|
||||
used. When provided, `alloy.configMap.content` must hold a valid Alloy configuration file.
|
||||
|
||||
[default-config]: ./config/example.alloy
|
||||
|
||||
### alloy.securityContext
|
||||
|
||||
`alloy.securityContext` sets the securityContext passed to the Grafana
|
||||
Alloy container.
|
||||
|
||||
By default, Grafana Alloy containers are not able to collect telemetry from the
|
||||
host node or other specific types of privileged telemetry data. See [Collecting
|
||||
logs from other containers][#collecting-logs-from-other-containers] and
|
||||
[Collecting host node telemetry][#collecting-host-node-telemetry] below for
|
||||
more information on how to enable these capabilities.
|
||||
|
||||
### rbac.create
|
||||
|
||||
`rbac.create` enables the creation of ClusterRole and ClusterRoleBindings for
|
||||
the Grafana Alloy containers to use. The default permission set allows
|
||||
components like [discovery.kubernetes][] to work properly.
|
||||
|
||||
[discovery.kubernetes]: https://grafana.com/docs/alloy/latest/reference/components/discovery.kubernetes/
|
||||
|
||||
### controller.autoscaling
|
||||
|
||||
`controller.autoscaling.enabled` enables the creation of a HorizontalPodAutoscaler. It is only used when `controller.type` is set to `deployment` or `statefulset`.
|
||||
|
||||
`controller.autoscaling` is intended to be used with [clustered][] mode.
|
||||
|
||||
> **WARNING**: Using `controller.autoscaling` for any other Grafana Alloy
|
||||
> configuration could lead to redundant or double telemetry collection.
|
||||
|
||||
[clustered]: https://grafana.com/docs/alloy/latest/reference/cli/run/#clustered-mode
|
||||
|
||||
When using autoscaling with a StatefulSet controller and have enabled
|
||||
volumeClaimTemplates to be created alongside the StatefulSet, it is possible to
|
||||
leak up to `maxReplicas` PVCs when the HPA is scaling down. If you're on
|
||||
Kubernetes version `>=1.23-0` and your cluster has the
|
||||
`StatefulSetAutoDeletePVC` feature gate enabled, you can set
|
||||
`enableStatefulSetAutoDeletePVC` to true to automatically delete stale PVCs.
|
||||
|
||||
Using `controller.autoscaling` requires the target metric (cpu/memory) to have
|
||||
its resource requests set up for both the Alloy and config-reloader containers
|
||||
so that the HPA can use them to calculate the replica count from the actual
|
||||
resource utilization.
|
||||
|
||||
## Collecting logs from other containers
|
||||
|
||||
There are two ways to collect logs from other containers within the cluster
|
||||
Alloy is deployed in.
|
||||
|
||||
### loki.source.kubernetes
|
||||
|
||||
The [loki.source.kubernetes][] component may be used to collect logs from
|
||||
containers using the Kubernetes API. This component does not require mounting
|
||||
the hosts filesystem into Alloy, nor requires additional security contexts to
|
||||
work correctly.
|
||||
|
||||
[loki.source.kubernetes]: https://grafana.com/docs/alloy/latest/reference/components/loki.source.kubernetes/
|
||||
|
||||
### File-based collection
|
||||
|
||||
Logs may also be collected by mounting the host's filesystem into the Alloy
|
||||
container, bypassing the need to communicate with the Kubrnetes API.
|
||||
|
||||
To mount logs from other containers to Grafana Alloy directly:
|
||||
|
||||
* Set `alloy.mounts.dockercontainers` to `true`.
|
||||
* Set `alloy.securityContext` to:
|
||||
```yaml
|
||||
privileged: true
|
||||
runAsUser: 0
|
||||
```
|
||||
|
||||
## Collecting host node telemetry
|
||||
|
||||
Telemetry from the host, such as host-specific log files (from `/var/logs`) or
|
||||
metrics from `/proc` and `/sys` are not accessible to Grafana Alloy containers.
|
||||
|
||||
To expose this information to Grafana Alloy for telemetry collection:
|
||||
|
||||
* Set `alloy.mounts.dockercontainers` to `true`.
|
||||
* Mount `/proc` and `/sys` from the host into the container.
|
||||
* Set `alloy.securityContext` to:
|
||||
```yaml
|
||||
privileged: true
|
||||
runAsUser: 0
|
||||
```
|
||||
|
||||
## Expose Alloy externally on OpenShift clusters
|
||||
|
||||
If you want to send telemetry from an Alloy instance outside of the OpenShift clusters over gRPC towards the Alloy instance on the OpenShift clusters, you need to:
|
||||
|
||||
* Set the optional `appProtocol` on `alloy.extraPorts` to `h2c`
|
||||
* Expose the service via Ingress or Route within the OpenShift cluster. Example of a Route in OpenShift:
|
||||
```yaml
|
||||
kind: Route
|
||||
apiVersion: route.openshift.io/v1
|
||||
metadata:
|
||||
name: route-otlp-alloy-h2c
|
||||
spec:
|
||||
to:
|
||||
kind: Service
|
||||
name: test-grpc-h2c
|
||||
weight: 100
|
||||
port:
|
||||
targetPort: otlp-grpc
|
||||
tls:
|
||||
termination: edge
|
||||
insecureEdgeTerminationPolicy: Redirect
|
||||
wildcardPolicy: None
|
||||
```
|
||||
|
||||
Once this Ingress/Route is exposed it would then allow gRPC communication for (for example) traces. This allow an Alloy instance on a VM or another Kubernetes/OpenShift cluster to be able to communicate over gRPC via the exposed Ingress or Route.
|
||||
@@ -0,0 +1,3 @@
|
||||
apiVersion: v2
|
||||
name: crds
|
||||
version: 0.0.0
|
||||
@@ -0,0 +1,205 @@
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
kind: CustomResourceDefinition
|
||||
metadata:
|
||||
annotations:
|
||||
controller-gen.kubebuilder.io/version: v0.9.2
|
||||
creationTimestamp: null
|
||||
name: podlogs.monitoring.grafana.com
|
||||
spec:
|
||||
group: monitoring.grafana.com
|
||||
names:
|
||||
categories:
|
||||
- grafana-alloy
|
||||
- alloy
|
||||
kind: PodLogs
|
||||
listKind: PodLogsList
|
||||
plural: podlogs
|
||||
singular: podlogs
|
||||
scope: Namespaced
|
||||
versions:
|
||||
- name: v1alpha2
|
||||
schema:
|
||||
openAPIV3Schema:
|
||||
description: PodLogs defines how to collect logs for a Pod.
|
||||
properties:
|
||||
apiVersion:
|
||||
description: 'APIVersion defines the versioned schema of this representation
|
||||
of an object. Servers should convert recognized schemas to the latest
|
||||
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
|
||||
type: string
|
||||
kind:
|
||||
description: 'Kind is a string value representing the REST resource this
|
||||
object represents. Servers may infer this from the endpoint the client
|
||||
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
|
||||
type: string
|
||||
metadata:
|
||||
type: object
|
||||
spec:
|
||||
description: PodLogsSpec defines how to collect logs for a Pod.
|
||||
properties:
|
||||
namespaceSelector:
|
||||
description: Selector to select which namespaces the Pod objects are
|
||||
discovered from.
|
||||
properties:
|
||||
matchExpressions:
|
||||
description: matchExpressions is a list of label selector requirements.
|
||||
The requirements are ANDed.
|
||||
items:
|
||||
description: A label selector requirement is a selector that
|
||||
contains values, a key, and an operator that relates the key
|
||||
and values.
|
||||
properties:
|
||||
key:
|
||||
description: key is the label key that the selector applies
|
||||
to.
|
||||
type: string
|
||||
operator:
|
||||
description: operator represents a key's relationship to
|
||||
a set of values. Valid operators are In, NotIn, Exists
|
||||
and DoesNotExist.
|
||||
type: string
|
||||
values:
|
||||
description: values is an array of string values. If the
|
||||
operator is In or NotIn, the values array must be non-empty.
|
||||
If the operator is Exists or DoesNotExist, the values
|
||||
array must be empty. This array is replaced during a strategic
|
||||
merge patch.
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
description: matchLabels is a map of {key,value} pairs. A single
|
||||
{key,value} in the matchLabels map is equivalent to an element
|
||||
of matchExpressions, whose key field is "key", the operator
|
||||
is "In", and the values array contains only "value". The requirements
|
||||
are ANDed.
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
relabelings:
|
||||
description: RelabelConfigs to apply to logs before delivering.
|
||||
items:
|
||||
description: 'RelabelConfig allows dynamic rewriting of the label
|
||||
set, being applied to samples before ingestion. It defines `<metric_relabel_configs>`-section
|
||||
of Prometheus configuration. More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#metric_relabel_configs'
|
||||
properties:
|
||||
action:
|
||||
default: replace
|
||||
description: Action to perform based on regex matching. Default
|
||||
is 'replace'. uppercase and lowercase actions require Prometheus
|
||||
>= 2.36.
|
||||
enum:
|
||||
- replace
|
||||
- Replace
|
||||
- keep
|
||||
- Keep
|
||||
- drop
|
||||
- Drop
|
||||
- hashmod
|
||||
- HashMod
|
||||
- labelmap
|
||||
- LabelMap
|
||||
- labeldrop
|
||||
- LabelDrop
|
||||
- labelkeep
|
||||
- LabelKeep
|
||||
- lowercase
|
||||
- Lowercase
|
||||
- uppercase
|
||||
- Uppercase
|
||||
type: string
|
||||
modulus:
|
||||
description: Modulus to take of the hash of the source label
|
||||
values.
|
||||
format: int64
|
||||
type: integer
|
||||
regex:
|
||||
description: Regular expression against which the extracted
|
||||
value is matched. Default is '(.*)'
|
||||
type: string
|
||||
replacement:
|
||||
description: Replacement value against which a regex replace
|
||||
is performed if the regular expression matches. Regex capture
|
||||
groups are available. Default is '$1'
|
||||
type: string
|
||||
separator:
|
||||
description: Separator placed between concatenated source label
|
||||
values. default is ';'.
|
||||
type: string
|
||||
sourceLabels:
|
||||
description: The source labels select values from existing labels.
|
||||
Their content is concatenated using the configured separator
|
||||
and matched against the configured regular expression for
|
||||
the replace, keep, and drop actions.
|
||||
items:
|
||||
description: LabelName is a valid Prometheus label name which
|
||||
may only contain ASCII letters, numbers, as well as underscores.
|
||||
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
|
||||
type: string
|
||||
type: array
|
||||
targetLabel:
|
||||
description: Label to which the resulting value is written in
|
||||
a replace action. It is mandatory for replace actions. Regex
|
||||
capture groups are available.
|
||||
type: string
|
||||
type: object
|
||||
type: array
|
||||
selector:
|
||||
description: Selector to select Pod objects. Required.
|
||||
properties:
|
||||
matchExpressions:
|
||||
description: matchExpressions is a list of label selector requirements.
|
||||
The requirements are ANDed.
|
||||
items:
|
||||
description: A label selector requirement is a selector that
|
||||
contains values, a key, and an operator that relates the key
|
||||
and values.
|
||||
properties:
|
||||
key:
|
||||
description: key is the label key that the selector applies
|
||||
to.
|
||||
type: string
|
||||
operator:
|
||||
description: operator represents a key's relationship to
|
||||
a set of values. Valid operators are In, NotIn, Exists
|
||||
and DoesNotExist.
|
||||
type: string
|
||||
values:
|
||||
description: values is an array of string values. If the
|
||||
operator is In or NotIn, the values array must be non-empty.
|
||||
If the operator is Exists or DoesNotExist, the values
|
||||
array must be empty. This array is replaced during a strategic
|
||||
merge patch.
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
description: matchLabels is a map of {key,value} pairs. A single
|
||||
{key,value} in the matchLabels map is equivalent to an element
|
||||
of matchExpressions, whose key field is "key", the operator
|
||||
is "In", and the values array contains only "value". The requirements
|
||||
are ANDed.
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
required:
|
||||
- selector
|
||||
type: object
|
||||
type: object
|
||||
served: true
|
||||
storage: true
|
||||
@@ -0,0 +1,3 @@
|
||||
serviceAccount:
|
||||
additionalLabels:
|
||||
test: "true"
|
||||
@@ -0,0 +1,7 @@
|
||||
alloy:
|
||||
clustering:
|
||||
enabled: true
|
||||
|
||||
controller:
|
||||
type: 'statefulset'
|
||||
replicas: 3
|
||||
@@ -0,0 +1,5 @@
|
||||
controller:
|
||||
type: deployment
|
||||
podDisruptionBudget:
|
||||
enabled: true
|
||||
maxUnavailable: 1
|
||||
@@ -0,0 +1,5 @@
|
||||
controller:
|
||||
type: deployment
|
||||
podDisruptionBudget:
|
||||
enabled: true
|
||||
minAvailable: 1
|
||||
@@ -0,0 +1,5 @@
|
||||
controller:
|
||||
type: statefulset
|
||||
podDisruptionBudget:
|
||||
enabled: true
|
||||
maxUnavailable: 1
|
||||
@@ -0,0 +1,5 @@
|
||||
controller:
|
||||
type: statefulset
|
||||
podDisruptionBudget:
|
||||
enabled: true
|
||||
minAvailable: 1
|
||||
@@ -0,0 +1,12 @@
|
||||
controller:
|
||||
volumes:
|
||||
extra:
|
||||
- name: cache-volume
|
||||
emptyDir:
|
||||
sizeLimit: 500Mi
|
||||
|
||||
alloy:
|
||||
mounts:
|
||||
extra:
|
||||
- mountPath: /cache
|
||||
name: cache-volume
|
||||
@@ -0,0 +1,5 @@
|
||||
# Test rendering of the chart with the controller explicitly set to DaemonSet.
|
||||
controller:
|
||||
type: daemonset
|
||||
hostNetwork: true
|
||||
dnsPolicy: ClusterFirstWithHostNet
|
||||
@@ -0,0 +1,3 @@
|
||||
# Test rendering of the chart with the controller explicitly set to DaemonSet.
|
||||
controller:
|
||||
type: daemonset
|
||||
@@ -0,0 +1,26 @@
|
||||
# Test rendering of the chart with the controller explicitly set to Deployment and autoscaling enabled.
|
||||
controller:
|
||||
type: deployment
|
||||
autoscaling:
|
||||
horizontal:
|
||||
enabled: true
|
||||
scaleDown:
|
||||
policies:
|
||||
- type: Pods
|
||||
value: 4
|
||||
periodSeconds: 60
|
||||
selectPolicy: Min
|
||||
stabilizationWindowSeconds: 100
|
||||
scaleUp:
|
||||
policies:
|
||||
- type: Pods
|
||||
value: 4
|
||||
periodSeconds: 60
|
||||
- type: Percent
|
||||
value: 100
|
||||
periodSeconds: 15
|
||||
stabilizationWindowSeconds: 80
|
||||
alloy:
|
||||
resources:
|
||||
requests:
|
||||
memory: 100Mi
|
||||
@@ -0,0 +1,3 @@
|
||||
# Test rendering of the chart with the controller explicitly set to Deployment.
|
||||
controller:
|
||||
type: deployment
|
||||
@@ -0,0 +1,26 @@
|
||||
# Test rendering of the chart with the controller explicitly set to StatefulSet and autoscaling the old way enabled.
|
||||
controller:
|
||||
type: statefulset
|
||||
autoscaling:
|
||||
enabled: true
|
||||
scaleDown:
|
||||
policies:
|
||||
- type: Pods
|
||||
value: 4
|
||||
periodSeconds: 60
|
||||
selectPolicy: Min
|
||||
stabilizationWindowSeconds: 100
|
||||
scaleUp:
|
||||
policies:
|
||||
- type: Pods
|
||||
value: 4
|
||||
periodSeconds: 60
|
||||
- type: Percent
|
||||
value: 100
|
||||
periodSeconds: 15
|
||||
stabilizationWindowSeconds: 80
|
||||
enableStatefulSetAutoDeletePVC: true
|
||||
alloy:
|
||||
resources:
|
||||
requests:
|
||||
memory: 100Mi
|
||||
@@ -0,0 +1,3 @@
|
||||
# Test rendering of the chart with the controller explicitly set to StatefulSet.
|
||||
controller:
|
||||
type: statefulset
|
||||
@@ -0,0 +1,10 @@
|
||||
alloy:
|
||||
configMap:
|
||||
content: |-
|
||||
logging {
|
||||
level = "warn"
|
||||
format = "logfmt"
|
||||
}
|
||||
discovery.kubernetes "custom_pods" {
|
||||
role = "pod"
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
# Test rendering of the chart with everything set to the default values.
|
||||
@@ -0,0 +1,9 @@
|
||||
# Test rendering of the chart with the service monitor enabled
|
||||
alloy:
|
||||
listenScheme: HTTPS
|
||||
service:
|
||||
enabled: true
|
||||
serviceMonitor:
|
||||
enabled: true
|
||||
tlsConfig:
|
||||
insecureSkipVerify: true
|
||||
@@ -0,0 +1,5 @@
|
||||
# Test rendering of the chart with the service monitor enabled
|
||||
service:
|
||||
enabled: true
|
||||
serviceMonitor:
|
||||
enabled: true
|
||||
@@ -0,0 +1,5 @@
|
||||
# Specify extra ports for verifying rendering the template works
|
||||
alloy:
|
||||
envFrom:
|
||||
- configMapRef:
|
||||
name: special-config
|
||||
@@ -0,0 +1,5 @@
|
||||
alloy:
|
||||
configMap:
|
||||
create: false
|
||||
name: existing-config
|
||||
key: my-config.alloy
|
||||
@@ -0,0 +1,9 @@
|
||||
# Specify extra ports for verifying rendering the template works
|
||||
alloy:
|
||||
extraEnv:
|
||||
- name: GREETING
|
||||
value: "Warm greetings to"
|
||||
- name: HONORIFIC
|
||||
value: "The Most Honorable"
|
||||
- name: NAME
|
||||
value: "Kubernetes"
|
||||
@@ -0,0 +1,8 @@
|
||||
extraObjects:
|
||||
- apiVersion: v1
|
||||
kind: Secret
|
||||
metadata:
|
||||
name: grafana-cloud
|
||||
stringData:
|
||||
PROMETHEUS_HOST: 'https://prometheus-us-central1.grafana.net/api/prom/push'
|
||||
PROMETHEUS_USERNAME: '123456'
|
||||
@@ -0,0 +1,7 @@
|
||||
# Specify extra ports for verifying rendering the template works
|
||||
alloy:
|
||||
extraPorts:
|
||||
- name: jaeger-thrift
|
||||
port: 14268
|
||||
targetPort: 14268
|
||||
protocol: TCP
|
||||
@@ -0,0 +1,9 @@
|
||||
alloy:
|
||||
extraPorts:
|
||||
- name: "faro"
|
||||
port: 12347
|
||||
targetPort: 12347
|
||||
protocol: "TCP"
|
||||
|
||||
ingress:
|
||||
enabled: true
|
||||
@@ -0,0 +1,13 @@
|
||||
# Test rendering of the chart with the global image pull secret explicitly set.
|
||||
global:
|
||||
image:
|
||||
pullSecrets:
|
||||
- name: global-cred
|
||||
|
||||
podSecurityContext:
|
||||
runAsUser: 1000
|
||||
runAsGroup: 1000
|
||||
|
||||
image:
|
||||
pullSecrets:
|
||||
- name: local-cred
|
||||
@@ -0,0 +1,11 @@
|
||||
# Test rendering of the chart with the global image registry explicitly set to another value.
|
||||
global:
|
||||
image:
|
||||
registry: quay.io
|
||||
|
||||
image:
|
||||
registry: docker.com # Invalid value by default
|
||||
|
||||
configReloader:
|
||||
image:
|
||||
registry: docker.com
|
||||
@@ -0,0 +1,5 @@
|
||||
alloy:
|
||||
hostAliases:
|
||||
- ip: "20.21.22.23"
|
||||
hostnames:
|
||||
- "grafana.company.net"
|
||||
@@ -0,0 +1,29 @@
|
||||
controller:
|
||||
initContainers:
|
||||
- name: geo-ip
|
||||
image: ghcr.io/maxmind/geoipupdate:v6.0
|
||||
volumeMounts:
|
||||
- name: geoip
|
||||
mountPath: /etc/geoip
|
||||
volumes:
|
||||
- name: geoip
|
||||
emptyDir: {}
|
||||
env:
|
||||
- name: GEOIPUPDATE_ACCOUNT_ID
|
||||
value: "geoipupdate_account_id"
|
||||
- name: GEOIPUPDATE_LICENSE_KEY
|
||||
value: "geoipupdate_license_key"
|
||||
- name: GEOIPUPDATE_EDITION_IDS
|
||||
value: "GeoLite2-ASN GeoLite2-City GeoLite2-Country"
|
||||
- name: GEOIPUPDATE_DB_DIR
|
||||
value: "/etc/geoip"
|
||||
volumes:
|
||||
extra:
|
||||
- name: geoip
|
||||
mountPath: /etc/geoip
|
||||
|
||||
alloy:
|
||||
mounts:
|
||||
extra:
|
||||
- name: geoip
|
||||
mountPath: /etc/geoip
|
||||
@@ -0,0 +1,8 @@
|
||||
controller:
|
||||
type: deployment
|
||||
|
||||
alloy:
|
||||
lifecycle:
|
||||
preStop:
|
||||
exec:
|
||||
command: ["/bin/sh", "-c", "sleep 1"]
|
||||
@@ -0,0 +1,11 @@
|
||||
alloy:
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /metrics
|
||||
port: 12345
|
||||
scheme: HTTP
|
||||
initialDelaySeconds: 30
|
||||
timeoutSeconds: 2
|
||||
periodSeconds: 30
|
||||
successThreshold: 1
|
||||
failureThreshold: 3
|
||||
@@ -0,0 +1,4 @@
|
||||
# Test rendering of the chart with the image pull secret explicitly set.
|
||||
image:
|
||||
pullSecrets:
|
||||
- name: local-cred
|
||||
@@ -0,0 +1,7 @@
|
||||
# Test rendering of the chart with the individual image registries explicitly set to another value.
|
||||
image:
|
||||
registry: quay.io
|
||||
|
||||
configReloader:
|
||||
image:
|
||||
registry: quay.io
|
||||
@@ -0,0 +1,11 @@
|
||||
controller:
|
||||
nodeSelector:
|
||||
key1: "value1"
|
||||
tolerations:
|
||||
- key: "key1"
|
||||
operator: "Equal"
|
||||
value: "value1"
|
||||
effect: "NoSchedule"
|
||||
- key: "key2"
|
||||
operator: "Exists"
|
||||
effect: "NoSchedule"
|
||||
@@ -0,0 +1,7 @@
|
||||
global:
|
||||
podSecurityContext:
|
||||
fsGroup: 473
|
||||
alloy:
|
||||
securityContext:
|
||||
runAsUser: 473
|
||||
runAsGroup: 473
|
||||
@@ -0,0 +1,4 @@
|
||||
# Test correct rendering of the pod annotations
|
||||
controller:
|
||||
podAnnotations:
|
||||
testAnnotationKey: testAnnotationValue
|
||||
@@ -0,0 +1,29 @@
|
||||
controller:
|
||||
extraContainers:
|
||||
- name: geo-ip
|
||||
image: ghcr.io/maxmind/geoipupdate:v6.0
|
||||
volumeMounts:
|
||||
- name: geoip
|
||||
mountPath: /etc/geoip
|
||||
volumes:
|
||||
- name: geoip
|
||||
emptyDir: {}
|
||||
env:
|
||||
- name: GEOIPUPDATE_ACCOUNT_ID
|
||||
value: "geoipupdate_account_id"
|
||||
- name: GEOIPUPDATE_LICENSE_KEY
|
||||
value: "geoipupdate_license_key"
|
||||
- name: GEOIPUPDATE_EDITION_IDS
|
||||
value: "GeoLite2-ASN GeoLite2-City GeoLite2-Country"
|
||||
- name: GEOIPUPDATE_DB_DIR
|
||||
value: "/etc/geoip"
|
||||
volumes:
|
||||
extra:
|
||||
- name: geoip
|
||||
mountPath: /etc/geoip
|
||||
|
||||
alloy:
|
||||
mounts:
|
||||
extra:
|
||||
- name: geoip
|
||||
mountPath: /etc/geoip
|
||||
@@ -0,0 +1,3 @@
|
||||
controller:
|
||||
type: deployment
|
||||
terminationGracePeriodSeconds: 20
|
||||
@@ -0,0 +1,10 @@
|
||||
controller:
|
||||
type: deployment
|
||||
topologySpreadConstraints:
|
||||
- maxSkew: 1
|
||||
topologyKey: topology.kubernetes.io/zone
|
||||
whenUnsatisfiable: ScheduleAnyway
|
||||
labelSelector:
|
||||
matchLabels:
|
||||
app.kubernetes.io/name: alloy
|
||||
app.kubernetes.io/instance: alloy
|
||||
@@ -0,0 +1,10 @@
|
||||
image:
|
||||
registry: "docker.io"
|
||||
repository: "grafana/agent"
|
||||
digest: "sha256:82575a7be3e4770e53f620298e58bcc4cdb0fd0338e01c4b206cae9e3ca46ebf"
|
||||
|
||||
configReloader:
|
||||
image:
|
||||
registry: "docker.io"
|
||||
repository: "jimmidyson/configmap-reload"
|
||||
digest: "sha256:5af9d3041d12a3e63f115125f89b66d2ba981fe82e64302ac370c5496055059c"
|
||||
@@ -0,0 +1,28 @@
|
||||
logging {
|
||||
level = "info"
|
||||
format = "logfmt"
|
||||
}
|
||||
|
||||
discovery.kubernetes "pods" {
|
||||
role = "pod"
|
||||
}
|
||||
|
||||
discovery.kubernetes "nodes" {
|
||||
role = "node"
|
||||
}
|
||||
|
||||
discovery.kubernetes "services" {
|
||||
role = "service"
|
||||
}
|
||||
|
||||
discovery.kubernetes "endpoints" {
|
||||
role = "endpoints"
|
||||
}
|
||||
|
||||
discovery.kubernetes "endpointslices" {
|
||||
role = "endpointslice"
|
||||
}
|
||||
|
||||
discovery.kubernetes "ingresses" {
|
||||
role = "ingress"
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
Welcome to Grafana Alloy!
|
||||
@@ -0,0 +1,25 @@
|
||||
{{/*
|
||||
Retrieve configMap name from the name of the chart or the ConfigMap the user
|
||||
specified.
|
||||
*/}}
|
||||
{{- define "alloy.config-map.name" -}}
|
||||
{{- $values := (mustMergeOverwrite .Values.alloy (or .Values.agent dict)) -}}
|
||||
{{- if $values.configMap.name -}}
|
||||
{{- $values.configMap.name }}
|
||||
{{- else -}}
|
||||
{{- include "alloy.fullname" . }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
The name of the config file is the default or the key the user specified in the
|
||||
ConfigMap.
|
||||
*/}}
|
||||
{{- define "alloy.config-map.key" -}}
|
||||
{{- $values := (mustMergeOverwrite .Values.alloy (or .Values.agent dict)) -}}
|
||||
{{- if $values.configMap.key -}}
|
||||
{{- $values.configMap.key }}
|
||||
{{- else -}}
|
||||
config.alloy
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,162 @@
|
||||
{{/*
|
||||
Expand the name of the chart.
|
||||
*/}}
|
||||
{{- define "alloy.name" -}}
|
||||
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create a default fully qualified app name.
|
||||
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||
If release name contains chart name it will be used as a full name.
|
||||
*/}}
|
||||
{{- define "alloy.fullname" -}}
|
||||
{{- if .Values.fullnameOverride }}
|
||||
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
|
||||
{{- else }}
|
||||
{{- $name := default .Chart.Name .Values.nameOverride }}
|
||||
{{- if contains $name .Release.Name }}
|
||||
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
|
||||
{{- else }}
|
||||
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create chart name and version as used by the chart label.
|
||||
*/}}
|
||||
{{- define "alloy.chart" -}}
|
||||
{{- if index .Values "$chart_tests" }}
|
||||
{{- printf "%s" .Chart.Name | replace "+" "_" | trunc 63 | trimSuffix "-" }}
|
||||
{{- else }}
|
||||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Allow the release namespace to be overridden for multi-namespace deployments in combined charts
|
||||
*/}}
|
||||
{{- define "alloy.namespace" -}}
|
||||
{{- if .Values.namespaceOverride }}
|
||||
{{- .Values.namespaceOverride }}
|
||||
{{- else }}
|
||||
{{- .Release.Namespace }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Common labels
|
||||
*/}}
|
||||
{{- define "alloy.labels" -}}
|
||||
helm.sh/chart: {{ include "alloy.chart" . }}
|
||||
{{ include "alloy.selectorLabels" . }}
|
||||
{{- if index .Values "$chart_tests" }}
|
||||
app.kubernetes.io/version: "vX.Y.Z"
|
||||
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||
{{- else -}}
|
||||
{{/* substr trims delimeter prefix char from alloy.imageId output
|
||||
e.g. ':' for tags and '@' for digests.
|
||||
For digests, we crop the string to a 7-char (short) sha. */}}
|
||||
app.kubernetes.io/version: {{ (include "alloy.imageId" .) | trunc 15 | trimPrefix "@sha256" | trimPrefix ":" | quote }}
|
||||
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||
app.kubernetes.io/part-of: alloy
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Selector labels
|
||||
*/}}
|
||||
{{- define "alloy.selectorLabels" -}}
|
||||
app.kubernetes.io/name: {{ include "alloy.name" . }}
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create the name of the service account to use
|
||||
*/}}
|
||||
{{- define "alloy.serviceAccountName" -}}
|
||||
{{- if .Values.serviceAccount.create }}
|
||||
{{- default (include "alloy.fullname" .) .Values.serviceAccount.name }}
|
||||
{{- else }}
|
||||
{{- default "default" .Values.serviceAccount.name }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Calculate name of image ID to use for "alloy.
|
||||
*/}}
|
||||
{{- define "alloy.imageId" -}}
|
||||
{{- if .Values.image.digest }}
|
||||
{{- $digest := .Values.image.digest }}
|
||||
{{- if not (hasPrefix "sha256:" $digest) }}
|
||||
{{- $digest = printf "sha256:%s" $digest }}
|
||||
{{- end }}
|
||||
{{- printf "@%s" $digest }}
|
||||
{{- else if .Values.image.tag }}
|
||||
{{- printf ":%s" .Values.image.tag }}
|
||||
{{- else }}
|
||||
{{- printf ":%s" .Chart.AppVersion }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Calculate name of image ID to use for "config-reloader".
|
||||
*/}}
|
||||
{{- define "config-reloader.imageId" -}}
|
||||
{{- if .Values.configReloader.image.digest }}
|
||||
{{- $digest := .Values.configReloader.image.digest }}
|
||||
{{- if not (hasPrefix "sha256:" $digest) }}
|
||||
{{- $digest = printf "sha256:%s" $digest }}
|
||||
{{- end }}
|
||||
{{- printf "@%s" $digest }}
|
||||
{{- else if .Values.configReloader.image.tag }}
|
||||
{{- printf ":%s" .Values.configReloader.image.tag }}
|
||||
{{- else }}
|
||||
{{- printf ":%s" "v0.8.0" }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Return the appropriate apiVersion for ingress.
|
||||
*/}}
|
||||
{{- define "alloy.ingress.apiVersion" -}}
|
||||
{{- if and ($.Capabilities.APIVersions.Has "networking.k8s.io/v1") (semverCompare ">= 1.19-0" .Capabilities.KubeVersion.Version) }}
|
||||
{{- print "networking.k8s.io/v1" }}
|
||||
{{- else if $.Capabilities.APIVersions.Has "networking.k8s.io/v1beta1" }}
|
||||
{{- print "networking.k8s.io/v1beta1" }}
|
||||
{{- else }}
|
||||
{{- print "extensions/v1beta1" }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Return if ingress is stable.
|
||||
*/}}
|
||||
{{- define "alloy.ingress.isStable" -}}
|
||||
{{- eq (include "alloy.ingress.apiVersion" .) "networking.k8s.io/v1" }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Return if ingress supports ingressClassName.
|
||||
*/}}
|
||||
{{- define "alloy.ingress.supportsIngressClassName" -}}
|
||||
{{- or (eq (include "alloy.ingress.isStable" .) "true") (and (eq (include "alloy.ingress.apiVersion" .) "networking.k8s.io/v1beta1") (semverCompare ">= 1.18-0" .Capabilities.KubeVersion.Version)) }}
|
||||
{{- end }}
|
||||
{{/*
|
||||
Return if ingress supports pathType.
|
||||
*/}}
|
||||
{{- define "alloy.ingress.supportsPathType" -}}
|
||||
{{- or (eq (include "alloy.ingress.isStable" .) "true") (and (eq (include "alloy.ingress.apiVersion" .) "networking.k8s.io/v1beta1") (semverCompare ">= 1.18-0" .Capabilities.KubeVersion.Version)) }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Return the appropriate apiVersion for PodDisruptionBudget.
|
||||
*/}}
|
||||
{{- define "alloy.controller.pdb.apiVersion" -}}
|
||||
{{- if and (.Capabilities.APIVersions.Has "policy/v1") (semverCompare ">=1.21-0" .Capabilities.KubeVersion.Version) -}}
|
||||
{{- print "policy/v1" -}}
|
||||
{{- else -}}
|
||||
{{- print "policy/v1beta1" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,38 @@
|
||||
{{- $values := (mustMergeOverwrite .Values.alloy (or .Values.agent dict)) -}}
|
||||
{{- if $values.clustering.enabled -}}
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ include "alloy.fullname" . }}-cluster
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: networking
|
||||
spec:
|
||||
type: ClusterIP
|
||||
clusterIP: 'None'
|
||||
publishNotReadyAddresses: true
|
||||
selector:
|
||||
{{- include "alloy.selectorLabels" . | nindent 4 }}
|
||||
ports:
|
||||
# Do not include the -metrics suffix in the port name, otherwise metrics
|
||||
# can be double-collected with the non-headless Service if it's also
|
||||
# enabled.
|
||||
#
|
||||
# This service should only be used for clustering, and not metric
|
||||
# collection.
|
||||
- name: {{ $values.clustering.portName }}
|
||||
port: {{ $values.listenPort }}
|
||||
targetPort: {{ $values.listenPort }}
|
||||
protocol: "TCP"
|
||||
{{- range $portMap := $values.extraPorts }}
|
||||
- name: {{ $portMap.name }}
|
||||
port: {{ $portMap.port }}
|
||||
targetPort: {{ $portMap.targetPort }}
|
||||
protocol: {{ coalesce $portMap.protocol "TCP" }}
|
||||
{{- if not (empty $portMap.appProtocol) }}
|
||||
# Useful for OpenShift clusters that want to expose Alloy ports externally
|
||||
appProtocol: {{ $portMap.appProtocol }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,17 @@
|
||||
{{- $values := (mustMergeOverwrite .Values.alloy (or .Values.agent dict)) -}}
|
||||
{{- if $values.configMap.create }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: {{ include "alloy.config-map.name" . }}
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: config
|
||||
data:
|
||||
{{- if $values.configMap.content }}
|
||||
config.alloy: |- {{- (tpl $values.configMap.content .) | nindent 4 }}
|
||||
{{- else }}
|
||||
config.alloy: |- {{- .Files.Get "config/example.alloy" | trim | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,92 @@
|
||||
{{- define "alloy.container" -}}
|
||||
{{- $values := (mustMergeOverwrite .Values.alloy (or .Values.agent dict)) -}}
|
||||
- name: alloy
|
||||
image: {{ .Values.global.image.registry | default .Values.image.registry }}/{{ .Values.image.repository }}{{ include "alloy.imageId" . }}
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
args:
|
||||
- run
|
||||
- /etc/alloy/{{ include "alloy.config-map.key" . }}
|
||||
- --storage.path={{ $values.storagePath }}
|
||||
- --server.http.listen-addr={{ $values.listenAddr }}:{{ $values.listenPort }}
|
||||
- --server.http.ui-path-prefix={{ $values.uiPathPrefix }}
|
||||
{{- if not $values.enableReporting }}
|
||||
- --disable-reporting
|
||||
{{- end}}
|
||||
{{- if $values.clustering.enabled }}
|
||||
- --cluster.enabled=true
|
||||
- --cluster.join-addresses={{ include "alloy.fullname" . }}-cluster
|
||||
{{- if $values.clustering.name }}
|
||||
- --cluster.name={{ $values.clustering.name }}
|
||||
{{- end}}
|
||||
{{- end}}
|
||||
{{- if $values.stabilityLevel }}
|
||||
- --stability.level={{ $values.stabilityLevel }}
|
||||
{{- end }}
|
||||
{{- range $values.extraArgs }}
|
||||
- {{ . }}
|
||||
{{- end}}
|
||||
env:
|
||||
- name: ALLOY_DEPLOY_MODE
|
||||
value: "helm"
|
||||
- name: HOSTNAME
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: spec.nodeName
|
||||
{{- range $values.extraEnv }}
|
||||
- {{- toYaml . | nindent 6 }}
|
||||
{{- end }}
|
||||
{{- if $values.envFrom }}
|
||||
envFrom:
|
||||
{{- toYaml $values.envFrom | nindent 4 }}
|
||||
{{- end }}
|
||||
ports:
|
||||
- containerPort: {{ $values.listenPort }}
|
||||
name: http-metrics
|
||||
{{- range $portMap := $values.extraPorts }}
|
||||
- containerPort: {{ $portMap.targetPort }}
|
||||
{{- if $portMap.hostPort }}
|
||||
hostPort: {{ $portMap.hostPort }}
|
||||
{{- end}}
|
||||
name: {{ $portMap.name }}
|
||||
protocol: {{ coalesce $portMap.protocol "TCP" }}
|
||||
{{- end }}
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /-/ready
|
||||
port: {{ $values.listenPort }}
|
||||
scheme: {{ $values.listenScheme }}
|
||||
initialDelaySeconds: 10
|
||||
timeoutSeconds: 1
|
||||
{{- with $values.livenessProbe }}
|
||||
livenessProbe:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with $values.resources }}
|
||||
resources:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with $values.lifecycle }}
|
||||
lifecycle:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with $values.securityContext }}
|
||||
securityContext:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
volumeMounts:
|
||||
- name: config
|
||||
mountPath: /etc/alloy
|
||||
{{- if $values.mounts.varlog }}
|
||||
- name: varlog
|
||||
mountPath: /var/log
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
{{- if $values.mounts.dockercontainers }}
|
||||
- name: dockercontainers
|
||||
mountPath: /var/lib/docker/containers
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
{{- range $values.mounts.extra }}
|
||||
- {{- toYaml . | nindent 6 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,26 @@
|
||||
{{- define "alloy.watch-container" -}}
|
||||
{{- $values := (mustMergeOverwrite .Values.alloy (or .Values.agent dict)) -}}
|
||||
{{- if .Values.configReloader.enabled -}}
|
||||
- name: config-reloader
|
||||
image: {{ .Values.global.image.registry | default .Values.configReloader.image.registry }}/{{ .Values.configReloader.image.repository }}{{ include "config-reloader.imageId" . }}
|
||||
{{- if .Values.configReloader.customArgs }}
|
||||
args:
|
||||
{{- toYaml .Values.configReloader.customArgs | nindent 4 }}
|
||||
{{- else }}
|
||||
args:
|
||||
- --watched-dir=/etc/alloy
|
||||
- --reload-url=http://localhost:{{ $values.listenPort }}/-/reload
|
||||
{{- end }}
|
||||
volumeMounts:
|
||||
- name: config
|
||||
mountPath: /etc/alloy
|
||||
{{- with .Values.configReloader.resources }}
|
||||
resources:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.configReloader.securityContext }}
|
||||
securityContext:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,93 @@
|
||||
{{- define "alloy.pod-template" -}}
|
||||
{{- $values := (mustMergeOverwrite .Values.alloy (or .Values.agent dict)) -}}
|
||||
metadata:
|
||||
annotations:
|
||||
kubectl.kubernetes.io/default-container: alloy
|
||||
{{- if and $values.configMap.create $values.configMap.content }}
|
||||
checksum/config: {{ (tpl $values.configMap.content .) | sha256sum | trunc 63 }}
|
||||
{{- end }}
|
||||
{{- with .Values.controller.podAnnotations }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "alloy.selectorLabels" . | nindent 4 }}
|
||||
{{- with .Values.controller.podLabels }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- with .Values.global.podSecurityContext }}
|
||||
securityContext:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
serviceAccountName: {{ include "alloy.serviceAccountName" . }}
|
||||
{{- if or .Values.global.image.pullSecrets .Values.image.pullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{- if .Values.global.image.pullSecrets }}
|
||||
{{- toYaml .Values.global.image.pullSecrets | nindent 4 }}
|
||||
{{- else }}
|
||||
{{- toYaml .Values.image.pullSecrets | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.controller.initContainers }}
|
||||
initContainers:
|
||||
{{- with .Values.controller.initContainers }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
containers:
|
||||
{{- include "alloy.container" . | nindent 4 }}
|
||||
{{- include "alloy.watch-container" . | nindent 4 }}
|
||||
{{- with .Values.controller.extraContainers }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end}}
|
||||
{{- if .Values.controller.priorityClassName }}
|
||||
priorityClassName: {{ .Values.controller.priorityClassName }}
|
||||
{{- end }}
|
||||
{{- if .Values.controller.hostNetwork }}
|
||||
hostNetwork: {{ .Values.controller.hostNetwork }}
|
||||
{{- end }}
|
||||
{{- if .Values.controller.hostPID }}
|
||||
hostPID: {{ .Values.controller.hostPID }}
|
||||
{{- end }}
|
||||
dnsPolicy: {{ .Values.controller.dnsPolicy }}
|
||||
{{- with .Values.controller.affinity }}
|
||||
affinity:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- if .Values.controller.terminationGracePeriodSeconds }}
|
||||
terminationGracePeriodSeconds: {{ .Values.controller.terminationGracePeriodSeconds | int }}
|
||||
{{- end }}
|
||||
{{- with .Values.controller.nodeSelector }}
|
||||
nodeSelector:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.controller.tolerations }}
|
||||
tolerations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.controller.topologySpreadConstraints }}
|
||||
topologySpreadConstraints:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
volumes:
|
||||
- name: config
|
||||
configMap:
|
||||
name: {{ include "alloy.config-map.name" . }}
|
||||
{{- if $values.mounts.varlog }}
|
||||
- name: varlog
|
||||
hostPath:
|
||||
path: /var/log
|
||||
{{- end }}
|
||||
{{- if $values.mounts.dockercontainers }}
|
||||
- name: dockercontainers
|
||||
hostPath:
|
||||
path: /var/lib/docker/containers
|
||||
{{- end }}
|
||||
{{- if .Values.controller.volumes.extra }}
|
||||
{{- toYaml .Values.controller.volumes.extra | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- if $values.hostAliases }}
|
||||
hostAliases:
|
||||
{{- toYaml $values.hostAliases | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,26 @@
|
||||
{{- if eq .Values.controller.type "daemonset" }}
|
||||
apiVersion: apps/v1
|
||||
kind: DaemonSet
|
||||
metadata:
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
{{- with .Values.controller.extraAnnotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if ge (int .Capabilities.KubeVersion.Minor) 22 }}
|
||||
minReadySeconds: 10
|
||||
{{- end }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "alloy.selectorLabels" . | nindent 6 }}
|
||||
template:
|
||||
{{- include "alloy.pod-template" . | nindent 4 }}
|
||||
{{- with .Values.controller.updateStrategy }}
|
||||
updateStrategy:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,29 @@
|
||||
{{- if eq .Values.controller.type "deployment" }}
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
{{- with .Values.controller.extraAnnotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if not .Values.controller.autoscaling.enabled }}
|
||||
replicas: {{ .Values.controller.replicas }}
|
||||
{{- end }}
|
||||
{{- if ge (int .Capabilities.KubeVersion.Minor) 22 }}
|
||||
minReadySeconds: 10
|
||||
{{- end }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "alloy.selectorLabels" . | nindent 6 }}
|
||||
template:
|
||||
{{- include "alloy.pod-template" . | nindent 4 }}
|
||||
{{- with .Values.controller.updateStrategy }}
|
||||
strategy:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,51 @@
|
||||
{{- if eq .Values.controller.type "statefulset" }}
|
||||
{{- if .Values.enableStatefulSetAutoDeletePVC }}
|
||||
{{- fail "Value 'enableStatefulSetAutoDeletePVC' should be nested inside 'controller' options." }}
|
||||
{{- end }}
|
||||
apiVersion: apps/v1
|
||||
kind: StatefulSet
|
||||
metadata:
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
{{- with .Values.controller.extraAnnotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if not .Values.controller.autoscaling.enabled }}
|
||||
replicas: {{ .Values.controller.replicas }}
|
||||
{{- end }}
|
||||
{{- if .Values.controller.parallelRollout }}
|
||||
podManagementPolicy: Parallel
|
||||
{{- end }}
|
||||
{{- if ge (int .Capabilities.KubeVersion.Minor) 22 }}
|
||||
minReadySeconds: 10
|
||||
{{- end }}
|
||||
serviceName: {{ include "alloy.fullname" . }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "alloy.selectorLabels" . | nindent 6 }}
|
||||
template:
|
||||
{{- include "alloy.pod-template" . | nindent 4 }}
|
||||
{{- with .Values.controller.updateStrategy }}
|
||||
updateStrategy:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.controller.volumeClaimTemplates }}
|
||||
volumeClaimTemplates:
|
||||
{{- range . }}
|
||||
- {{ toYaml . | nindent 6 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if and (semverCompare ">= 1.23-0" .Capabilities.KubeVersion.Version) (.Values.controller.enableStatefulSetAutoDeletePVC) }}
|
||||
{{- /*
|
||||
Data on the read nodes is easy to replace, so we want to always delete PVCs to make
|
||||
operation easier, and will rely on re-fetching data when needed.
|
||||
*/}}
|
||||
persistentVolumeClaimRetentionPolicy:
|
||||
whenDeleted: Delete
|
||||
whenScaled: Delete
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,4 @@
|
||||
{{ range .Values.extraObjects }}
|
||||
---
|
||||
{{ tpl (toYaml .) $ }}
|
||||
{{ end }}
|
||||
@@ -0,0 +1,83 @@
|
||||
{{- $values := (mustMergeOverwrite .Values.alloy (or .Values.agent dict)) -}}
|
||||
{{- if and (or (eq .Values.controller.type "deployment") (eq .Values.controller.type "statefulset" )) (or .Values.controller.autoscaling.horizontal.enabled .Values.controller.autoscaling.enabled) }}
|
||||
{{ $autoscaling := .Values.controller.autoscaling }}
|
||||
{{- if .Values.controller.autoscaling.horizontal.enabled }}
|
||||
{{- $autoscaling = .Values.controller.autoscaling.horizontal }}
|
||||
{{- end }}
|
||||
{{- if (not (empty $autoscaling.targetMemoryUtilizationPercentage)) }}
|
||||
{{- $_ := $values.resources.requests | required ".Values.alloy.resources.requests is required when using autoscaling." -}}
|
||||
{{- $_ := $values.resources.requests.memory | required ".Values.alloy.resources.requests.memory is required when using autoscaling based on memory utilization." -}}
|
||||
{{- $_ := .Values.configReloader.resources.requests | required ".Values.configReloader.resources.requests is required when using autoscaling." -}}
|
||||
{{- $_ := .Values.configReloader.resources.requests.memory | required ".Values.configReloader.resources.requests.memory is required when using autoscaling based on memory utilization." -}}
|
||||
{{- end}}
|
||||
{{- if (not (empty $autoscaling.targetCPUUtilizationPercentage)) }}
|
||||
{{- $_ := $values.resources.requests | required ".Values.alloy.resources.requests is required when using autoscaling." -}}
|
||||
{{- $_ := $values.resources.requests.cpu | required ".Values.alloy.resources.requests.cpu is required when using autoscaling based on cpu utilization." -}}
|
||||
{{- $_ := .Values.configReloader.resources.requests | required ".Values.configReloader.resources.requests is required when using autoscaling." -}}
|
||||
{{- $_ := .Values.configReloader.resources.requests.cpu | required ".Values.configReloader.resources.requests.cpu is required when using autoscaling based on cpu utilization." -}}
|
||||
{{- end}}
|
||||
apiVersion: autoscaling/v2
|
||||
kind: HorizontalPodAutoscaler
|
||||
metadata:
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: availability
|
||||
spec:
|
||||
scaleTargetRef:
|
||||
apiVersion: apps/v1
|
||||
kind: {{ .Values.controller.type }}
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
{{- with $autoscaling }}
|
||||
minReplicas: {{ .minReplicas }}
|
||||
maxReplicas: {{ .maxReplicas }}
|
||||
behavior:
|
||||
{{- with .scaleDown }}
|
||||
scaleDown:
|
||||
{{- if .policies }}
|
||||
policies:
|
||||
{{- range .policies }}
|
||||
- type: {{ .type }}
|
||||
value: {{ .value }}
|
||||
periodSeconds: {{ .periodSeconds }}
|
||||
{{- end }}
|
||||
selectPolicy: {{ .selectPolicy }}
|
||||
{{- end }}
|
||||
stabilizationWindowSeconds: {{ .stabilizationWindowSeconds }}
|
||||
{{- end }}
|
||||
{{- with .scaleUp }}
|
||||
scaleUp:
|
||||
{{- if .policies }}
|
||||
policies:
|
||||
{{- range .policies }}
|
||||
- type: {{ .type }}
|
||||
value: {{ .value }}
|
||||
periodSeconds: {{ .periodSeconds }}
|
||||
{{- end }}
|
||||
selectPolicy: {{ .selectPolicy }}
|
||||
{{- end }}
|
||||
stabilizationWindowSeconds: {{ .stabilizationWindowSeconds }}
|
||||
{{- end }}
|
||||
metrics:
|
||||
# Changing the order of the metrics will cause ArgoCD to go into a sync loop
|
||||
# memory needs to be first.
|
||||
# More info in: https://github.com/argoproj/argo-cd/issues/1079
|
||||
{{- with .targetMemoryUtilizationPercentage }}
|
||||
- type: Resource
|
||||
resource:
|
||||
name: memory
|
||||
target:
|
||||
type: Utilization
|
||||
averageUtilization: {{ . }}
|
||||
{{- end }}
|
||||
{{- with .targetCPUUtilizationPercentage }}
|
||||
- type: Resource
|
||||
resource:
|
||||
name: cpu
|
||||
target:
|
||||
type: Utilization
|
||||
averageUtilization: {{ . }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,79 @@
|
||||
{{- if .Values.ingress.enabled -}}
|
||||
{{- $ingressApiIsStable := eq (include "alloy.ingress.isStable" .) "true" -}}
|
||||
{{- $ingressSupportsIngressClassName := eq (include "alloy.ingress.supportsIngressClassName" .) "true" -}}
|
||||
{{- $ingressSupportsPathType := eq (include "alloy.ingress.supportsPathType" .) "true" -}}
|
||||
{{- $fullName := include "alloy.fullname" . -}}
|
||||
{{- $servicePort := .Values.ingress.faroPort -}}
|
||||
{{- $ingressPath := .Values.ingress.path -}}
|
||||
{{- $ingressPathType := .Values.ingress.pathType -}}
|
||||
{{- $extraPaths := .Values.ingress.extraPaths -}}
|
||||
apiVersion: {{ include "alloy.ingress.apiVersion" . }}
|
||||
kind: Ingress
|
||||
metadata:
|
||||
name: {{ $fullName }}
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: networking
|
||||
{{- with .Values.ingress.labels }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.ingress.annotations }}
|
||||
annotations:
|
||||
{{- range $key, $value := . }}
|
||||
{{ $key }}: {{ tpl $value $ | quote }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if and $ingressSupportsIngressClassName .Values.ingress.ingressClassName }}
|
||||
ingressClassName: {{ .Values.ingress.ingressClassName }}
|
||||
{{- end -}}
|
||||
{{- with .Values.ingress.tls }}
|
||||
tls:
|
||||
{{- tpl (toYaml .) $ | nindent 4 }}
|
||||
{{- end }}
|
||||
rules:
|
||||
{{- if .Values.ingress.hosts }}
|
||||
{{- range .Values.ingress.hosts }}
|
||||
- host: {{ tpl . $ }}
|
||||
http:
|
||||
paths:
|
||||
{{- with $extraPaths }}
|
||||
{{- toYaml . | nindent 10 }}
|
||||
{{- end }}
|
||||
- path: {{ $ingressPath }}
|
||||
{{- if $ingressSupportsPathType }}
|
||||
pathType: {{ $ingressPathType }}
|
||||
{{- end }}
|
||||
backend:
|
||||
{{- if $ingressApiIsStable }}
|
||||
service:
|
||||
name: {{ $fullName }}
|
||||
port:
|
||||
number: {{ $servicePort }}
|
||||
{{- else }}
|
||||
serviceName: {{ $fullName }}
|
||||
servicePort: {{ $servicePort }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- else }}
|
||||
- http:
|
||||
paths:
|
||||
- backend:
|
||||
{{- if $ingressApiIsStable }}
|
||||
service:
|
||||
name: {{ $fullName }}
|
||||
port:
|
||||
number: {{ $servicePort }}
|
||||
{{- else }}
|
||||
serviceName: {{ $fullName }}
|
||||
servicePort: {{ $servicePort }}
|
||||
{{- end }}
|
||||
{{- with $ingressPath }}
|
||||
path: {{ . }}
|
||||
{{- end }}
|
||||
{{- if $ingressSupportsPathType }}
|
||||
pathType: {{ $ingressPathType }}
|
||||
{{- end }}
|
||||
{{- end -}}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,31 @@
|
||||
{{- if .Values.controller.podDisruptionBudget.enabled }}
|
||||
{{- if eq .Values.controller.type "daemonset" }}
|
||||
{{- fail "PDBs (Pod Disruption Budgets) are not intended for DaemonSets. Please use a different controller type." }}
|
||||
{{- end }}
|
||||
|
||||
{{- if and .Values.controller.podDisruptionBudget.minAvailable .Values.controller.podDisruptionBudget.maxUnavailable }}
|
||||
{{- fail "Only one of minAvailable or maxUnavailable should be defined for PodDisruptionBudget" }}
|
||||
{{- end }}
|
||||
|
||||
{{- if not (or .Values.controller.podDisruptionBudget.minAvailable .Values.controller.podDisruptionBudget.maxUnavailable) }}
|
||||
{{- fail "Either minAvailable or maxUnavailable must be defined for PodDisruptionBudget" }}
|
||||
{{- end }}
|
||||
|
||||
apiVersion: {{ include "alloy.controller.pdb.apiVersion" . }}
|
||||
kind: PodDisruptionBudget
|
||||
metadata:
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "alloy.selectorLabels" . | nindent 6 }}
|
||||
{{- if .Values.controller.podDisruptionBudget.minAvailable }}
|
||||
minAvailable: {{ .Values.controller.podDisruptionBudget.minAvailable }}
|
||||
{{- end }}
|
||||
{{- if .Values.controller.podDisruptionBudget.maxUnavailable }}
|
||||
maxUnavailable: {{ .Values.controller.podDisruptionBudget.maxUnavailable }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,112 @@
|
||||
{{- if .Values.rbac.create }}
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
kind: ClusterRole
|
||||
metadata:
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: rbac
|
||||
rules:
|
||||
# Rules which allow discovery.kubernetes to function.
|
||||
- apiGroups:
|
||||
- ""
|
||||
- "discovery.k8s.io"
|
||||
- "networking.k8s.io"
|
||||
resources:
|
||||
- endpoints
|
||||
- endpointslices
|
||||
- ingresses
|
||||
- nodes
|
||||
- nodes/proxy
|
||||
- nodes/metrics
|
||||
- pods
|
||||
- services
|
||||
verbs:
|
||||
- get
|
||||
- list
|
||||
- watch
|
||||
# Rules which allow loki.source.kubernetes and loki.source.podlogs to work.
|
||||
- apiGroups:
|
||||
- ""
|
||||
resources:
|
||||
- pods
|
||||
- pods/log
|
||||
- namespaces
|
||||
verbs:
|
||||
- get
|
||||
- list
|
||||
- watch
|
||||
- apiGroups:
|
||||
- "monitoring.grafana.com"
|
||||
resources:
|
||||
- podlogs
|
||||
verbs:
|
||||
- get
|
||||
- list
|
||||
- watch
|
||||
# Rules which allow mimir.rules.kubernetes to work.
|
||||
- apiGroups: ["monitoring.coreos.com"]
|
||||
resources:
|
||||
- prometheusrules
|
||||
verbs:
|
||||
- get
|
||||
- list
|
||||
- watch
|
||||
- nonResourceURLs:
|
||||
- /metrics
|
||||
verbs:
|
||||
- get
|
||||
# Rules for prometheus.kubernetes.*
|
||||
- apiGroups: ["monitoring.coreos.com"]
|
||||
resources:
|
||||
- podmonitors
|
||||
- servicemonitors
|
||||
- probes
|
||||
- scrapeconfigs
|
||||
verbs:
|
||||
- get
|
||||
- list
|
||||
- watch
|
||||
# Rules which allow eventhandler to work.
|
||||
- apiGroups:
|
||||
- ""
|
||||
resources:
|
||||
- events
|
||||
verbs:
|
||||
- get
|
||||
- list
|
||||
- watch
|
||||
# needed for remote.kubernetes.*
|
||||
- apiGroups: [""]
|
||||
resources:
|
||||
- "configmaps"
|
||||
- "secrets"
|
||||
verbs:
|
||||
- get
|
||||
- list
|
||||
- watch
|
||||
# needed for otelcol.processor.k8sattributes
|
||||
- apiGroups: ["apps"]
|
||||
resources: ["replicasets"]
|
||||
verbs: ["get", "list", "watch"]
|
||||
- apiGroups: ["extensions"]
|
||||
resources: ["replicasets"]
|
||||
verbs: ["get", "list", "watch"]
|
||||
|
||||
---
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
kind: ClusterRoleBinding
|
||||
metadata:
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: rbac
|
||||
roleRef:
|
||||
apiGroup: rbac.authorization.k8s.io
|
||||
kind: ClusterRole
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
subjects:
|
||||
- kind: ServiceAccount
|
||||
name: {{ include "alloy.serviceAccountName" . }}
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,43 @@
|
||||
{{- $values := (mustMergeOverwrite .Values.alloy (or .Values.agent dict)) -}}
|
||||
{{- if .Values.service.enabled -}}
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: networking
|
||||
{{- with .Values.service.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
type: {{ .Values.service.type }}
|
||||
{{- if .Values.service.clusterIP }}
|
||||
clusterIP: {{ .Values.service.clusterIP }}
|
||||
{{- end }}
|
||||
selector:
|
||||
{{- include "alloy.selectorLabels" . | nindent 4 }}
|
||||
{{- if semverCompare ">=1.26-0" .Capabilities.KubeVersion.Version }}
|
||||
internalTrafficPolicy: {{.Values.service.internalTrafficPolicy}}
|
||||
{{- end }}
|
||||
ports:
|
||||
- name: http-metrics
|
||||
{{- if eq .Values.service.type "NodePort" }}
|
||||
nodePort: {{ .Values.service.nodePort }}
|
||||
{{- end }}
|
||||
port: {{ $values.listenPort }}
|
||||
targetPort: {{ $values.listenPort }}
|
||||
protocol: "TCP"
|
||||
{{- range $portMap := $values.extraPorts }}
|
||||
- name: {{ $portMap.name }}
|
||||
port: {{ $portMap.port }}
|
||||
targetPort: {{ $portMap.targetPort }}
|
||||
protocol: {{ coalesce $portMap.protocol "TCP" }}
|
||||
{{- if not (empty $portMap.appProtocol) }}
|
||||
# Useful for OpenShift clusters that want to expose Alloy ports externally
|
||||
appProtocol: {{ $portMap.appProtocol }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,18 @@
|
||||
{{- if .Values.serviceAccount.create -}}
|
||||
apiVersion: v1
|
||||
kind: ServiceAccount
|
||||
automountServiceAccountToken: {{ .Values.serviceAccount.automountServiceAccountToken }}
|
||||
metadata:
|
||||
name: {{ include "alloy.serviceAccountName" . }}
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: rbac
|
||||
{{- with .Values.serviceAccount.additionalLabels }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.serviceAccount.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,37 @@
|
||||
{{- $values := (mustMergeOverwrite .Values.alloy (or .Values.agent dict)) -}}
|
||||
{{- if and .Values.service.enabled .Values.serviceMonitor.enabled -}}
|
||||
apiVersion: monitoring.coreos.com/v1
|
||||
kind: ServiceMonitor
|
||||
metadata:
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
namespace: {{ include "alloy.namespace" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: metrics
|
||||
{{- with .Values.serviceMonitor.additionalLabels }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
endpoints:
|
||||
- port: http-metrics
|
||||
scheme: {{ $values.listenScheme | lower }}
|
||||
honorLabels: true
|
||||
{{- if .Values.serviceMonitor.interval }}
|
||||
interval: {{ .Values.serviceMonitor.interval }}
|
||||
{{- end }}
|
||||
{{- if .Values.serviceMonitor.metricRelabelings }}
|
||||
metricRelabelings:
|
||||
{{ tpl (toYaml .Values.serviceMonitor.metricRelabelings | nindent 6) . }}
|
||||
{{- end }}
|
||||
{{- if .Values.serviceMonitor.relabelings }}
|
||||
relabelings:
|
||||
{{ tpl (toYaml .Values.serviceMonitor.relabelings | nindent 6) . }}
|
||||
{{- end }}
|
||||
{{- with .Values.serviceMonitor.tlsConfig }}
|
||||
tlsConfig:
|
||||
{{- toYaml . | nindent 6 }}
|
||||
{{- end }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "alloy.selectorLabels" . | nindent 6 }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,41 @@
|
||||
{{- if .Capabilities.APIVersions.Has "autoscaling.k8s.io/v1" -}}
|
||||
{{- if .Values.controller.autoscaling.vertical.enabled -}}
|
||||
apiVersion: autoscaling.k8s.io/v1
|
||||
kind: VerticalPodAutoscaler
|
||||
metadata:
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
labels:
|
||||
{{- include "alloy.labels" . | nindent 4 }}
|
||||
app.kubernetes.io/component: availability
|
||||
spec:
|
||||
{{- with .Values.controller.autoscaling.vertical }}
|
||||
{{- with .recommenders }}
|
||||
recommenders:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .resourcePolicy }}
|
||||
resourcePolicy:
|
||||
{{- with .containerPolicies }}
|
||||
containerPolicies:
|
||||
{{- range . }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- with .updatePolicy }}
|
||||
updatePolicy:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
targetRef:
|
||||
apiVersion: apps/v1
|
||||
{{- if eq .Values.controller.type "deployment" }}
|
||||
kind: Deployment
|
||||
{{- else if eq .Values.controller.type "statefulset" }}
|
||||
kind: StatefulSet
|
||||
{{- else }}
|
||||
kind: DaemonSet
|
||||
{{- end }}
|
||||
name: {{ include "alloy.fullname" . }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,463 @@
|
||||
# -- Overrides the chart's name. Used to change the infix in the resource names.
|
||||
nameOverride: null
|
||||
|
||||
# -- Overrides the chart's namespace.
|
||||
namespaceOverride: null
|
||||
|
||||
# -- Overrides the chart's computed fullname. Used to change the full prefix of
|
||||
# resource names.
|
||||
fullnameOverride: null
|
||||
|
||||
## Global properties for image pulling override the values defined under `image.registry` and `configReloader.image.registry`.
|
||||
## If you want to override only one image registry, use the specific fields but if you want to override them all, use `global.image.registry`
|
||||
global:
|
||||
image:
|
||||
# -- Global image registry to use if it needs to be overridden for some specific use cases (e.g local registries, custom images, ...)
|
||||
registry: ""
|
||||
|
||||
# -- Optional set of global image pull secrets.
|
||||
pullSecrets: []
|
||||
|
||||
# -- Security context to apply to the Grafana Alloy pod.
|
||||
podSecurityContext: {}
|
||||
|
||||
crds:
|
||||
# -- Whether to install CRDs for monitoring.
|
||||
create: true
|
||||
|
||||
## Various Alloy settings. For backwards compatibility with the grafana-agent
|
||||
## chart, this field may also be called "agent". Naming this field "agent" is
|
||||
## deprecated and will be removed in a future release.
|
||||
alloy:
|
||||
configMap:
|
||||
# -- Create a new ConfigMap for the config file.
|
||||
create: true
|
||||
# -- Content to assign to the new ConfigMap. This is passed into `tpl` allowing for templating from values.
|
||||
content: ''
|
||||
|
||||
# -- Name of existing ConfigMap to use. Used when create is false.
|
||||
name: null
|
||||
# -- Key in ConfigMap to get config from.
|
||||
key: null
|
||||
|
||||
clustering:
|
||||
# -- Deploy Alloy in a cluster to allow for load distribution.
|
||||
enabled: false
|
||||
|
||||
# -- Name for the Alloy cluster. Used for differentiating between clusters.
|
||||
name: ""
|
||||
|
||||
# -- Name for the port used for clustering, useful if running inside an Istio Mesh
|
||||
portName: http
|
||||
|
||||
# -- Minimum stability level of components and behavior to enable. Must be
|
||||
# one of "experimental", "public-preview", or "generally-available".
|
||||
stabilityLevel: "generally-available"
|
||||
|
||||
# -- Path to where Grafana Alloy stores data (for example, the Write-Ahead Log).
|
||||
# By default, data is lost between reboots.
|
||||
storagePath: /tmp/alloy
|
||||
|
||||
# -- Address to listen for traffic on. 0.0.0.0 exposes the UI to other
|
||||
# containers.
|
||||
listenAddr: 0.0.0.0
|
||||
|
||||
# -- Port to listen for traffic on.
|
||||
listenPort: 12345
|
||||
|
||||
# -- Scheme is needed for readiness probes. If enabling tls in your configs, set to "HTTPS"
|
||||
listenScheme: HTTP
|
||||
|
||||
# -- Base path where the UI is exposed.
|
||||
uiPathPrefix: /
|
||||
|
||||
# -- Enables sending Grafana Labs anonymous usage stats to help improve Grafana
|
||||
# Alloy.
|
||||
enableReporting: true
|
||||
|
||||
# -- Extra environment variables to pass to the Alloy container.
|
||||
extraEnv: []
|
||||
|
||||
# -- Maps all the keys on a ConfigMap or Secret as environment variables. https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.24/#envfromsource-v1-core
|
||||
envFrom: []
|
||||
|
||||
# -- Extra args to pass to `alloy run`: https://grafana.com/docs/alloy/latest/reference/cli/run/
|
||||
extraArgs: []
|
||||
|
||||
# -- Extra ports to expose on the Alloy container.
|
||||
extraPorts: []
|
||||
# - name: "faro"
|
||||
# port: 12347
|
||||
# targetPort: 12347
|
||||
# protocol: "TCP"
|
||||
# appProtocol: "h2c"
|
||||
|
||||
# -- Host aliases to add to the Alloy container.
|
||||
hostAliases: []
|
||||
# - ip: "20.21.22.23"
|
||||
# hostnames:
|
||||
# - "company.grafana.net"
|
||||
|
||||
mounts:
|
||||
# -- Mount /var/log from the host into the container for log collection.
|
||||
varlog: false
|
||||
# -- Mount /var/lib/docker/containers from the host into the container for log
|
||||
# collection.
|
||||
dockercontainers: false
|
||||
|
||||
# -- Extra volume mounts to add into the Grafana Alloy container. Does not
|
||||
# affect the watch container.
|
||||
extra: []
|
||||
|
||||
# -- Security context to apply to the Grafana Alloy container.
|
||||
securityContext: {}
|
||||
|
||||
# -- Resource requests and limits to apply to the Grafana Alloy container.
|
||||
resources: {}
|
||||
|
||||
# -- Set lifecycle hooks for the Grafana Alloy container.
|
||||
lifecycle: {}
|
||||
# preStop:
|
||||
# exec:
|
||||
# command:
|
||||
# - /bin/sleep
|
||||
# - "10"
|
||||
|
||||
# -- Set livenessProbe for the Grafana Alloy container.
|
||||
livenessProbe: {}
|
||||
|
||||
image:
|
||||
# -- Grafana Alloy image registry (defaults to docker.io)
|
||||
registry: "docker.io"
|
||||
# -- Grafana Alloy image repository.
|
||||
repository: grafana/alloy
|
||||
# -- (string) Grafana Alloy image tag. When empty, the Chart's appVersion is
|
||||
# used.
|
||||
tag: null
|
||||
# -- Grafana Alloy image's SHA256 digest (either in format "sha256:XYZ" or "XYZ"). When set, will override `image.tag`.
|
||||
digest: null
|
||||
# -- Grafana Alloy image pull policy.
|
||||
pullPolicy: IfNotPresent
|
||||
# -- Optional set of image pull secrets.
|
||||
pullSecrets: []
|
||||
|
||||
rbac:
|
||||
# -- Whether to create RBAC resources for Alloy.
|
||||
create: true
|
||||
|
||||
serviceAccount:
|
||||
# -- Whether to create a service account for the Grafana Alloy deployment.
|
||||
create: true
|
||||
# -- Additional labels to add to the created service account.
|
||||
additionalLabels: {}
|
||||
# -- Annotations to add to the created service account.
|
||||
annotations: {}
|
||||
# -- The name of the existing service account to use when
|
||||
# serviceAccount.create is false.
|
||||
name: null
|
||||
# Whether the Alloy pod should automatically mount the service account token.
|
||||
automountServiceAccountToken: true
|
||||
|
||||
# Options for the extra controller used for config reloading.
|
||||
configReloader:
|
||||
# -- Enables automatically reloading when the Alloy config changes.
|
||||
enabled: true
|
||||
image:
|
||||
# -- Config reloader image registry (defaults to docker.io)
|
||||
registry: "quay.io"
|
||||
# -- Repository to get config reloader image from.
|
||||
repository: prometheus-operator/prometheus-config-reloader
|
||||
# -- Tag of image to use for config reloading.
|
||||
tag: v0.81.0
|
||||
# -- SHA256 digest of image to use for config reloading (either in format "sha256:XYZ" or "XYZ"). When set, will override `configReloader.image.tag`
|
||||
digest: ""
|
||||
# -- Override the args passed to the container.
|
||||
customArgs: []
|
||||
# -- Resource requests and limits to apply to the config reloader container.
|
||||
resources:
|
||||
requests:
|
||||
cpu: "10m"
|
||||
memory: "50Mi"
|
||||
# -- Security context to apply to the Grafana configReloader container.
|
||||
securityContext: {}
|
||||
|
||||
controller:
|
||||
# -- Type of controller to use for deploying Grafana Alloy in the cluster.
|
||||
# Must be one of 'daemonset', 'deployment', or 'statefulset'.
|
||||
type: 'daemonset'
|
||||
|
||||
# -- Number of pods to deploy. Ignored when controller.type is 'daemonset'.
|
||||
replicas: 1
|
||||
|
||||
# -- Annotations to add to controller.
|
||||
extraAnnotations: {}
|
||||
|
||||
# -- Whether to deploy pods in parallel. Only used when controller.type is
|
||||
# 'statefulset'.
|
||||
parallelRollout: true
|
||||
|
||||
# -- Configures Pods to use the host network. When set to true, the ports that will be used must be specified.
|
||||
hostNetwork: false
|
||||
|
||||
# -- Configures Pods to use the host PID namespace.
|
||||
hostPID: false
|
||||
|
||||
# -- Configures the DNS policy for the pod. https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy
|
||||
dnsPolicy: ClusterFirst
|
||||
|
||||
# -- Termination grace period in seconds for the Grafana Alloy pods.
|
||||
# The default value used by Kubernetes if unspecifed is 30 seconds.
|
||||
terminationGracePeriodSeconds: null
|
||||
|
||||
# -- Update strategy for updating deployed Pods.
|
||||
updateStrategy: {}
|
||||
|
||||
# -- nodeSelector to apply to Grafana Alloy pods.
|
||||
nodeSelector: {}
|
||||
|
||||
# -- Tolerations to apply to Grafana Alloy pods.
|
||||
tolerations: []
|
||||
|
||||
# -- Topology Spread Constraints to apply to Grafana Alloy pods.
|
||||
topologySpreadConstraints: []
|
||||
|
||||
# -- priorityClassName to apply to Grafana Alloy pods.
|
||||
priorityClassName: ''
|
||||
|
||||
# -- Extra pod annotations to add.
|
||||
podAnnotations: {}
|
||||
|
||||
# -- Extra pod labels to add.
|
||||
podLabels: {}
|
||||
|
||||
# -- PodDisruptionBudget configuration.
|
||||
podDisruptionBudget:
|
||||
# -- Whether to create a PodDisruptionBudget for the controller.
|
||||
enabled: false
|
||||
# -- Minimum number of pods that must be available during a disruption.
|
||||
# Note: Only one of minAvailable or maxUnavailable should be set.
|
||||
minAvailable: null
|
||||
# -- Maximum number of pods that can be unavailable during a disruption.
|
||||
# Note: Only one of minAvailable or maxUnavailable should be set.
|
||||
maxUnavailable: null
|
||||
|
||||
# -- Whether to enable automatic deletion of stale PVCs due to a scale down operation, when controller.type is 'statefulset'.
|
||||
enableStatefulSetAutoDeletePVC: false
|
||||
|
||||
autoscaling:
|
||||
# -- Creates a HorizontalPodAutoscaler for controller type deployment.
|
||||
# Deprecated: Please use controller.autoscaling.horizontal instead
|
||||
enabled: false
|
||||
# -- The lower limit for the number of replicas to which the autoscaler can scale down.
|
||||
minReplicas: 1
|
||||
# -- The upper limit for the number of replicas to which the autoscaler can scale up.
|
||||
maxReplicas: 5
|
||||
# -- Average CPU utilization across all relevant pods, a percentage of the requested value of the resource for the pods. Setting `targetCPUUtilizationPercentage` to 0 will disable CPU scaling.
|
||||
targetCPUUtilizationPercentage: 0
|
||||
# -- Average Memory utilization across all relevant pods, a percentage of the requested value of the resource for the pods. Setting `targetMemoryUtilizationPercentage` to 0 will disable Memory scaling.
|
||||
targetMemoryUtilizationPercentage: 80
|
||||
|
||||
scaleDown:
|
||||
# -- List of policies to determine the scale-down behavior.
|
||||
policies: []
|
||||
# - type: Pods
|
||||
# value: 4
|
||||
# periodSeconds: 60
|
||||
# -- Determines which of the provided scaling-down policies to apply if multiple are specified.
|
||||
selectPolicy: Max
|
||||
# -- The duration that the autoscaling mechanism should look back on to make decisions about scaling down.
|
||||
stabilizationWindowSeconds: 300
|
||||
|
||||
scaleUp:
|
||||
# -- List of policies to determine the scale-up behavior.
|
||||
policies: []
|
||||
# - type: Pods
|
||||
# value: 4
|
||||
# periodSeconds: 60
|
||||
# -- Determines which of the provided scaling-up policies to apply if multiple are specified.
|
||||
selectPolicy: Max
|
||||
# -- The duration that the autoscaling mechanism should look back on to make decisions about scaling up.
|
||||
stabilizationWindowSeconds: 0
|
||||
|
||||
# -- Configures the Horizontal Pod Autoscaler for the controller.
|
||||
horizontal:
|
||||
# -- Enables the Horizontal Pod Autoscaler for the controller.
|
||||
enabled: false
|
||||
|
||||
# -- The lower limit for the number of replicas to which the autoscaler can scale down.
|
||||
minReplicas: 1
|
||||
# -- The upper limit for the number of replicas to which the autoscaler can scale up.
|
||||
maxReplicas: 5
|
||||
# -- Average CPU utilization across all relevant pods, a percentage of the requested value of the resource for the pods. Setting `targetCPUUtilizationPercentage` to 0 will disable CPU scaling.
|
||||
targetCPUUtilizationPercentage: 0
|
||||
# -- Average Memory utilization across all relevant pods, a percentage of the requested value of the resource for the pods. Setting `targetMemoryUtilizationPercentage` to 0 will disable Memory scaling.
|
||||
targetMemoryUtilizationPercentage: 80
|
||||
|
||||
scaleDown:
|
||||
# -- List of policies to determine the scale-down behavior.
|
||||
policies: []
|
||||
# - type: Pods
|
||||
# value: 4
|
||||
# periodSeconds: 60
|
||||
# -- Determines which of the provided scaling-down policies to apply if multiple are specified.
|
||||
selectPolicy: Max
|
||||
# -- The duration that the autoscaling mechanism should look back on to make decisions about scaling down.
|
||||
stabilizationWindowSeconds: 300
|
||||
|
||||
scaleUp:
|
||||
# -- List of policies to determine the scale-up behavior.
|
||||
policies: []
|
||||
# - type: Pods
|
||||
# value: 4
|
||||
# periodSeconds: 60
|
||||
# -- Determines which of the provided scaling-up policies to apply if multiple are specified.
|
||||
selectPolicy: Max
|
||||
# -- The duration that the autoscaling mechanism should look back on to make decisions about scaling up.
|
||||
stabilizationWindowSeconds: 0
|
||||
# -- Configures the Vertical Pod Autoscaler for the controller.
|
||||
vertical:
|
||||
# -- Enables the Vertical Pod Autoscaler for the controller.
|
||||
enabled: false
|
||||
|
||||
# -- List of recommenders to use for the Vertical Pod Autoscaler.
|
||||
# Recommenders are responsible for generating recommendation for the object.
|
||||
# List should be empty (then the default recommender will generate the recommendation)
|
||||
# or contain exactly one recommender.
|
||||
recommenders: []
|
||||
# recommenders:
|
||||
# - name: custom-recommender-performance
|
||||
|
||||
# -- Configures the resource policy for the Vertical Pod Autoscaler.
|
||||
resourcePolicy:
|
||||
# -- Configures the container policies for the Vertical Pod Autoscaler.
|
||||
containerPolicies:
|
||||
- containerName: alloy
|
||||
# -- The controlled resources for the Vertical Pod Autoscaler.
|
||||
controlledResources:
|
||||
- cpu
|
||||
- memory
|
||||
# -- The controlled values for the Vertical Pod Autoscaler. Needs to be either RequestsOnly or RequestsAndLimits.
|
||||
controlledValues: "RequestsAndLimits"
|
||||
# -- The maximum allowed values for the pods.
|
||||
maxAllowed: {}
|
||||
# cpu: 200m
|
||||
# memory: 100Mi
|
||||
# -- Defines the min allowed resources for the pod
|
||||
minAllowed: {}
|
||||
# cpu: 200m
|
||||
# memory: 100Mi
|
||||
|
||||
# -- Configures the update policy for the Vertical Pod Autoscaler.
|
||||
updatePolicy:
|
||||
# -- Specifies minimal number of replicas which need to be alive for VPA Updater to attempt pod eviction
|
||||
# minReplicas: 1
|
||||
# -- Specifies whether recommended updates are applied when a Pod is started and whether recommended updates
|
||||
# are applied during the life of a Pod. Possible values are "Off", "Initial", "Recreate", and "Auto".
|
||||
# updateMode: Auto
|
||||
|
||||
# -- Affinity configuration for pods.
|
||||
affinity: {}
|
||||
|
||||
volumes:
|
||||
# -- Extra volumes to add to the Grafana Alloy pod.
|
||||
extra: []
|
||||
|
||||
# -- volumeClaimTemplates to add when controller.type is 'statefulset'.
|
||||
volumeClaimTemplates: []
|
||||
|
||||
## -- Additional init containers to run.
|
||||
## ref: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/
|
||||
##
|
||||
initContainers: []
|
||||
|
||||
# -- Additional containers to run alongside the Alloy container and initContainers.
|
||||
extraContainers: []
|
||||
|
||||
service:
|
||||
# -- Creates a Service for the controller's pods.
|
||||
enabled: true
|
||||
# -- Service type
|
||||
type: ClusterIP
|
||||
# -- NodePort port. Only takes effect when `service.type: NodePort`
|
||||
nodePort: 31128
|
||||
# -- Cluster IP, can be set to None, empty "" or an IP address
|
||||
clusterIP: ''
|
||||
# -- Value for internal traffic policy. 'Cluster' or 'Local'
|
||||
internalTrafficPolicy: Cluster
|
||||
annotations: {}
|
||||
# cloud.google.com/load-balancer-type: Internal
|
||||
|
||||
serviceMonitor:
|
||||
enabled: false
|
||||
# -- Additional labels for the service monitor.
|
||||
additionalLabels: {}
|
||||
# -- Scrape interval. If not set, the Prometheus default scrape interval is used.
|
||||
interval: ""
|
||||
# -- MetricRelabelConfigs to apply to samples after scraping, but before ingestion.
|
||||
# ref: https://github.com/prometheus-operator/prometheus-operator/blob/main/Documentation/api.md#relabelconfig
|
||||
metricRelabelings: []
|
||||
# - action: keep
|
||||
# regex: 'kube_(daemonset|deployment|pod|namespace|node|statefulset).+'
|
||||
# sourceLabels: [__name__]
|
||||
|
||||
# -- Customize tls parameters for the service monitor
|
||||
tlsConfig: {}
|
||||
|
||||
# -- RelabelConfigs to apply to samples before scraping
|
||||
# ref: https://github.com/prometheus-operator/prometheus-operator/blob/main/Documentation/api.md#relabelconfig
|
||||
relabelings: []
|
||||
# - sourceLabels: [__meta_kubernetes_pod_node_name]
|
||||
# separator: ;
|
||||
# regex: ^(.*)$
|
||||
# targetLabel: nodename
|
||||
# replacement: $1
|
||||
# action: replace
|
||||
ingress:
|
||||
# -- Enables ingress for Alloy (Faro port)
|
||||
enabled: false
|
||||
# For Kubernetes >= 1.18 you should specify the ingress-controller via the field ingressClassName
|
||||
# See https://kubernetes.io/blog/2020/04/02/improvements-to-the-ingress-api-in-kubernetes-1.18/#specifying-the-class-of-an-ingress
|
||||
# ingressClassName: nginx
|
||||
# Values can be templated
|
||||
annotations:
|
||||
{}
|
||||
# kubernetes.io/ingress.class: nginx
|
||||
# kubernetes.io/tls-acme: "true"
|
||||
labels: {}
|
||||
path: /
|
||||
faroPort: 12347
|
||||
|
||||
# pathType is only for k8s >= 1.1=
|
||||
pathType: Prefix
|
||||
|
||||
hosts:
|
||||
- chart-example.local
|
||||
## Extra paths to prepend to every host configuration. This is useful when working with annotation based services.
|
||||
extraPaths: []
|
||||
# - path: /*
|
||||
# backend:
|
||||
# serviceName: ssl-redirect
|
||||
# servicePort: use-annotation
|
||||
## Or for k8s > 1.19
|
||||
# - path: /*
|
||||
# pathType: Prefix
|
||||
# backend:
|
||||
# service:
|
||||
# name: ssl-redirect
|
||||
# port:
|
||||
# name: use-annotation
|
||||
|
||||
tls: []
|
||||
# - secretName: chart-example-tls
|
||||
# hosts:
|
||||
# - chart-example.local
|
||||
|
||||
# -- Extra k8s manifests to deploy
|
||||
extraObjects: []
|
||||
# - apiVersion: v1
|
||||
# kind: Secret
|
||||
# metadata:
|
||||
# name: grafana-cloud
|
||||
# stringData:
|
||||
# PROMETHEUS_HOST: 'https://prometheus-us-central1.grafana.net/api/prom/push'
|
||||
# PROMETHEUS_USERNAME: '123456'
|
||||
@@ -0,0 +1,15 @@
|
||||
apiVersion: v2
|
||||
appVersion: 4.6.0
|
||||
description: Helm chart for OpenEBS Dynamic Local PV. For instructions to install
|
||||
OpenEBS Dynamic Local PV using helm chart, refer to https://openebs.github.io/dynamic-localpv-provisioner/.
|
||||
home: https://openebs.io
|
||||
icon: https://raw.githubusercontent.com/cncf/artwork/master/projects/openebs/icon/color/openebs-icon-color.png
|
||||
keywords:
|
||||
- storage
|
||||
- local
|
||||
- dynamic-localpv
|
||||
name: localpv-provisioner
|
||||
sources:
|
||||
- https://github.com/openebs/dynamic-localpv-provisioner
|
||||
type: application
|
||||
version: 4.6.0
|
||||
@@ -0,0 +1,128 @@
|
||||
# OpenEBS LocalPV Provisioner
|
||||
|
||||
[](https://opensource.org/licenses/Apache-2.0)
|
||||

|
||||

|
||||
|
||||
A Helm chart for openebs dynamic localpv provisioner. This chart bootstraps OpenEBS Dynamic LocalPV provisioner deployment on a [Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager.
|
||||
|
||||
|
||||
**Homepage:** <http://www.openebs.io/>
|
||||
|
||||
## Get Repo Info
|
||||
|
||||
```console
|
||||
helm repo add openebs-localpv https://openebs.github.io/dynamic-localpv-provisioner
|
||||
helm repo update
|
||||
```
|
||||
|
||||
_See [helm repo](https://helm.sh/docs/helm/helm_repo/) for command documentation._
|
||||
|
||||
## Install Chart
|
||||
|
||||
Please visit the [link](https://openebs.github.io/dynamic-localpv-provisioner/) for install instructions via helm3.
|
||||
|
||||
```console
|
||||
# Helm
|
||||
helm install [RELEASE_NAME] openebs-localpv/localpv-provisioner --namespace [NAMESPACE] --create-namespace
|
||||
```
|
||||
|
||||
_See [configuration](#configuration) below._
|
||||
|
||||
_See [helm install](https://helm.sh/docs/helm/helm_install/) for command documentation._
|
||||
|
||||
## Uninstall Chart
|
||||
|
||||
```console
|
||||
# Helm
|
||||
helm uninstall [RELEASE_NAME] --namespace [NAMESPACE]
|
||||
```
|
||||
|
||||
This removes all the Kubernetes components associated with the chart and deletes the release.
|
||||
|
||||
_See [helm uninstall](https://helm.sh/docs/helm/helm_uninstall/) for command documentation._
|
||||
|
||||
## Upgrading Chart
|
||||
|
||||
```console
|
||||
# Helm
|
||||
helm upgrade [RELEASE_NAME] [CHART] --install --namespace [NAMESPACE]
|
||||
```
|
||||
|
||||
|
||||
## Configuration
|
||||
|
||||
The following table lists the configurable parameters of the OpenEBS Dynamic LocalPV Provisioner chart and their default values.
|
||||
|
||||
You can modify different parameters by specifying the desired value in the `helm install` command by using the `--set` and/or the `--set-string` flag(s).
|
||||
|
||||
```console
|
||||
helm install openebs-localpv openebs-localpv/localpv-provisioner --namespace openebs --create-namespace
|
||||
```
|
||||
|
||||
Sample command to install the provisioner with nodeAffinityLabels "openebs.io/node-affinity-key-1" and "openebs.io/node-affinity-key-2" on the hostpath StorageClass:
|
||||
```console
|
||||
helm install openebs-localpv openebs-localpv/localpv-provisioner --namespace openebs --create-namespace \
|
||||
--set-string hostpathClass.nodeAffinityLabels="{openebs.io/node-affinity-key-1,openebs.io/node-affinity-key-2}"
|
||||
```
|
||||
|
||||
| Parameter | Description | Default |
|
||||
|--------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------|-------------------------------|
|
||||
| `globalImageRegistryOverride` | When set to true, the value of `global.imageRegistry` will override all image registry settings defined at local level | `"false"` |
|
||||
| `global.imagePullSecrets` | Global image pull secrets (merged with local imagePullSecrets and not overridden) | `[]` |
|
||||
| `global.imagePullPolicy` | Global override for image pull policy | `""` |
|
||||
| `global.analytics.enabled` | Global override for analytics | `null` |
|
||||
| `analytics.enabled` | Enable sending stats to Google Analytics | `true` |
|
||||
| `analytics.pingInterval` | Duration(hours) between sending ping stat | `24h` |
|
||||
| `extraLabels` | Additional labels to add to all chart resources | `{}` |
|
||||
| `global.imageRegistry` | Global override for container image registry (when `globalImageRegistryOverride` is set to true) | `"docker.io"` |
|
||||
| `helperPod.image.registry` | Registry for helper image | `""` |
|
||||
| `helperPod.image.repository` | Image for helper pod | `"openebs/linux-utils"` |
|
||||
| `helperPod.image.pullPolicy` | Pull policy for helper pod | `IfNotPresent` |
|
||||
| `helperPod.image.tag` | Image tag for helper image | `4.5.0` |
|
||||
| `helperPod.timeoutSecs` | The maximum number of seconds to wait for a helperPod (init, cleanup, quota) to complete | `120` |
|
||||
| `hostpathClass.allowedTopologies` | Restrict provisioning/scheduling of openebs-hostpath volumes to nodes matching these topology label selectors | `[]` |
|
||||
| `hostpathClass.basePath` | BasePath for openebs-hostpath StorageClass | `"/var/openebs/local"` |
|
||||
| `hostpathClass.enabled` | Enables creation of default Hostpath StorageClass | `true` |
|
||||
| `hostpathClass.isDefaultClass` | Make openebs-hostpath the default StorageClass | `"false"` |
|
||||
| `hostpathClass.nodeAffinityLabels` | Custom node label(or labels) key to uniquely identify nodes. `kubernetes.io/hostname` is the default label key for node selection. | `[]` |
|
||||
| `hostpathClass.xfsQuota.enabled` | Enable XFS Quota (requires XFS filesystem) | `false` |
|
||||
| `hostpathClass.ext4Quota.enabled` | Enable EXT4 Quota (requires EXT4 filesystem) | `false` |
|
||||
| `hostpathClass.reclaimPolicy` | ReclaimPolicy for Hostpath PVs | `"Delete"` |
|
||||
| `imagePullSecrets` | Provides image pull secret | `""` |
|
||||
| `localpv.controller.workers` | The no. of concurrent worker goroutines for processing PVC create/delete events | `4` |
|
||||
| `localpv.controller.client.qps` | Max queries/sec to the Kubernetes API server. Empty uses the client-go default (5) | `""` |
|
||||
| `localpv.controller.client.burst` | Max burst of queries above `client.qps` to the Kubernetes API server. Empty uses the client-go default (10) | `""` |
|
||||
| `localpv.enabled` | Enable LocalPV Provisioner | `true` |
|
||||
| `localpv.image.registry` | Registry for LocalPV Provisioner image | `""` |
|
||||
| `localpv.image.repository` | Image repository for LocalPV Provisioner | `openebs/provisioner-localpv` |
|
||||
| `localpv.image.pullPolicy` | Image pull policy for LocalPV Provisioner | `IfNotPresent` |
|
||||
| `localpv.image.tag` | Image tag for LocalPV Provisioner | `4.6.0` |
|
||||
| `localpv.updateStrategy.type` | Update strategy for LocalPV Provisioner | `RollingUpdate` |
|
||||
| `localpv.annotations` | Annotations for LocalPV Provisioner metadata | `""` |
|
||||
| `localpv.podAnnotations` | Annotations for LocalPV Provisioner pods metadata | `""` |
|
||||
| `localpv.privileged` | Run LocalPV Provisioner with extra privileges | `true` |
|
||||
| `localpv.resources` | Resource and request and limit for containers | `""` |
|
||||
| `localpv.podLabels` | Appends labels to the pods | `""` |
|
||||
| `localpv.nodeSelector` | Nodeselector for LocalPV Provisioner pods | `""` |
|
||||
| `localpv.nodeDeployment.enabled` | Enabled the NodeDeployment mode of installation | `""` |
|
||||
| `localpv.tolerations` | LocalPV Provisioner pod toleration values | `""` |
|
||||
| `localpv.securityContext` | Security context for container | `""` |
|
||||
| `localpv.healthCheck.liveness.enabled` | Keep/remove the liveness probe kubernetes health check | `true` |
|
||||
| `localpv.healthCheck.readiness.enabled` | Keep/remove the readiness probe kubernetes health check | `true` |
|
||||
| `localpv.healthCheck.port` | Set the port to which the health server binds (all interfaces) | `8081` |
|
||||
| `localpv.replicas` | No. of LocalPV Provisioner replica | `1` |
|
||||
| `localpv.allowInsecurePvcBasePathOverride` | Allow namespace tenants to set the BasePath PVC cas-config value | `false` |
|
||||
| `localpv.enableLeaderElection` | Enable leader election | `true` |
|
||||
| `localpv.affinity` | LocalPV Provisioner pod affinity | `{}` |
|
||||
| `localpv.priorityClassName` | Sets priorityClassName in pod | `""` |
|
||||
| `rbac.create` | Enable RBAC Resources | `true` |
|
||||
| `rbac.pspEnabled` | Create pod security policy resources | `false` |
|
||||
|
||||
A YAML file that specifies the values for the parameters can be provided while installing the chart. For example,
|
||||
|
||||
```bash
|
||||
helm install <release-name> -f values.yaml --namespace openebs openebs-localpv/localpv-provisioner
|
||||
```
|
||||
|
||||
> **Tip**: You can use the default [values.yaml](values.yaml)
|
||||
@@ -0,0 +1,9 @@
|
||||
The OpenEBS Dynamic LocalPV Provisioner has been installed.
|
||||
Check its status by running:
|
||||
$ kubectl get pods -n {{ .Release.Namespace }}
|
||||
|
||||
Get started with the Dynamic LocalPV Provisioner Quickstart guide at:
|
||||
https://github.com/openebs/dynamic-localpv-provisioner/blob/develop/docs/quickstart.md
|
||||
|
||||
For more information, visit our Slack at https://kubernetes.slack.com/messages/openebs or view
|
||||
the OpenEBS documentation online at https://openebs.io/docs
|
||||
@@ -0,0 +1,219 @@
|
||||
{{/* vim: set filetype=mustache: */}}
|
||||
{{/*
|
||||
Expand the name of the chart.
|
||||
*/}}
|
||||
{{- define "localpv.name" -}}
|
||||
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Create a default fully qualified localpv provisioner name.
|
||||
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||
If release name contains chart name it will be used as a full name.
|
||||
*/}}
|
||||
{{- define "localpv.fullname" -}}
|
||||
{{- if .Values.fullnameOverride -}}
|
||||
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
|
||||
{{- else -}}
|
||||
{{- $name := default .Chart.Name .Values.nameOverride -}}
|
||||
{{- if contains $name .Release.Name -}}
|
||||
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
|
||||
{{- else -}}
|
||||
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Create chart name and version as used by the chart label.
|
||||
*/}}
|
||||
{{- define "localpv.chart" -}}
|
||||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
|
||||
|
||||
{{/*
|
||||
Meta labels
|
||||
*/}}
|
||||
{{- define "localpv.common.metaLabels" -}}
|
||||
chart: {{ template "localpv.chart" . }}
|
||||
heritage: {{ .Release.Service }}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Selector labels
|
||||
*/}}
|
||||
{{- define "localpv.selectorLabels" -}}
|
||||
app: {{ template "localpv.name" . }}
|
||||
release: {{ .Release.Name }}
|
||||
component: {{ .Values.localpv.name | quote }}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Component labels
|
||||
*/}}
|
||||
{{- define "localpv.componentLabels" -}}
|
||||
openebs.io/component-name: openebs-{{ .Values.localpv.name }}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Common labels
|
||||
*/}}
|
||||
{{- define "localpv.labels" -}}
|
||||
{{ include "localpv.common.metaLabels" . }}
|
||||
{{ include "localpv.selectorLabels" . }}
|
||||
{{ include "localpv.componentLabels" . }}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Create the name of the service account to use
|
||||
*/}}
|
||||
{{- define "localpv.serviceAccountName" -}}
|
||||
{{- if .Values.serviceAccount.create -}}
|
||||
{{ default (include "localpv.fullname" .) .Values.serviceAccount.name }}
|
||||
{{- else -}}
|
||||
{{ default "default" .Values.serviceAccount.name }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Name of the ConfigMap used to record analytics install-event state for the
|
||||
current Helm release.
|
||||
|
||||
Usage:
|
||||
{{ include "localpv.analyticsStateCM.name" . }}
|
||||
*/}}
|
||||
{{- define "localpv.analyticsStateCM.name" -}}
|
||||
{{- printf "%s-analytics-state" (include "localpv.fullname" .) | trunc 63 | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Name of the Lease used by the provisioner to elect a single analytics
|
||||
emitter in node-deployment mode.
|
||||
|
||||
Usage:
|
||||
{{ include "localpv.analyticsLease.name" . }}
|
||||
*/}}
|
||||
{{- define "localpv.analyticsLease.name" -}}
|
||||
{{- printf "%s-analytics" (include "localpv.fullname" .) | trunc 63 | trimSuffix "-" -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Creates the tolerations based on the global tolerations, with early eviction
|
||||
Usage:
|
||||
{{ include "tolerations_with_early_eviction" . }}
|
||||
*/}}
|
||||
{{- define "tolerations_with_early_eviction" -}}
|
||||
{{- if .Values.earlyEvictionTolerations }}
|
||||
{{- toYaml .Values.earlyEvictionTolerations | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.localpv.tolerations }}
|
||||
{{- toYaml .Values.localpv.tolerations | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Creates the image URL ie registry/repository:tag
|
||||
|
||||
Registry resolution is tolerant of upgrades from chart versions that predate
|
||||
.global.imageRegistry (for example v4.1.4, which had no `global` block and left
|
||||
`registry` unset). Each registry source is normalised to a trimmed string
|
||||
(an unset/null value becomes "") before precedence is applied, so a stripped
|
||||
registry - e.g. under `helm upgrade --reuse-values` - no longer fails with
|
||||
"invalid value; expected string".
|
||||
|
||||
- override (globalImageRegistryOverride=true): .global.imageRegistry takes
|
||||
precedence over the image-local registry, falling back to the local one
|
||||
when the global registry is unset.
|
||||
- default (globalImageRegistryOverride=false): the image-local registry
|
||||
takes precedence, falling back to .global.imageRegistry when the local
|
||||
one is unset (retains v4.4.0 behaviour where the global was the default).
|
||||
|
||||
If neither registry resolves (both unset), the image defaults to the docker.io
|
||||
registry - matching the chart's default .global.imageRegistry - so upgrades that
|
||||
dropped the value still render a fully-qualified reference rather than an
|
||||
unprefixed one.
|
||||
*/}}
|
||||
{{- define "localpv.common.image" -}}
|
||||
{{- $global := .global | default dict -}}
|
||||
{{- $localRegistry := .imageRoot.registry | default "" | toString | trimSuffix "/" -}}
|
||||
{{- $globalRegistry := $global.imageRegistry | default "" | toString | trimSuffix "/" -}}
|
||||
{{- $registryName := "" -}}
|
||||
{{- if .override -}}
|
||||
{{- $registryName = $globalRegistry | default $localRegistry -}}
|
||||
{{- else -}}
|
||||
{{- $registryName = $localRegistry | default $globalRegistry -}}
|
||||
{{- end -}}
|
||||
{{- $registryName = $registryName | default "docker.io" -}}
|
||||
{{- $repositoryName := .imageRoot.repository -}}
|
||||
{{- $termination := .imageRoot.tag | toString -}}
|
||||
{{- printf "%s/%s:%s" $registryName $repositoryName $termination -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Concatenates imagepullsecrets, outputs in ENV format and handles different formats (example - secret or - name: secret)
|
||||
*/}}
|
||||
{{- define "localpv.helper.pullSecrets" -}}
|
||||
{{- $names := list -}}
|
||||
{{- with .Values.global.imagePullSecrets -}}
|
||||
{{- range . -}}
|
||||
{{- if kindIs "map" . }}
|
||||
{{- if and (hasKey . "name") (not (empty .name)) -}}
|
||||
{{ $names = append $names .name }}
|
||||
{{- end -}}
|
||||
{{- else if not (empty .) -}}
|
||||
{{ $names = append $names . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- with .Values.imagePullSecrets -}}
|
||||
{{- range . }}
|
||||
{{- if kindIs "map" . -}}
|
||||
{{- if and (hasKey . "name") (not (empty .name)) -}}
|
||||
{{- $names = append $names .name }}
|
||||
{{- end -}}
|
||||
{{- else if not (empty .) -}}
|
||||
{{- $names = append $names . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- if $names }}
|
||||
- name: OPENEBS_IO_IMAGE_PULL_SECRETS
|
||||
value: "{{ join "," ($names | uniq) }}"
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Concatenates imagepullsecrets and handles different formats (example - secret or - name: secret)
|
||||
*/}}
|
||||
{{- define "localpv.common.pullSecrets" -}}
|
||||
{{- $names := list -}}
|
||||
{{- with .Values.global.imagePullSecrets -}}
|
||||
{{- range . -}}
|
||||
{{- if kindIs "map" . }}
|
||||
{{- if and (hasKey . "name") (not (empty .name)) -}}
|
||||
{{ $names = append $names .name }}
|
||||
{{- end -}}
|
||||
{{- else if not (empty .) -}}
|
||||
{{ $names = append $names . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- with .Values.imagePullSecrets -}}
|
||||
{{- range . }}
|
||||
{{- if kindIs "map" . -}}
|
||||
{{- if and (hasKey . "name") (not (empty .name)) -}}
|
||||
{{- $names = append $names .name }}
|
||||
{{- end -}}
|
||||
{{- else if not (empty .) -}}
|
||||
{{- $names = append $names . -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- $names = uniq $names -}}
|
||||
{{- if $names -}}
|
||||
{{- range $names }}
|
||||
- name: {{ . }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,27 @@
|
||||
{{/*
|
||||
Chart-managed Lease for analytics leader election (node-deployment mode only).
|
||||
|
||||
Elects a single analytics emitter across DaemonSet pods. Helm-managed so
|
||||
`helm uninstall` cleanly removes it; without this, the Lease would persist
|
||||
in the namespace with the previous holder's identity, and the next install
|
||||
would have to wait out LeaseDuration before acquiring leadership.
|
||||
*/}}
|
||||
{{- if .Values.localpv.enabled }}
|
||||
{{- $analyticsEnabled := .Values.analytics.enabled -}}
|
||||
{{- if kindIs "bool" .Values.global.analytics.enabled -}}
|
||||
{{- $analyticsEnabled = .Values.global.analytics.enabled -}}
|
||||
{{- end -}}
|
||||
{{- if and $analyticsEnabled .Values.localpv.nodeDeployment.enabled }}
|
||||
apiVersion: coordination.k8s.io/v1
|
||||
kind: Lease
|
||||
metadata:
|
||||
name: {{ include "localpv.analyticsLease.name" . }}
|
||||
namespace: {{ .Release.Namespace }}
|
||||
labels:
|
||||
{{- include "localpv.labels" . | nindent 4 }}
|
||||
{{- if .Values.extraLabels -}}
|
||||
{{- toYaml .Values.extraLabels | nindent 4 }}
|
||||
{{- end }}
|
||||
spec: {}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,217 @@
|
||||
{{- if .Values.localpv.enabled }}
|
||||
{{- if .Values.localpv.nodeDeployment.enabled }}
|
||||
{{- $healthPort := default 8081 .Values.localpv.healthCheck.port }}
|
||||
apiVersion: apps/v1
|
||||
kind: DaemonSet
|
||||
metadata:
|
||||
name: {{ template "localpv.fullname" . }}-node
|
||||
{{- with .Values.localpv.annotations }}
|
||||
annotations: {{ toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "localpv.labels" . | nindent 4 }}
|
||||
{{- if .Values.extraLabels -}}
|
||||
{{- toYaml .Values.extraLabels | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "localpv.selectorLabels" . | nindent 6 }}
|
||||
template:
|
||||
metadata:
|
||||
{{- with .Values.localpv.podAnnotations }}
|
||||
annotations: {{ toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "localpv.labels" . | nindent 8 }}
|
||||
{{- if .Values.extraLabels -}}
|
||||
{{- toYaml .Values.extraLabels | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.localpv.podLabels }}
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.loggingLabels}}
|
||||
{{ toYaml . | nindent 8 -}}
|
||||
{{- end}}
|
||||
spec:
|
||||
{{- if .Values.localpv.priorityClassName }}
|
||||
priorityClassName: {{ tpl .Values.localpv.priorityClassName . }}
|
||||
{{- end }}
|
||||
{{- if or .Values.global.imagePullSecrets .Values.imagePullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{- include "localpv.common.pullSecrets" . | indent 6 }}
|
||||
{{- end }}
|
||||
serviceAccountName: {{ template "localpv.serviceAccountName" . }}
|
||||
securityContext:
|
||||
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||
containers:
|
||||
- name: {{ template "localpv.fullname" . }}
|
||||
image: "{{ include "localpv.common.image" (dict "imageRoot" .Values.localpv.image "global" .Values.global "override" .Values.globalImageRegistryOverride) }}"
|
||||
imagePullPolicy: {{ default .Values.localpv.image.pullPolicy .Values.global.imagePullPolicy }}
|
||||
{{- if .Values.localpv.privileged }}
|
||||
securityContext:
|
||||
privileged: true
|
||||
{{- end }}
|
||||
resources:
|
||||
{{ toYaml .Values.localpv.resources | indent 10 }}
|
||||
env:
|
||||
# OPENEBS_IO_K8S_MASTER enables openebs provisioner to connect to K8s
|
||||
# based on this address. This is ignored if empty.
|
||||
# This is supported for openebs provisioner version 0.5.2 onwards
|
||||
#- name: OPENEBS_IO_K8S_MASTER
|
||||
# value: "http://10.128.0.12:8080"
|
||||
# OPENEBS_IO_KUBE_CONFIG enables openebs provisioner to connect to K8s
|
||||
# based on this config. This is ignored if empty.
|
||||
# This is supported for openebs provisioner version 0.5.2 onwards
|
||||
#- name: OPENEBS_IO_KUBE_CONFIG
|
||||
# value: "/home/ubuntu/.kube/config"
|
||||
- name: OPENEBS_NAMESPACE
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: metadata.namespace
|
||||
- name: NODE_NAME
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: spec.nodeName
|
||||
# POD_NAME is consumed by the analytics leader-election code in
|
||||
# node-deployment mode so that each DaemonSet pod has a stable,
|
||||
# unique lease identity. Required for correct singleton behavior
|
||||
# of install/ping/heartbeat events.
|
||||
- name: POD_NAME
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: metadata.name
|
||||
# OPENEBS_SERVICE_ACCOUNT provides the service account of this pod as
|
||||
# environment variable
|
||||
- name: OPENEBS_SERVICE_ACCOUNT
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: spec.serviceAccountName
|
||||
# OPENEBS_IO_BASE_PATH is the environment variable that provides the
|
||||
# default base path on the node where host-path PVs will be provisioned.
|
||||
{{- if kindIs "bool" .Values.global.analytics.enabled }}
|
||||
- name: OPENEBS_IO_ENABLE_ANALYTICS
|
||||
value: "{{ .Values.global.analytics.enabled }}"
|
||||
{{- else }}
|
||||
- name: OPENEBS_IO_ENABLE_ANALYTICS
|
||||
value: "{{ .Values.analytics.enabled }}"
|
||||
{{- end }}
|
||||
# OPENEBS_IO_ANALYTICS_STATE_CM names the ConfigMap consulted to
|
||||
# decide whether to emit the install event for this Helm release
|
||||
# and to persist ping/heartbeat timestamps across pod restarts.
|
||||
# The provisioner creates and updates this ConfigMap itself; it
|
||||
# is not managed by Helm.
|
||||
- name: OPENEBS_IO_ANALYTICS_STATE_CM
|
||||
value: {{ include "localpv.analyticsStateCM.name" . | quote }}
|
||||
# OPENEBS_IO_ANALYTICS_LEASE names the Lease used to elect a single
|
||||
# analytics emitter across all DaemonSet pods. Release-scoped so
|
||||
# multiple releases in the same namespace do not collide. The
|
||||
# provisioner creates the Lease on-demand via client-go's
|
||||
# leader-election; it is not managed by Helm.
|
||||
- name: OPENEBS_IO_ANALYTICS_LEASE
|
||||
value: {{ include "localpv.analyticsLease.name" . | quote }}
|
||||
{{- if .Values.global.analytics.gaId }}
|
||||
- name: GA_ID
|
||||
value: {{ .Values.global.analytics.gaId | quote }}
|
||||
{{- else if .Values.analytics.gaId }}
|
||||
- name: GA_ID
|
||||
value: {{ .Values.analytics.gaId | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.global.analytics.gaKey }}
|
||||
- name: GA_KEY
|
||||
value: {{ .Values.global.analytics.gaKey | quote }}
|
||||
{{- else if .Values.analytics.gaKey }}
|
||||
- name: GA_KEY
|
||||
value: {{ .Values.analytics.gaKey | quote }}
|
||||
{{- end }}
|
||||
- name: OPENEBS_IO_BASE_PATH
|
||||
value: "{{ .Values.localpv.basePath }}"
|
||||
- name: OPENEBS_IO_WORKER_THREADS
|
||||
value: {{ .Values.localpv.controller.workers | quote }}
|
||||
{{- if .Values.localpv.controller.client.qps }}
|
||||
- name: OPENEBS_IO_CLIENT_QPS
|
||||
value: {{ .Values.localpv.controller.client.qps | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.localpv.controller.client.burst }}
|
||||
- name: OPENEBS_IO_CLIENT_BURST
|
||||
value: {{ .Values.localpv.controller.client.burst | quote }}
|
||||
{{- end }}
|
||||
- name: OPENEBS_IO_HELPER_IMAGE
|
||||
value: "{{ include "localpv.common.image" (dict "imageRoot" .Values.helperPod.image "global" .Values.global "override" .Values.globalImageRegistryOverride) }}"
|
||||
- name: OPENEBS_IO_IMAGE_PULL_POLICY
|
||||
value: "{{ default .Values.helperPod.image.pullPolicy .Values.global.imagePullPolicy }}"
|
||||
- name: OPENEBS_IO_HELPER_POD_HOST_NETWORK
|
||||
value: "{{ .Values.helperPod.hostNetwork }}"
|
||||
- name: OPENEBS_IO_INSTALLER_TYPE
|
||||
value: "localpv-charts-helm-nodedeploy"
|
||||
- name: OPENEBS_IO_HELPER_POD_TIMEOUT_SECS
|
||||
value: {{ .Values.helperPod.timeoutSecs | quote }}
|
||||
# Disable leader election in node deployment mode.
|
||||
# Not related to anonymous usage analytics leader election.
|
||||
- name: LEADER_ELECTION_ENABLED
|
||||
value: "false"
|
||||
# Enable node deployment mode
|
||||
- name: NODE_DEPLOYMENT
|
||||
value: "true"
|
||||
# OPENEBS_IO_HEALTH_PROBE_BIND_ADDRESS is the address the health-probe
|
||||
# HTTP server binds to. /healthz serves liveness, /readyz serves readiness.
|
||||
- name: OPENEBS_IO_HEALTH_PROBE_BIND_ADDRESS
|
||||
value: ":{{ $healthPort }}"
|
||||
{{- include "localpv.helper.pullSecrets" . | indent 8 }}
|
||||
args:
|
||||
- "--node-deployment=true"
|
||||
{{- if .Values.localpv.allowInsecurePvcBasePathOverride }}
|
||||
- "--allow-insecure-pvc-basepath-override"
|
||||
{{- end }}
|
||||
ports:
|
||||
- name: healthz
|
||||
containerPort: {{ $healthPort }}
|
||||
protocol: TCP
|
||||
{{- if .Values.localpv.healthCheck.liveness.enabled }}
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /healthz
|
||||
port: healthz
|
||||
initialDelaySeconds: {{ .Values.localpv.healthCheck.liveness.initialDelaySeconds }}
|
||||
periodSeconds: {{ .Values.localpv.healthCheck.liveness.periodSeconds }}
|
||||
timeoutSeconds: {{ .Values.localpv.healthCheck.liveness.timeoutSeconds }}
|
||||
failureThreshold: {{ .Values.localpv.healthCheck.liveness.failureThreshold }}
|
||||
{{- end }}
|
||||
{{- if .Values.localpv.healthCheck.readiness.enabled }}
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /readyz
|
||||
port: healthz
|
||||
initialDelaySeconds: {{ .Values.localpv.healthCheck.readiness.initialDelaySeconds }}
|
||||
periodSeconds: {{ .Values.localpv.healthCheck.readiness.periodSeconds }}
|
||||
timeoutSeconds: {{ .Values.localpv.healthCheck.readiness.timeoutSeconds }}
|
||||
failureThreshold: {{ .Values.localpv.healthCheck.readiness.failureThreshold }}
|
||||
{{- end }}
|
||||
volumeMounts:
|
||||
- name: host-root
|
||||
mountPath: /host
|
||||
mountPropagation: HostToContainer
|
||||
{{- if .Values.localpv.nodeDeployment.additionalVolumeMounts }}
|
||||
{{ toYaml .Values.localpv.nodeDeployment.additionalVolumeMounts | indent 8 }}
|
||||
{{- end }}
|
||||
volumes:
|
||||
- name: host-root
|
||||
hostPath:
|
||||
path: /
|
||||
type: Directory
|
||||
{{- if .Values.localpv.nodeDeployment.additionalVolumes }}
|
||||
{{ toYaml .Values.localpv.nodeDeployment.additionalVolumes | indent 6 }}
|
||||
{{- end }}
|
||||
{{- if .Values.localpv.nodeSelector }}
|
||||
nodeSelector:
|
||||
{{ toYaml .Values.localpv.nodeSelector | indent 8 }}
|
||||
{{- end }}
|
||||
{{- if $tolerations := include "tolerations_with_early_eviction" . }}
|
||||
tolerations: {{ $tolerations }}
|
||||
{{- end }}
|
||||
{{- if .Values.localpv.affinity }}
|
||||
affinity:
|
||||
{{ toYaml .Values.localpv.affinity | indent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,198 @@
|
||||
{{- if .Values.localpv.enabled }}
|
||||
{{- if not .Values.localpv.nodeDeployment.enabled }}
|
||||
{{- $healthPort := default 8081 .Values.localpv.healthCheck.port }}
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: {{ template "localpv.fullname" . }}
|
||||
namespace: {{ .Release.Namespace }}
|
||||
{{- with .Values.localpv.annotations }}
|
||||
annotations: {{ toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "localpv.labels" . | nindent 4 }}
|
||||
{{- if .Values.extraLabels -}}
|
||||
{{- toYaml .Values.extraLabels | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
replicas: {{ .Values.localpv.replicas }}
|
||||
strategy:
|
||||
type: "Recreate"
|
||||
rollingUpdate: null
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "localpv.selectorLabels" . | nindent 6 }}
|
||||
template:
|
||||
metadata:
|
||||
{{- with .Values.localpv.podAnnotations }}
|
||||
annotations: {{ toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "localpv.labels" . | nindent 8 }}
|
||||
{{- if .Values.extraLabels -}}
|
||||
{{- toYaml .Values.extraLabels | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.localpv.podLabels }}
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.loggingLabels}}
|
||||
{{ toYaml . | nindent 8 -}}
|
||||
{{- end}}
|
||||
spec:
|
||||
{{- if .Values.localpv.priorityClassName }}
|
||||
priorityClassName: {{ tpl .Values.localpv.priorityClassName . }}
|
||||
{{- end }}
|
||||
{{- if or .Values.global.imagePullSecrets .Values.imagePullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{- include "localpv.common.pullSecrets" . | indent 6 }}
|
||||
{{- end }}
|
||||
serviceAccountName: {{ template "localpv.serviceAccountName" . }}
|
||||
securityContext:
|
||||
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||
containers:
|
||||
- name: {{ template "localpv.fullname" . }}
|
||||
image: "{{ include "localpv.common.image" (dict "imageRoot" .Values.localpv.image "global" .Values.global "override" .Values.globalImageRegistryOverride) }}"
|
||||
imagePullPolicy: {{ default .Values.localpv.image.pullPolicy .Values.global.imagePullPolicy }}
|
||||
resources:
|
||||
{{ toYaml .Values.localpv.resources | indent 10 }}
|
||||
env:
|
||||
# OPENEBS_IO_K8S_MASTER enables openebs provisioner to connect to K8s
|
||||
# based on this address. This is ignored if empty.
|
||||
# This is supported for openebs provisioner version 0.5.2 onwards
|
||||
#- name: OPENEBS_IO_K8S_MASTER
|
||||
# value: "http://10.128.0.12:8080"
|
||||
# OPENEBS_IO_KUBE_CONFIG enables openebs provisioner to connect to K8s
|
||||
# based on this config. This is ignored if empty.
|
||||
# This is supported for openebs provisioner version 0.5.2 onwards
|
||||
#- name: OPENEBS_IO_KUBE_CONFIG
|
||||
# value: "/home/ubuntu/.kube/config"
|
||||
- name: OPENEBS_NAMESPACE
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: metadata.namespace
|
||||
- name: NODE_NAME
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: spec.nodeName
|
||||
# OPENEBS_SERVICE_ACCOUNT provides the service account of this pod as
|
||||
# environment variable
|
||||
- name: OPENEBS_SERVICE_ACCOUNT
|
||||
valueFrom:
|
||||
fieldRef:
|
||||
fieldPath: spec.serviceAccountName
|
||||
# OPENEBS_IO_BASE_PATH is the environment variable that provides the
|
||||
# default base path on the node where host-path PVs will be provisioned.
|
||||
{{- if kindIs "bool" .Values.global.analytics.enabled }}
|
||||
- name: OPENEBS_IO_ENABLE_ANALYTICS
|
||||
value: "{{ .Values.global.analytics.enabled }}"
|
||||
{{- else }}
|
||||
- name: OPENEBS_IO_ENABLE_ANALYTICS
|
||||
value: "{{ .Values.analytics.enabled }}"
|
||||
{{- end }}
|
||||
# OPENEBS_IO_ANALYTICS_STATE_CM names the ConfigMap consulted to
|
||||
# decide whether to emit the install event for this Helm release
|
||||
# and to persist ping/heartbeat timestamps across pod restarts.
|
||||
# The provisioner creates and updates this ConfigMap itself; it
|
||||
# is not managed by Helm. helm uninstall does not remove it, so
|
||||
# reinstalls into the same namespace will not re-fire the install
|
||||
# event unless the ConfigMap is deleted manually.
|
||||
- name: OPENEBS_IO_ANALYTICS_STATE_CM
|
||||
value: {{ include "localpv.analyticsStateCM.name" . | quote }}
|
||||
{{- if .Values.global.analytics.gaId }}
|
||||
- name: GA_ID
|
||||
value: {{ .Values.global.analytics.gaId | quote }}
|
||||
{{- else if .Values.analytics.gaId }}
|
||||
- name: GA_ID
|
||||
value: {{ .Values.analytics.gaId | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.global.analytics.gaKey }}
|
||||
- name: GA_KEY
|
||||
value: {{ .Values.global.analytics.gaKey | quote }}
|
||||
{{- else if .Values.analytics.gaKey }}
|
||||
- name: GA_KEY
|
||||
value: {{ .Values.analytics.gaKey | quote }}
|
||||
{{- end }}
|
||||
- name: OPENEBS_IO_BASE_PATH
|
||||
value: "{{ .Values.localpv.basePath }}"
|
||||
- name: OPENEBS_IO_WORKER_THREADS
|
||||
value: {{ .Values.localpv.controller.workers | quote }}
|
||||
{{- if .Values.localpv.controller.client.qps }}
|
||||
- name: OPENEBS_IO_CLIENT_QPS
|
||||
value: {{ .Values.localpv.controller.client.qps | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.localpv.controller.client.burst }}
|
||||
- name: OPENEBS_IO_CLIENT_BURST
|
||||
value: {{ .Values.localpv.controller.client.burst | quote }}
|
||||
{{- end }}
|
||||
- name: OPENEBS_IO_IMAGE_PULL_POLICY
|
||||
value: "{{ default .Values.helperPod.image.pullPolicy .Values.global.imagePullPolicy }}"
|
||||
- name: OPENEBS_IO_HELPER_IMAGE
|
||||
value: "{{ include "localpv.common.image" (dict "imageRoot" .Values.helperPod.image "global" .Values.global "override" .Values.globalImageRegistryOverride) }}"
|
||||
- name: OPENEBS_IO_HELPER_POD_HOST_NETWORK
|
||||
value: "{{ .Values.helperPod.hostNetwork }}"
|
||||
- name: OPENEBS_IO_INSTALLER_TYPE
|
||||
value: "localpv-charts-helm-helperpod"
|
||||
- name: OPENEBS_IO_HELPER_POD_TIMEOUT_SECS
|
||||
value: {{ .Values.helperPod.timeoutSecs | quote }}
|
||||
# LEADER_ELECTION_ENABLED is used to enable/disable leader election. By default
|
||||
# leader election is enabled.
|
||||
- name: LEADER_ELECTION_ENABLED
|
||||
value: "{{ .Values.localpv.enableLeaderElection }}"
|
||||
# OPENEBS_IO_HEALTH_PROBE_BIND_ADDRESS is the address the health-probe
|
||||
# HTTP server binds to. /healthz serves liveness, /readyz serves readiness.
|
||||
- name: OPENEBS_IO_HEALTH_PROBE_BIND_ADDRESS
|
||||
value: ":{{ $healthPort }}"
|
||||
{{- include "localpv.helper.pullSecrets" . | indent 8 }}
|
||||
{{/* Add args below */}}
|
||||
{{/* All args are optional (so far, at least), so the 'args' PodTemplate key
|
||||
* is only included if there is at least one arg. And that's why we're doing
|
||||
* it this way.
|
||||
*/}}
|
||||
{{- $args := list }}
|
||||
{{- if .Values.localpv.allowInsecurePvcBasePathOverride }}
|
||||
{{- $args = append $args "--allow-insecure-pvc-basepath-override" }}
|
||||
{{- end }}
|
||||
|
||||
{{- if $args }}
|
||||
args:
|
||||
{{- range $args }}
|
||||
- {{ . | quote }} {{/* Add new args to the above $args list */}}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
ports:
|
||||
- name: healthz
|
||||
containerPort: {{ $healthPort }}
|
||||
protocol: TCP
|
||||
{{- if .Values.localpv.healthCheck.liveness.enabled }}
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /healthz
|
||||
port: healthz
|
||||
initialDelaySeconds: {{ .Values.localpv.healthCheck.liveness.initialDelaySeconds }}
|
||||
periodSeconds: {{ .Values.localpv.healthCheck.liveness.periodSeconds }}
|
||||
timeoutSeconds: {{ .Values.localpv.healthCheck.liveness.timeoutSeconds }}
|
||||
failureThreshold: {{ .Values.localpv.healthCheck.liveness.failureThreshold }}
|
||||
{{- end }}
|
||||
{{- if .Values.localpv.healthCheck.readiness.enabled }}
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /readyz
|
||||
port: healthz
|
||||
initialDelaySeconds: {{ .Values.localpv.healthCheck.readiness.initialDelaySeconds }}
|
||||
periodSeconds: {{ .Values.localpv.healthCheck.readiness.periodSeconds }}
|
||||
timeoutSeconds: {{ .Values.localpv.healthCheck.readiness.timeoutSeconds }}
|
||||
failureThreshold: {{ .Values.localpv.healthCheck.readiness.failureThreshold }}
|
||||
{{- end }}
|
||||
{{- if .Values.localpv.nodeSelector }}
|
||||
nodeSelector:
|
||||
{{ toYaml .Values.localpv.nodeSelector | indent 8 }}
|
||||
{{- end }}
|
||||
{{- if $tolerations := include "tolerations_with_early_eviction" . }}
|
||||
tolerations: {{ $tolerations }}
|
||||
{{- end }}
|
||||
{{- if .Values.localpv.affinity }}
|
||||
affinity:
|
||||
{{ toYaml .Values.localpv.affinity | indent 8 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,47 @@
|
||||
{{- if .Values.hostpathClass.enabled }}
|
||||
apiVersion: storage.k8s.io/v1
|
||||
kind: StorageClass
|
||||
metadata:
|
||||
name: {{ tpl (.Values.hostpathClass.name) .}}
|
||||
annotations:
|
||||
openebs.io/cas-type: local
|
||||
cas.openebs.io/config: |
|
||||
- name: StorageType
|
||||
value: "hostpath"
|
||||
{{- if or .Values.localpv.basePath .Values.hostpathClass.basePath }}
|
||||
- name: BasePath
|
||||
value: {{ tpl (.Values.hostpathClass.basePath | default .Values.localpv.basePath | quote) . }}
|
||||
{{- end }}
|
||||
{{- if .Values.hostpathClass.nodeAffinityLabels }}
|
||||
- name: NodeAffinityLabels
|
||||
list:
|
||||
{{ toYaml .Values.hostpathClass.nodeAffinityLabels | indent 10 }}
|
||||
{{- end }}
|
||||
{{- if .Values.hostpathClass.xfsQuota.enabled }}
|
||||
- name: XFSQuota
|
||||
enabled: "{{ .Values.hostpathClass.xfsQuota.enabled }}"
|
||||
data:
|
||||
softLimitGrace: "{{ .Values.hostpathClass.xfsQuota.softLimitGrace }}"
|
||||
hardLimitGrace: "{{ .Values.hostpathClass.xfsQuota.hardLimitGrace }}"
|
||||
{{- end }}
|
||||
{{- if .Values.hostpathClass.ext4Quota.enabled }}
|
||||
- name: EXT4Quota
|
||||
enabled: "{{ .Values.hostpathClass.ext4Quota.enabled }}"
|
||||
data:
|
||||
softLimitGrace: "{{ .Values.hostpathClass.ext4Quota.softLimitGrace }}"
|
||||
hardLimitGrace: "{{ .Values.hostpathClass.ext4Quota.hardLimitGrace }}"
|
||||
{{- end }}
|
||||
{{- if .Values.hostpathClass.isDefaultClass }}
|
||||
storageclass.kubernetes.io/is-default-class: "true"
|
||||
{{- end }}
|
||||
{{- if .Values.extraLabels }}
|
||||
labels: {{- toYaml .Values.extraLabels | nindent 4 -}}
|
||||
{{- end }}
|
||||
provisioner: openebs.io/local
|
||||
volumeBindingMode: WaitForFirstConsumer
|
||||
reclaimPolicy: {{ .Values.hostpathClass.reclaimPolicy }}
|
||||
{{- if .Values.hostpathClass.allowedTopologies }}
|
||||
allowedTopologies:
|
||||
{{ toYaml .Values.hostpathClass.allowedTopologies }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,33 @@
|
||||
{{- if .Values.rbac.pspEnabled }}
|
||||
apiVersion: policy/v1beta1
|
||||
kind: PodSecurityPolicy
|
||||
metadata:
|
||||
name: {{ template "localpv.fullname" . }}-psp
|
||||
{{- with .Values.localpv.annotations }}
|
||||
annotations: {{ toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "localpv.labels" . | nindent 4 }}
|
||||
{{- if .Values.extraLabels -}}
|
||||
{{- toYaml .Values.extraLabels | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
privileged: {{ .Values.localpv.privileged }}
|
||||
allowPrivilegeEscalation: true
|
||||
allowedCapabilities: ['*']
|
||||
volumes: ['*']
|
||||
hostNetwork: true
|
||||
hostPorts:
|
||||
- min: 0
|
||||
max: 65535
|
||||
hostIPC: true
|
||||
hostPID: true
|
||||
runAsUser:
|
||||
rule: 'RunAsAny'
|
||||
seLinux:
|
||||
rule: 'RunAsAny'
|
||||
supplementalGroups:
|
||||
rule: 'RunAsAny'
|
||||
fsGroup:
|
||||
rule: 'RunAsAny'
|
||||
{{- end }}
|
||||
@@ -0,0 +1,124 @@
|
||||
{{- if .Values.serviceAccount.create -}}
|
||||
apiVersion: v1
|
||||
kind: ServiceAccount
|
||||
metadata:
|
||||
name: {{ include "localpv.serviceAccountName" . }}
|
||||
namespace: {{ .Release.Namespace }}
|
||||
labels:
|
||||
{{- include "localpv.labels" . | nindent 4 }}
|
||||
{{- if .Values.extraLabels -}}
|
||||
{{- toYaml .Values.extraLabels | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.serviceAccount.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.rbac.create }}
|
||||
---
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
kind: ClusterRole
|
||||
metadata:
|
||||
name: {{ template "localpv.fullname" . }}
|
||||
{{- with .Values.localpv.annotations }}
|
||||
annotations: {{ toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "localpv.labels" . | nindent 4 }}
|
||||
{{- if .Values.extraLabels -}}
|
||||
{{- toYaml .Values.extraLabels | nindent 4 }}
|
||||
{{- end }}
|
||||
rules:
|
||||
- apiGroups: ["*"]
|
||||
resources: ["nodes"]
|
||||
verbs: ["get", "list", "watch"]
|
||||
- apiGroups: ["*"]
|
||||
resources: ["namespaces", "pods", "events", "endpoints"]
|
||||
verbs: ["*"]
|
||||
- apiGroups: ["*"]
|
||||
resources: ["resourcequotas", "limitranges"]
|
||||
verbs: ["list", "watch"]
|
||||
- apiGroups: ["*"]
|
||||
resources: ["storageclasses", "persistentvolumeclaims", "persistentvolumes"]
|
||||
verbs: ["*"]
|
||||
- apiGroups: ["apiextensions.k8s.io"]
|
||||
resources: ["customresourcedefinitions"]
|
||||
verbs: [ "get", "list", "create", "update", "delete", "patch"]
|
||||
- apiGroups: ["openebs.io"]
|
||||
resources: [ "*"]
|
||||
verbs: ["*" ]
|
||||
- apiGroups: ["coordination.k8s.io"]
|
||||
resources: ["leases"]
|
||||
verbs: ["get", "create", "update"]
|
||||
# Analytics state ConfigMap: the provisioner creates and updates this
|
||||
# ConfigMap itself to persist install/ping/heartbeat timestamps.
|
||||
- apiGroups: [""]
|
||||
resources: ["configmaps"]
|
||||
verbs: ["get", "create", "update", "patch"]
|
||||
- nonResourceURLs: ["/metrics"]
|
||||
verbs: ["get"]
|
||||
---
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
kind: ClusterRoleBinding
|
||||
metadata:
|
||||
name: {{ template "localpv.fullname" . }}
|
||||
{{- with .Values.localpv.annotations }}
|
||||
annotations: {{ toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "localpv.labels" . | nindent 4 }}
|
||||
{{- if .Values.extraLabels -}}
|
||||
{{- toYaml .Values.extraLabels | nindent 4 }}
|
||||
{{- end }}
|
||||
roleRef:
|
||||
apiGroup: rbac.authorization.k8s.io
|
||||
kind: ClusterRole
|
||||
name: {{ template "localpv.fullname" . }}
|
||||
subjects:
|
||||
- kind: ServiceAccount
|
||||
name: {{ template "localpv.serviceAccountName" . }}
|
||||
namespace: {{ .Release.Namespace }}
|
||||
{{- if .Values.rbac.pspEnabled }}
|
||||
---
|
||||
kind: ClusterRole
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
metadata:
|
||||
name: {{ template "localpv.fullname" . }}-psp
|
||||
{{- with .Values.localpv.annotations }}
|
||||
annotations: {{ toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "localpv.labels" . | nindent 4 }}
|
||||
{{- if .Values.extraLabels -}}
|
||||
{{- toYaml .Values.extraLabels | nindent 4 }}
|
||||
{{- end }}
|
||||
rules:
|
||||
- apiGroups: ['policy']
|
||||
resources: ['podsecuritypolicies']
|
||||
verbs: ['use']
|
||||
resourceNames:
|
||||
- {{ template "localpv.fullname" . }}-psp
|
||||
---
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
kind: ClusterRoleBinding
|
||||
metadata:
|
||||
name: {{ template "localpv.fullname" . }}-psp
|
||||
{{- with .Values.localpv.annotations }}
|
||||
annotations: {{ toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "localpv.labels" . | nindent 4 }}
|
||||
{{- if .Values.extraLabels -}}
|
||||
{{- toYaml .Values.extraLabels | nindent 4 }}
|
||||
{{- end }}
|
||||
roleRef:
|
||||
apiGroup: rbac.authorization.k8s.io
|
||||
kind: ClusterRole
|
||||
name: {{ template "localpv.fullname" . }}-psp
|
||||
subjects:
|
||||
- kind: ServiceAccount
|
||||
name: {{ template "localpv.serviceAccountName" . }}
|
||||
namespace: {{ $.Release.Namespace }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
@@ -0,0 +1,233 @@
|
||||
# Default values for localpv.
|
||||
# This is a YAML-formatted file.
|
||||
# Declare variables to be passed into your templates.
|
||||
|
||||
# NOTE: This option is required so that .global.imageRegistry works as an override
|
||||
# for the local image registry values. By default, this option is set to false
|
||||
# and that's to retain backwards compatibility with v4.4.0 where .global.imageRegistry
|
||||
# was introduced as the default and the local options were overrides for the global default.
|
||||
# The other .global options do not work this way, and they are all overrides for their
|
||||
# respective options. If you're not upgrading from v4.4.0, you'll want to enable
|
||||
# this option (set to 'true').
|
||||
globalImageRegistryOverride: false
|
||||
|
||||
global:
|
||||
# Global override for container image registry (when `globalImageRegistryOverride` is set to true)
|
||||
imageRegistry: "docker.io"
|
||||
# Global image pull secrets (merged with local imagePullSecrets and not overridden)
|
||||
# - secret
|
||||
imagePullSecrets: []
|
||||
# Global override for image pull policy
|
||||
imagePullPolicy: ""
|
||||
analytics:
|
||||
# Global override for analytics
|
||||
enabled:
|
||||
|
||||
rbac:
|
||||
# rbac.create: `true` if rbac resources should be created
|
||||
create: true
|
||||
# rbac.pspEnabled: `true` if PodSecurityPolicy resources should be created
|
||||
pspEnabled: false
|
||||
|
||||
earlyEvictionTolerations:
|
||||
- effect: NoExecute
|
||||
key: node.kubernetes.io/unreachable
|
||||
operator: Exists
|
||||
tolerationSeconds: 5
|
||||
- effect: NoExecute
|
||||
key: node.kubernetes.io/not-ready
|
||||
operator: Exists
|
||||
tolerationSeconds: 5
|
||||
|
||||
localpv:
|
||||
name: localpv-provisioner
|
||||
enabled: true
|
||||
controller:
|
||||
# The number of concurrent worker goroutines for processing PVC create and delete events.
|
||||
# Higher values increase provisioning throughput when many PVC events are received simultaneously.
|
||||
workers: 4
|
||||
# Client-side rate limits for requests to the Kubernetes API server.
|
||||
client:
|
||||
# Maximum queries per second (QPS) the provisioner sends to the Kubernetes API server.
|
||||
# Leave empty to use the client-go default (5). Raise it alongside `workers` to avoid
|
||||
# client-side throttling when provisioning many volumes concurrently.
|
||||
qps: ""
|
||||
# Maximum burst of queries above `client.qps` the provisioner allows to the Kubernetes
|
||||
# API server. Leave empty to use the client-go default (10). Setting `client.qps`
|
||||
# without `client.burst` leaves burst at the client-go default of 10, which may
|
||||
# throttle bursts well below the configured QPS; prefer setting both together.
|
||||
burst: ""
|
||||
image:
|
||||
registry: "docker.io/"
|
||||
repository: openebs/provisioner-localpv
|
||||
tag: 4.6.0
|
||||
pullPolicy: IfNotPresent
|
||||
updateStrategy:
|
||||
type: RollingUpdate
|
||||
# If set to false, containers created by the localpv provisioner will run without extra privileges.
|
||||
privileged: true
|
||||
annotations: {}
|
||||
podAnnotations: {}
|
||||
## Labels to be added to localpv provisioner deployment pods
|
||||
podLabels:
|
||||
name: openebs-localpv-provisioner
|
||||
healthCheck:
|
||||
# Container port the provisioner serves its HTTP health endpoints on:
|
||||
# /healthz (liveness) and /readyz (readiness).
|
||||
port: 8081
|
||||
liveness:
|
||||
# Enable the liveness probe (httpGet /healthz).
|
||||
enabled: true
|
||||
# No. of failures the liveness probe will tolerate.
|
||||
failureThreshold: 3
|
||||
# No. of seconds of delay before checking the liveness status.
|
||||
initialDelaySeconds: 1
|
||||
# No. of seconds between liveness probe checks.
|
||||
periodSeconds: 30
|
||||
# No. of seconds of timeout tolerance.
|
||||
timeoutSeconds: 5
|
||||
readiness:
|
||||
# Enable the readiness probe (httpGet /readyz).
|
||||
enabled: true
|
||||
# No. of failures the readiness probe will tolerate.
|
||||
failureThreshold: 3
|
||||
# No. of seconds of delay before checking the readiness status.
|
||||
initialDelaySeconds: 1
|
||||
# No. of seconds between readiness probe checks.
|
||||
periodSeconds: 20
|
||||
# No. of seconds of timeout tolerance.
|
||||
timeoutSeconds: 5
|
||||
replicas: 1
|
||||
enableLeaderElection: true
|
||||
basePath: "/var/openebs/local"
|
||||
# Node deployment configuration for distributed provisioning mode
|
||||
nodeDeployment:
|
||||
# Enable the NodeDeployment mode. This deploys the provisioner as a DaemonSet on
|
||||
# cluster nodes. NodeDeployment avoids the need to spin up a HelperPod at volume
|
||||
# creation/deletion time, and instead performs volume operations via the DaemonSet
|
||||
# container.
|
||||
# NOTE: This mode mounts the host '/' path on to container, as it does not use a
|
||||
# HelperPod and must be able to cater to different BasePath paths.
|
||||
enabled: false
|
||||
# Additional volume mounts for the provisioner container
|
||||
additionalVolumeMounts: []
|
||||
# Additional volumes for the provisioner pod
|
||||
additionalVolumes: []
|
||||
# Enabling (setting to 'true') this option enables namespaced PVC tenants to be able
|
||||
# to set the BasePath cas-config value of their hostpath volume via PVC annotations.
|
||||
# It's reasonable to want to not allow the namespace tenant to decide this for
|
||||
# themselves, and to only allow setting BasePath via the StorageClass/default env
|
||||
# (at a cluster admin level). The default value 'false' does not allow namespace tenants
|
||||
# to set BasePath via PVC cas-config annotations.
|
||||
allowInsecurePvcBasePathOverride: false
|
||||
resources:
|
||||
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||
# choice for the user. This also increases chances charts run on environments with little
|
||||
# resources, such as Minikube. If you do want to specify resources, uncomment the following
|
||||
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
|
||||
# limits:
|
||||
# cpu: 100m
|
||||
# memory: 128Mi
|
||||
# requests:
|
||||
# cpu: 100m
|
||||
# memory: 128Mi
|
||||
nodeSelector: {}
|
||||
tolerations: []
|
||||
affinity: {}
|
||||
securityContext: {}
|
||||
## Sets priorityClassName in pod
|
||||
priorityClassName: ""
|
||||
|
||||
imagePullSecrets:
|
||||
# - name: img-pull-secret
|
||||
podSecurityContext: {}
|
||||
# fsGroup: 2000
|
||||
|
||||
nameOverride: ""
|
||||
fullnameOverride: ""
|
||||
|
||||
serviceAccount:
|
||||
# Specifies whether a service account should be created
|
||||
create: true
|
||||
# Annotations to add to the service account
|
||||
annotations: {}
|
||||
# The name of the service account to use.
|
||||
# If not set and create is true, a name is generated using the fullname template
|
||||
name:
|
||||
|
||||
hostpathClass:
|
||||
# Name of the default hostpath StorageClass
|
||||
name: openebs-hostpath
|
||||
# If true, enables creation of the openebs-hostpath StorageClass
|
||||
enabled: true
|
||||
# Available reclaim policies: Delete/Retain, defaults: Delete.
|
||||
reclaimPolicy: Delete
|
||||
# If true, sets the openebs-hostpath StorageClass as the default StorageClass
|
||||
isDefaultClass: false
|
||||
# Path on the host where local volumes of this storage class are mounted under.
|
||||
# NOTE: If not specified, this defaults to the value of localpv.basePath.
|
||||
basePath: ""
|
||||
# Custom node affinity label(s) for example "openebs.io/node-affinity-value"
|
||||
# that will be used instead of hostnames
|
||||
# This helps in cases where the hostname changes when the node is removed and
|
||||
# added back with the disks still intact.
|
||||
# Example:
|
||||
# nodeAffinityLabels:
|
||||
# - "openebs.io/node-affinity-key-1"
|
||||
# - "openebs.io/node-affinity-key-2"
|
||||
nodeAffinityLabels: []
|
||||
# Custom allowedTopologies for the openebs-hostpath StorageClass. Restricts the
|
||||
# set of nodes where volumes of this StorageClass may be provisioned/scheduled,
|
||||
# by matching node labels. See:
|
||||
# https://kubernetes.io/docs/concepts/storage/storage-classes/#allowed-topologies
|
||||
# Example:
|
||||
# allowedTopologies:
|
||||
# - matchLabelExpressions:
|
||||
# - key: kubernetes.io/hostname
|
||||
# values:
|
||||
# - worker-2
|
||||
# - worker-3
|
||||
allowedTopologies: []
|
||||
# Prerequisite: XFS Quota requires an XFS filesystem mounted with
|
||||
# the 'pquota' or 'prjquota' mount option.
|
||||
xfsQuota:
|
||||
# If true, enables XFS project quota
|
||||
enabled: false
|
||||
# Detailed configuration options for XFS project quota.
|
||||
# If XFS Quota is enabled with the default values, the usage limit
|
||||
# is set at the storage capacity specified in the PVC.
|
||||
softLimitGrace: "0%"
|
||||
hardLimitGrace: "0%"
|
||||
# Prerequisite: EXT4 Quota requires an EXT4 filesystem mounted with
|
||||
# the 'prjquota' mount option.
|
||||
ext4Quota:
|
||||
# If true, enables EXT4 project quota
|
||||
enabled: false
|
||||
# Detailed configuration options for EXT4 project quota.
|
||||
# If EXT4 Quota is enabled with the default values, the usage limit
|
||||
# is set at the storage capacity specified in the PVC.
|
||||
softLimitGrace: "0%"
|
||||
hardLimitGrace: "0%"
|
||||
|
||||
helperPod:
|
||||
image:
|
||||
registry: ""
|
||||
repository: openebs/linux-utils
|
||||
pullPolicy: IfNotPresent
|
||||
# Overrides the image tag whose default is the chart appVersion.
|
||||
tag: 4.6.0
|
||||
hostNetwork: false
|
||||
# The maximum number of seconds to wait for a helperPod (init, cleanup, quota) to complete before timing out.
|
||||
timeoutSecs: 120
|
||||
|
||||
# Additional labels to add to all chart resources
|
||||
extraLabels: {}
|
||||
|
||||
loggingLabels:
|
||||
openebs.io/logging: "true"
|
||||
|
||||
analytics:
|
||||
# Enable sending stats to Google Analytics
|
||||
enabled: true
|
||||
# Specify in hours the duration after which a ping event needs to be sent.
|
||||
pingInterval: "24h"
|
||||
@@ -0,0 +1,32 @@
|
||||
# Patterns to ignore when building packages.
|
||||
# This supports shell glob matching, relative path matching, and
|
||||
# negation (prefixed with !). Only one pattern per line.
|
||||
.DS_Store
|
||||
# Common VCS dirs
|
||||
.git/
|
||||
.gitignore
|
||||
.bzr/
|
||||
.bzrignore
|
||||
.hg/
|
||||
.hgignore
|
||||
.svn/
|
||||
|
||||
# Common backup files
|
||||
*.swp
|
||||
*.bak
|
||||
*.tmp
|
||||
*.orig
|
||||
*~
|
||||
|
||||
# Various IDEs
|
||||
.project
|
||||
.idea/
|
||||
*.tmproj
|
||||
.vscode/
|
||||
|
||||
# Other
|
||||
doc.yaml
|
||||
README.tpl
|
||||
README.md.gotmpl
|
||||
ci
|
||||
CHANGELOG.md
|
||||
@@ -0,0 +1,12 @@
|
||||
dependencies:
|
||||
- name: minio
|
||||
repository: https://charts.min.io/
|
||||
version: 5.4.0
|
||||
- name: grafana-agent-operator
|
||||
repository: https://grafana.github.io/helm-charts
|
||||
version: 0.5.1
|
||||
- name: rollout-operator
|
||||
repository: https://grafana.github.io/helm-charts
|
||||
version: 0.24.0
|
||||
digest: sha256:beb08aeb31a1fa6b88c326b307c9960ca5fc5032892f7acd5deae6b859884638
|
||||
generated: "2025-02-26T01:09:19.861074559Z"
|
||||
@@ -0,0 +1,32 @@
|
||||
apiVersion: v2
|
||||
appVersion: 3.4.2
|
||||
dependencies:
|
||||
- alias: minio
|
||||
condition: minio.enabled
|
||||
name: minio
|
||||
repository: https://charts.min.io/
|
||||
version: 5.4.0
|
||||
- alias: grafana-agent-operator
|
||||
condition: monitoring.selfMonitoring.grafanaAgent.installOperator
|
||||
name: grafana-agent-operator
|
||||
repository: https://grafana.github.io/helm-charts
|
||||
version: 0.5.1
|
||||
- alias: rollout_operator
|
||||
condition: rollout_operator.enabled
|
||||
name: rollout-operator
|
||||
repository: https://grafana.github.io/helm-charts
|
||||
version: 0.24.0
|
||||
description: Helm chart for Grafana Loki and Grafana Enterprise Logs supporting monolithic,
|
||||
simple scalable, and microservices modes.
|
||||
home: https://grafana.github.io/helm-charts
|
||||
icon: https://grafana.com/docs/loki/latest/logo_and_name.png
|
||||
maintainers:
|
||||
- name: trevorwhitney
|
||||
- name: jeschkies
|
||||
name: loki
|
||||
sources:
|
||||
- https://github.com/grafana/loki
|
||||
- https://grafana.com/oss/loki/
|
||||
- https://grafana.com/docs/loki/latest/
|
||||
type: application
|
||||
version: 6.29.0
|
||||
@@ -0,0 +1,84 @@
|
||||
.DEFAULT_GOAL := all
|
||||
.PHONY: lint lint-yaml install-distributed install-single-binary uninstall update-chart update
|
||||
|
||||
# Optional image override, example: make install-distributed IMAGE=grafana/loki:2.9.0
|
||||
IMAGE ?=
|
||||
|
||||
# Optional helm arguments, example: make install-distributed ARGS="--set loki.auth.enabled=true"
|
||||
ARGS ?=
|
||||
|
||||
# Default arguments to disable affinity for testing
|
||||
DEFAULT_ARGS = --set gateway.affinity=null \
|
||||
--set ingester.affinity=null \
|
||||
--set distributor.affinity=null \
|
||||
--set querier.affinity=null \
|
||||
--set queryFrontend.affinity=null \
|
||||
--set queryScheduler.affinity=null \
|
||||
--set indexGateway.affinity=null \
|
||||
--set compactor.affinity=null \
|
||||
--set ruler.affinity=null \
|
||||
--set backend.affinity=null \
|
||||
--set read.affinity=null \
|
||||
--set write.affinity=null \
|
||||
--set singleBinary.affinity=null \
|
||||
--set memcachedChunks.affinity=null \
|
||||
--set memcachedFrontend.affinity=null \
|
||||
--set memcachedIndexQueries.affinity=null \
|
||||
--set memcachedMetadata.affinity=null \
|
||||
--set memcachedResults.affinity=null \
|
||||
--set global.podAntiAffinity=null \
|
||||
--set global.podAntiAffinityTopologyKey=null
|
||||
|
||||
# Generate image override flag if IMAGE is provided
|
||||
IMAGE_FLAG = $(if $(IMAGE),\
|
||||
$(eval PARTS=$(subst :, ,$(IMAGE)))\
|
||||
$(eval REPO_PARTS=$(subst /, ,$(word 1,$(PARTS))))\
|
||||
$(eval TAG=$(word 2,$(PARTS)))\
|
||||
$(eval REPO_COUNT=$(words $(REPO_PARTS)))\
|
||||
$(if $(filter 3,$(REPO_COUNT)),\
|
||||
--set loki.image.registry=$(word 1,$(REPO_PARTS))/$(word 2,$(REPO_PARTS)) --set loki.image.repository=$(word 3,$(REPO_PARTS)),\
|
||||
--set loki.image.registry=$(word 1,$(REPO_PARTS)) --set loki.image.repository=$(word 2,$(REPO_PARTS))\
|
||||
) --set loki.image.tag=$(TAG),)
|
||||
|
||||
lint: lint-yaml
|
||||
|
||||
lint-yaml:
|
||||
yamllint -c $(CURDIR)/src/.yamllint.yaml $(CURDIR)/src
|
||||
|
||||
# Helm chart installation targets
|
||||
install-distributed:
|
||||
helm upgrade --install loki . \
|
||||
-f distributed-values.yaml \
|
||||
--create-namespace \
|
||||
--namespace loki \
|
||||
$(DEFAULT_ARGS) \
|
||||
$(IMAGE_FLAG) \
|
||||
$(ARGS)
|
||||
|
||||
install-single-binary:
|
||||
helm upgrade --install loki . \
|
||||
-f single-binary-values.yaml \
|
||||
--create-namespace \
|
||||
--namespace loki \
|
||||
$(DEFAULT_ARGS) \
|
||||
$(IMAGE_FLAG) \
|
||||
$(ARGS)
|
||||
|
||||
# Uninstall Loki helm release and optionally delete the namespace
|
||||
uninstall:
|
||||
helm uninstall loki --namespace loki
|
||||
kubectl delete namespace loki --ignore-not-found
|
||||
|
||||
# Update Helm chart dependencies
|
||||
update-chart:
|
||||
helm dependency update .
|
||||
|
||||
# Update existing installation with latest changes
|
||||
update:
|
||||
@if [ "$$(helm get values loki -n loki -o yaml | grep "deploymentMode: Distributed")" ]; then \
|
||||
echo "Updating distributed deployment..."; \
|
||||
helm upgrade loki . -f distributed-values.yaml --namespace loki $(DEFAULT_ARGS) $(IMAGE_FLAG) $(ARGS); \
|
||||
else \
|
||||
echo "Updating single binary deployment..."; \
|
||||
helm upgrade loki . -f single-binary-values.yaml --namespace loki $(DEFAULT_ARGS) $(IMAGE_FLAG) $(ARGS); \
|
||||
fi
|
||||
@@ -0,0 +1,65 @@
|
||||
# loki
|
||||
|
||||
  
|
||||
|
||||
Helm chart for Grafana Loki and Grafana Enterprise Logs supporting monolithic, simple scalable, and microservices modes.
|
||||
|
||||
## Source Code
|
||||
|
||||
* <https://github.com/grafana/loki>
|
||||
* <https://grafana.com/oss/loki/>
|
||||
* <https://grafana.com/docs/loki/latest/>
|
||||
|
||||
## Requirements
|
||||
|
||||
| Repository | Name | Version |
|
||||
|------------|------|---------|
|
||||
| https://charts.min.io/ | minio(minio) | 5.4.0 |
|
||||
| https://grafana.github.io/helm-charts | grafana-agent-operator(grafana-agent-operator) | 0.5.1 |
|
||||
| https://grafana.github.io/helm-charts | rollout_operator(rollout-operator) | 0.24.0 |
|
||||
|
||||
Find more information in the Loki Helm Chart [documentation](https://grafana.com/docs/loki/next/installation/helm).
|
||||
|
||||
## Contributing and releasing
|
||||
|
||||
If you made any changes to the [Chart.yaml](https://github.com/grafana/loki/blob/main/production/helm/loki/Chart.yaml) or [values.yaml](https://github.com/grafana/loki/blob/main/production/helm/loki/values.yaml) run `make helm-docs` from the root of the repository to update the documentation and commit the changed files.
|
||||
|
||||
Futhermore, please add an entry to the [CHANGELOG.md](./CHANGELOG.md) file about what you changed. This file has a header that looks like this:
|
||||
|
||||
```
|
||||
[//]: # (<AUTOMATED_UPDATES_LOCATOR> : do not remove this line. This locator is used by the CI pipeline to automatically create a changelog entry for each new Loki release. Add other chart versions and respective changelog entries bellow this line.)
|
||||
````
|
||||
|
||||
Place your changes as a bulleted list below this header. The helm chart is automatically released once a week, at which point the `CHANGELOG.md` file will be updated to reflect the release of all changes between this header the the header of the previous version as the changes for that weeks release. For example, if the weekly release will be `1.21.0`, and the `CHANGELOG.md` file has the following entries:
|
||||
|
||||
```
|
||||
[//]: # (<AUTOMATED_UPDATES_LOCATOR> : do not remove this line. This locator is used by the CI pipeline to automatically create a changelog entry for each new Loki release. Add other chart versions and respective changelog entries bellow this line.)
|
||||
|
||||
- [CHANGE] Changed the thing
|
||||
- [FEATURE] Cool new feature
|
||||
|
||||
## 1.20.0
|
||||
|
||||
- [BUGFIX] Fixed the bug
|
||||
```
|
||||
|
||||
Then the weekly release will create a `CHANGELOG.md` with the following content:
|
||||
```
|
||||
[//]: # (<AUTOMATED_UPDATES_LOCATOR> : do not remove this line. This locator is used by the CI pipeline to automatically create a changelog entry for each new Loki release. Add other chart versions and respective changelog entries bellow this line.)
|
||||
|
||||
## 1.21.0
|
||||
|
||||
- [CHANGE] Changed the thing
|
||||
- [FEATURE] Cool new feature
|
||||
|
||||
## 1.20.0
|
||||
|
||||
- [BUGFIX] Fixed the bug
|
||||
```
|
||||
|
||||
#### Versioning
|
||||
|
||||
Normally contributors need _not_ bump the version nor update the [CHANGELOG.md](https://github.com/grafana/loki/blob/main/production/helm/loki/CHANGELOG.md). A new version of the Chart will follow this cadence:
|
||||
- Automatic weekly releases
|
||||
- Releases that coincide with Loki/GEL releases
|
||||
- Manual releases when necessary (ie. to address a CVE or critical bug)
|
||||
@@ -0,0 +1,22 @@
|
||||
# Patterns to ignore when building packages.
|
||||
# This supports shell glob matching, relative path matching, and
|
||||
# negation (prefixed with !). Only one pattern per line.
|
||||
.DS_Store
|
||||
# Common VCS dirs
|
||||
.git/
|
||||
.gitignore
|
||||
.bzr/
|
||||
.bzrignore
|
||||
.hg/
|
||||
.hgignore
|
||||
.svn/
|
||||
# Common backup files
|
||||
*.swp
|
||||
*.bak
|
||||
*.tmp
|
||||
*~
|
||||
# Various IDEs
|
||||
.project
|
||||
.idea/
|
||||
*.tmproj
|
||||
.vscode/
|
||||
@@ -0,0 +1,13 @@
|
||||
apiVersion: v2
|
||||
appVersion: 0.44.2
|
||||
description: A Helm chart for Grafana Agent Operator
|
||||
home: https://grafana.com/docs/agent/v0.44/
|
||||
icon: https://raw.githubusercontent.com/grafana/agent/v0.44.2/docs/sources/assets/logo_and_name.png
|
||||
maintainers:
|
||||
- email: grafana-agent-team@googlegroups.com
|
||||
name: Grafana Agent Team
|
||||
name: grafana-agent-operator
|
||||
sources:
|
||||
- https://github.com/grafana/agent/tree/v0.44.2/static/operator
|
||||
type: application
|
||||
version: 0.5.1
|
||||
@@ -0,0 +1,82 @@
|
||||
# grafana-agent-operator
|
||||
|
||||
  
|
||||
|
||||
A Helm chart for Grafana Agent Operator
|
||||
|
||||
⚠️ **Please create issues relating to this Helm chart in the [Agent](https://github.com/grafana/agent/issues) repo.**
|
||||
|
||||
## Source Code
|
||||
|
||||
* <https://github.com/grafana/agent/tree/v0.44.2/static/operator>
|
||||
|
||||
Note that this chart does not provision custom resources like `GrafanaAgent` and `MetricsInstance` (formerly `PrometheusInstance`) or any `*Monitor` resources.
|
||||
|
||||
To learn how to deploy these resources, please see Grafana's [Agent Operator getting started guide](https://grafana.com/docs/agent/latest/operator/getting-started/).
|
||||
|
||||
## CRDs
|
||||
|
||||
The CRDs are synced into this chart manually (for now) from the Grafana Agent [GitHub repo](https://github.com/grafana/agent/tree/main/operations/agent-static-operator/crds). To learn more about how Helm manages CRDs, please see [Custom Resource Definitions](https://helm.sh/docs/chart_best_practices/custom_resource_definitions/) from the Helm docs.
|
||||
|
||||
## Get Repo Info
|
||||
|
||||
```console
|
||||
helm repo add grafana https://grafana.github.io/helm-charts
|
||||
helm repo update
|
||||
```
|
||||
|
||||
_See [helm repo](https://helm.sh/docs/helm/helm_repo/) for command documentation._
|
||||
|
||||
## Installing the Chart
|
||||
|
||||
To install the chart with the release name `my-release`:
|
||||
|
||||
```console
|
||||
helm install my-release grafana/grafana-agent-operator
|
||||
```
|
||||
|
||||
## Uninstalling the Chart
|
||||
|
||||
To uninstall/delete the my-release deployment:
|
||||
|
||||
```console
|
||||
helm delete my-release
|
||||
```
|
||||
|
||||
The command removes all the Kubernetes components associated with the chart and deletes the release.
|
||||
|
||||
## Upgrading an existing Release to a new major version
|
||||
|
||||
A major chart version change (like v1.2.3 -> v2.0.0) indicates that there is an incompatible breaking change needing manual actions. Until this chart's version reaches `v1.0`, there are no promises of backwards compatibility.
|
||||
|
||||
## Values
|
||||
|
||||
| Key | Type | Default | Description |
|
||||
|-----|------|---------|-------------|
|
||||
| affinity | object | `{}` | Pod affinity configuration |
|
||||
| annotations | object | `{}` | Annotations for the Deployment |
|
||||
| containerSecurityContext | object | `{}` | Container security context (allowPrivilegeEscalation, etc.) |
|
||||
| extraArgs | list | `[]` | List of additional cli arguments to configure agent-operator (example: `--log.level`) |
|
||||
| fullnameOverride | string | `""` | Overrides the chart's computed fullname |
|
||||
| global.commonLabels | object | `{}` | Common labels for all object directly managed by this chart. |
|
||||
| hostAliases | list | `[]` | hostAliases to add |
|
||||
| image.pullPolicy | string | `"IfNotPresent"` | Image pull policy |
|
||||
| image.pullSecrets | list | `[]` | Image pull secrets |
|
||||
| image.registry | string | `"docker.io"` | Image registry |
|
||||
| image.repository | string | `"grafana/agent-operator"` | Image repo |
|
||||
| image.tag | string | `"v0.44.2"` | Image tag |
|
||||
| kubeletService | object | `{"namespace":"default","serviceName":"kubelet"}` | If both are set, Agent Operator will create and maintain a service for scraping kubelets https://grafana.com/docs/agent/latest/operator/getting-started/#monitor-kubelets |
|
||||
| nameOverride | string | `""` | Overrides the chart's name |
|
||||
| nodeSelector | object | `{}` | nodeSelector configuration |
|
||||
| podAnnotations | object | `{}` | Annotations for the Deployment Pods |
|
||||
| podLabels | object | `{}` | Annotations for the Deployment Pods |
|
||||
| podSecurityContext | object | `{}` | Pod security context (runAsUser, etc.) |
|
||||
| rbac.create | bool | `true` | Toggle to create ClusterRole and ClusterRoleBinding |
|
||||
| rbac.podSecurityPolicyName | string | `""` | Name of a PodSecurityPolicy to use in the ClusterRole. If unset, no PodSecurityPolicy is used. |
|
||||
| resources | object | `{}` | Resource limits and requests config |
|
||||
| serviceAccount.create | bool | `true` | Toggle to create ServiceAccount |
|
||||
| serviceAccount.name | string | `nil` | Service account name |
|
||||
| test.image.registry | string | `"docker.io"` | Test image registry |
|
||||
| test.image.repository | string | `"library/busybox"` | Test image repo |
|
||||
| test.image.tag | string | `"latest"` | Test image tag |
|
||||
| tolerations | list | `[]` | Tolerations applied to Pods |
|
||||
@@ -0,0 +1,52 @@
|
||||
{{ template "chart.header" . }}
|
||||
|
||||
{{ template "chart.versionBadge" . }}{{ template "chart.typeBadge" . }}{{ template "chart.appVersionBadge" . }}
|
||||
|
||||
{{ template "chart.description" . }}
|
||||
|
||||
⚠️ **Please create issues relating to this Helm chart in the [Agent](https://github.com/grafana/agent/issues) repo.**
|
||||
|
||||
{{ template "chart.sourcesSection" . }}
|
||||
|
||||
{{ template "chart.requirementsSection" . }}
|
||||
|
||||
Note that this chart does not provision custom resources like `GrafanaAgent` and `MetricsInstance` (formerly `PrometheusInstance`) or any `*Monitor` resources.
|
||||
|
||||
To learn how to deploy these resources, please see Grafana's [Agent Operator getting started guide](https://grafana.com/docs/agent/latest/operator/getting-started/).
|
||||
|
||||
## CRDs
|
||||
|
||||
The CRDs are synced into this chart manually (for now) from the Grafana Agent [GitHub repo](https://github.com/grafana/agent/tree/main/operations/agent-static-operator/crds). To learn more about how Helm manages CRDs, please see [Custom Resource Definitions](https://helm.sh/docs/chart_best_practices/custom_resource_definitions/) from the Helm docs.
|
||||
|
||||
## Get Repo Info
|
||||
|
||||
```console
|
||||
helm repo add grafana https://grafana.github.io/helm-charts
|
||||
helm repo update
|
||||
```
|
||||
|
||||
_See [helm repo](https://helm.sh/docs/helm/helm_repo/) for command documentation._
|
||||
|
||||
## Installing the Chart
|
||||
|
||||
To install the chart with the release name `my-release`:
|
||||
|
||||
```console
|
||||
helm install my-release grafana/grafana-agent-operator
|
||||
```
|
||||
|
||||
## Uninstalling the Chart
|
||||
|
||||
To uninstall/delete the my-release deployment:
|
||||
|
||||
```console
|
||||
helm delete my-release
|
||||
```
|
||||
|
||||
The command removes all the Kubernetes components associated with the chart and deletes the release.
|
||||
|
||||
## Upgrading an existing Release to a new major version
|
||||
|
||||
A major chart version change (like v1.2.3 -> v2.0.0) indicates that there is an incompatible breaking change needing manual actions. Until this chart's version reaches `v1.0`, there are no promises of backwards compatibility.
|
||||
|
||||
{{ template "chart.valuesSection" . }}
|
||||
+424
@@ -0,0 +1,424 @@
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
kind: CustomResourceDefinition
|
||||
metadata:
|
||||
annotations:
|
||||
controller-gen.kubebuilder.io/version: v0.9.2
|
||||
creationTimestamp: null
|
||||
name: podmonitors.monitoring.coreos.com
|
||||
spec:
|
||||
group: monitoring.coreos.com
|
||||
names:
|
||||
categories:
|
||||
- prometheus-operator
|
||||
kind: PodMonitor
|
||||
listKind: PodMonitorList
|
||||
plural: podmonitors
|
||||
shortNames:
|
||||
- pmon
|
||||
singular: podmonitor
|
||||
scope: Namespaced
|
||||
versions:
|
||||
- name: v1
|
||||
schema:
|
||||
openAPIV3Schema:
|
||||
properties:
|
||||
apiVersion:
|
||||
type: string
|
||||
kind:
|
||||
type: string
|
||||
metadata:
|
||||
type: object
|
||||
spec:
|
||||
properties:
|
||||
attachMetadata:
|
||||
properties:
|
||||
node:
|
||||
type: boolean
|
||||
type: object
|
||||
jobLabel:
|
||||
type: string
|
||||
labelLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
labelNameLengthLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
labelValueLengthLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
namespaceSelector:
|
||||
properties:
|
||||
any:
|
||||
type: boolean
|
||||
matchNames:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
type: object
|
||||
podMetricsEndpoints:
|
||||
items:
|
||||
properties:
|
||||
authorization:
|
||||
properties:
|
||||
credentials:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type:
|
||||
type: string
|
||||
type: object
|
||||
basicAuth:
|
||||
properties:
|
||||
password:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
username:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
bearerTokenSecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
enableHttp2:
|
||||
type: boolean
|
||||
filterRunning:
|
||||
type: boolean
|
||||
followRedirects:
|
||||
type: boolean
|
||||
honorLabels:
|
||||
type: boolean
|
||||
honorTimestamps:
|
||||
type: boolean
|
||||
interval:
|
||||
pattern: ^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
|
||||
type: string
|
||||
metricRelabelings:
|
||||
items:
|
||||
properties:
|
||||
action:
|
||||
default: replace
|
||||
enum:
|
||||
- replace
|
||||
- Replace
|
||||
- keep
|
||||
- Keep
|
||||
- drop
|
||||
- Drop
|
||||
- hashmod
|
||||
- HashMod
|
||||
- labelmap
|
||||
- LabelMap
|
||||
- labeldrop
|
||||
- LabelDrop
|
||||
- labelkeep
|
||||
- LabelKeep
|
||||
- lowercase
|
||||
- Lowercase
|
||||
- uppercase
|
||||
- Uppercase
|
||||
- keepequal
|
||||
- KeepEqual
|
||||
- dropequal
|
||||
- DropEqual
|
||||
type: string
|
||||
modulus:
|
||||
format: int64
|
||||
type: integer
|
||||
regex:
|
||||
type: string
|
||||
replacement:
|
||||
type: string
|
||||
separator:
|
||||
type: string
|
||||
sourceLabels:
|
||||
items:
|
||||
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
|
||||
type: string
|
||||
type: array
|
||||
targetLabel:
|
||||
type: string
|
||||
type: object
|
||||
type: array
|
||||
oauth2:
|
||||
properties:
|
||||
clientId:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
clientSecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
endpointParams:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
scopes:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
tokenUrl:
|
||||
minLength: 1
|
||||
type: string
|
||||
required:
|
||||
- clientId
|
||||
- clientSecret
|
||||
- tokenUrl
|
||||
type: object
|
||||
params:
|
||||
additionalProperties:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
type: object
|
||||
path:
|
||||
type: string
|
||||
port:
|
||||
type: string
|
||||
proxyUrl:
|
||||
type: string
|
||||
relabelings:
|
||||
items:
|
||||
properties:
|
||||
action:
|
||||
default: replace
|
||||
enum:
|
||||
- replace
|
||||
- Replace
|
||||
- keep
|
||||
- Keep
|
||||
- drop
|
||||
- Drop
|
||||
- hashmod
|
||||
- HashMod
|
||||
- labelmap
|
||||
- LabelMap
|
||||
- labeldrop
|
||||
- LabelDrop
|
||||
- labelkeep
|
||||
- LabelKeep
|
||||
- lowercase
|
||||
- Lowercase
|
||||
- uppercase
|
||||
- Uppercase
|
||||
- keepequal
|
||||
- KeepEqual
|
||||
- dropequal
|
||||
- DropEqual
|
||||
type: string
|
||||
modulus:
|
||||
format: int64
|
||||
type: integer
|
||||
regex:
|
||||
type: string
|
||||
replacement:
|
||||
type: string
|
||||
separator:
|
||||
type: string
|
||||
sourceLabels:
|
||||
items:
|
||||
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
|
||||
type: string
|
||||
type: array
|
||||
targetLabel:
|
||||
type: string
|
||||
type: object
|
||||
type: array
|
||||
scheme:
|
||||
enum:
|
||||
- http
|
||||
- https
|
||||
type: string
|
||||
scrapeTimeout:
|
||||
pattern: ^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
|
||||
type: string
|
||||
targetPort:
|
||||
anyOf:
|
||||
- type: integer
|
||||
- type: string
|
||||
x-kubernetes-int-or-string: true
|
||||
tlsConfig:
|
||||
properties:
|
||||
ca:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
cert:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
insecureSkipVerify:
|
||||
type: boolean
|
||||
keySecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
serverName:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
type: array
|
||||
podTargetLabels:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
sampleLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
selector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
targetLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
required:
|
||||
- podMetricsEndpoints
|
||||
- selector
|
||||
type: object
|
||||
required:
|
||||
- spec
|
||||
type: object
|
||||
served: true
|
||||
storage: true
|
||||
@@ -0,0 +1,458 @@
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
kind: CustomResourceDefinition
|
||||
metadata:
|
||||
annotations:
|
||||
controller-gen.kubebuilder.io/version: v0.9.2
|
||||
creationTimestamp: null
|
||||
name: probes.monitoring.coreos.com
|
||||
spec:
|
||||
group: monitoring.coreos.com
|
||||
names:
|
||||
categories:
|
||||
- prometheus-operator
|
||||
kind: Probe
|
||||
listKind: ProbeList
|
||||
plural: probes
|
||||
shortNames:
|
||||
- prb
|
||||
singular: probe
|
||||
scope: Namespaced
|
||||
versions:
|
||||
- name: v1
|
||||
schema:
|
||||
openAPIV3Schema:
|
||||
properties:
|
||||
apiVersion:
|
||||
type: string
|
||||
kind:
|
||||
type: string
|
||||
metadata:
|
||||
type: object
|
||||
spec:
|
||||
properties:
|
||||
authorization:
|
||||
properties:
|
||||
credentials:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type:
|
||||
type: string
|
||||
type: object
|
||||
basicAuth:
|
||||
properties:
|
||||
password:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
username:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
bearerTokenSecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
interval:
|
||||
pattern: ^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
|
||||
type: string
|
||||
jobName:
|
||||
type: string
|
||||
labelLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
labelNameLengthLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
labelValueLengthLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
metricRelabelings:
|
||||
items:
|
||||
properties:
|
||||
action:
|
||||
default: replace
|
||||
enum:
|
||||
- replace
|
||||
- Replace
|
||||
- keep
|
||||
- Keep
|
||||
- drop
|
||||
- Drop
|
||||
- hashmod
|
||||
- HashMod
|
||||
- labelmap
|
||||
- LabelMap
|
||||
- labeldrop
|
||||
- LabelDrop
|
||||
- labelkeep
|
||||
- LabelKeep
|
||||
- lowercase
|
||||
- Lowercase
|
||||
- uppercase
|
||||
- Uppercase
|
||||
- keepequal
|
||||
- KeepEqual
|
||||
- dropequal
|
||||
- DropEqual
|
||||
type: string
|
||||
modulus:
|
||||
format: int64
|
||||
type: integer
|
||||
regex:
|
||||
type: string
|
||||
replacement:
|
||||
type: string
|
||||
separator:
|
||||
type: string
|
||||
sourceLabels:
|
||||
items:
|
||||
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
|
||||
type: string
|
||||
type: array
|
||||
targetLabel:
|
||||
type: string
|
||||
type: object
|
||||
type: array
|
||||
module:
|
||||
type: string
|
||||
oauth2:
|
||||
properties:
|
||||
clientId:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
clientSecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
endpointParams:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
scopes:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
tokenUrl:
|
||||
minLength: 1
|
||||
type: string
|
||||
required:
|
||||
- clientId
|
||||
- clientSecret
|
||||
- tokenUrl
|
||||
type: object
|
||||
prober:
|
||||
properties:
|
||||
path:
|
||||
default: /probe
|
||||
type: string
|
||||
proxyUrl:
|
||||
type: string
|
||||
scheme:
|
||||
enum:
|
||||
- http
|
||||
- https
|
||||
type: string
|
||||
url:
|
||||
type: string
|
||||
required:
|
||||
- url
|
||||
type: object
|
||||
sampleLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
scrapeTimeout:
|
||||
pattern: ^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
|
||||
type: string
|
||||
targetLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
targets:
|
||||
properties:
|
||||
ingress:
|
||||
properties:
|
||||
namespaceSelector:
|
||||
properties:
|
||||
any:
|
||||
type: boolean
|
||||
matchNames:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
type: object
|
||||
relabelingConfigs:
|
||||
items:
|
||||
properties:
|
||||
action:
|
||||
default: replace
|
||||
enum:
|
||||
- replace
|
||||
- Replace
|
||||
- keep
|
||||
- Keep
|
||||
- drop
|
||||
- Drop
|
||||
- hashmod
|
||||
- HashMod
|
||||
- labelmap
|
||||
- LabelMap
|
||||
- labeldrop
|
||||
- LabelDrop
|
||||
- labelkeep
|
||||
- LabelKeep
|
||||
- lowercase
|
||||
- Lowercase
|
||||
- uppercase
|
||||
- Uppercase
|
||||
- keepequal
|
||||
- KeepEqual
|
||||
- dropequal
|
||||
- DropEqual
|
||||
type: string
|
||||
modulus:
|
||||
format: int64
|
||||
type: integer
|
||||
regex:
|
||||
type: string
|
||||
replacement:
|
||||
type: string
|
||||
separator:
|
||||
type: string
|
||||
sourceLabels:
|
||||
items:
|
||||
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
|
||||
type: string
|
||||
type: array
|
||||
targetLabel:
|
||||
type: string
|
||||
type: object
|
||||
type: array
|
||||
selector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
staticConfig:
|
||||
properties:
|
||||
labels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
relabelingConfigs:
|
||||
items:
|
||||
properties:
|
||||
action:
|
||||
default: replace
|
||||
enum:
|
||||
- replace
|
||||
- Replace
|
||||
- keep
|
||||
- Keep
|
||||
- drop
|
||||
- Drop
|
||||
- hashmod
|
||||
- HashMod
|
||||
- labelmap
|
||||
- LabelMap
|
||||
- labeldrop
|
||||
- LabelDrop
|
||||
- labelkeep
|
||||
- LabelKeep
|
||||
- lowercase
|
||||
- Lowercase
|
||||
- uppercase
|
||||
- Uppercase
|
||||
- keepequal
|
||||
- KeepEqual
|
||||
- dropequal
|
||||
- DropEqual
|
||||
type: string
|
||||
modulus:
|
||||
format: int64
|
||||
type: integer
|
||||
regex:
|
||||
type: string
|
||||
replacement:
|
||||
type: string
|
||||
separator:
|
||||
type: string
|
||||
sourceLabels:
|
||||
items:
|
||||
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
|
||||
type: string
|
||||
type: array
|
||||
targetLabel:
|
||||
type: string
|
||||
type: object
|
||||
type: array
|
||||
static:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
type: object
|
||||
type: object
|
||||
tlsConfig:
|
||||
properties:
|
||||
ca:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
cert:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
insecureSkipVerify:
|
||||
type: boolean
|
||||
keySecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
serverName:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
required:
|
||||
- spec
|
||||
type: object
|
||||
served: true
|
||||
storage: true
|
||||
+436
@@ -0,0 +1,436 @@
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
kind: CustomResourceDefinition
|
||||
metadata:
|
||||
annotations:
|
||||
controller-gen.kubebuilder.io/version: v0.9.2
|
||||
creationTimestamp: null
|
||||
name: servicemonitors.monitoring.coreos.com
|
||||
spec:
|
||||
group: monitoring.coreos.com
|
||||
names:
|
||||
categories:
|
||||
- prometheus-operator
|
||||
kind: ServiceMonitor
|
||||
listKind: ServiceMonitorList
|
||||
plural: servicemonitors
|
||||
shortNames:
|
||||
- smon
|
||||
singular: servicemonitor
|
||||
scope: Namespaced
|
||||
versions:
|
||||
- name: v1
|
||||
schema:
|
||||
openAPIV3Schema:
|
||||
properties:
|
||||
apiVersion:
|
||||
type: string
|
||||
kind:
|
||||
type: string
|
||||
metadata:
|
||||
type: object
|
||||
spec:
|
||||
properties:
|
||||
attachMetadata:
|
||||
properties:
|
||||
node:
|
||||
type: boolean
|
||||
type: object
|
||||
endpoints:
|
||||
items:
|
||||
properties:
|
||||
authorization:
|
||||
properties:
|
||||
credentials:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type:
|
||||
type: string
|
||||
type: object
|
||||
basicAuth:
|
||||
properties:
|
||||
password:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
username:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
bearerTokenFile:
|
||||
type: string
|
||||
bearerTokenSecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
enableHttp2:
|
||||
type: boolean
|
||||
filterRunning:
|
||||
type: boolean
|
||||
followRedirects:
|
||||
type: boolean
|
||||
honorLabels:
|
||||
type: boolean
|
||||
honorTimestamps:
|
||||
type: boolean
|
||||
interval:
|
||||
pattern: ^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
|
||||
type: string
|
||||
metricRelabelings:
|
||||
items:
|
||||
properties:
|
||||
action:
|
||||
default: replace
|
||||
enum:
|
||||
- replace
|
||||
- Replace
|
||||
- keep
|
||||
- Keep
|
||||
- drop
|
||||
- Drop
|
||||
- hashmod
|
||||
- HashMod
|
||||
- labelmap
|
||||
- LabelMap
|
||||
- labeldrop
|
||||
- LabelDrop
|
||||
- labelkeep
|
||||
- LabelKeep
|
||||
- lowercase
|
||||
- Lowercase
|
||||
- uppercase
|
||||
- Uppercase
|
||||
- keepequal
|
||||
- KeepEqual
|
||||
- dropequal
|
||||
- DropEqual
|
||||
type: string
|
||||
modulus:
|
||||
format: int64
|
||||
type: integer
|
||||
regex:
|
||||
type: string
|
||||
replacement:
|
||||
type: string
|
||||
separator:
|
||||
type: string
|
||||
sourceLabels:
|
||||
items:
|
||||
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
|
||||
type: string
|
||||
type: array
|
||||
targetLabel:
|
||||
type: string
|
||||
type: object
|
||||
type: array
|
||||
oauth2:
|
||||
properties:
|
||||
clientId:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
clientSecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
endpointParams:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
scopes:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
tokenUrl:
|
||||
minLength: 1
|
||||
type: string
|
||||
required:
|
||||
- clientId
|
||||
- clientSecret
|
||||
- tokenUrl
|
||||
type: object
|
||||
params:
|
||||
additionalProperties:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
type: object
|
||||
path:
|
||||
type: string
|
||||
port:
|
||||
type: string
|
||||
proxyUrl:
|
||||
type: string
|
||||
relabelings:
|
||||
items:
|
||||
properties:
|
||||
action:
|
||||
default: replace
|
||||
enum:
|
||||
- replace
|
||||
- Replace
|
||||
- keep
|
||||
- Keep
|
||||
- drop
|
||||
- Drop
|
||||
- hashmod
|
||||
- HashMod
|
||||
- labelmap
|
||||
- LabelMap
|
||||
- labeldrop
|
||||
- LabelDrop
|
||||
- labelkeep
|
||||
- LabelKeep
|
||||
- lowercase
|
||||
- Lowercase
|
||||
- uppercase
|
||||
- Uppercase
|
||||
- keepequal
|
||||
- KeepEqual
|
||||
- dropequal
|
||||
- DropEqual
|
||||
type: string
|
||||
modulus:
|
||||
format: int64
|
||||
type: integer
|
||||
regex:
|
||||
type: string
|
||||
replacement:
|
||||
type: string
|
||||
separator:
|
||||
type: string
|
||||
sourceLabels:
|
||||
items:
|
||||
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
|
||||
type: string
|
||||
type: array
|
||||
targetLabel:
|
||||
type: string
|
||||
type: object
|
||||
type: array
|
||||
scheme:
|
||||
enum:
|
||||
- http
|
||||
- https
|
||||
type: string
|
||||
scrapeTimeout:
|
||||
pattern: ^(0|(([0-9]+)y)?(([0-9]+)w)?(([0-9]+)d)?(([0-9]+)h)?(([0-9]+)m)?(([0-9]+)s)?(([0-9]+)ms)?)$
|
||||
type: string
|
||||
targetPort:
|
||||
anyOf:
|
||||
- type: integer
|
||||
- type: string
|
||||
x-kubernetes-int-or-string: true
|
||||
tlsConfig:
|
||||
properties:
|
||||
ca:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
caFile:
|
||||
type: string
|
||||
cert:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
certFile:
|
||||
type: string
|
||||
insecureSkipVerify:
|
||||
type: boolean
|
||||
keyFile:
|
||||
type: string
|
||||
keySecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
serverName:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
type: array
|
||||
jobLabel:
|
||||
type: string
|
||||
labelLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
labelNameLengthLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
labelValueLengthLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
namespaceSelector:
|
||||
properties:
|
||||
any:
|
||||
type: boolean
|
||||
matchNames:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
type: object
|
||||
podTargetLabels:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
sampleLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
selector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
targetLabels:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
targetLimit:
|
||||
format: int64
|
||||
type: integer
|
||||
required:
|
||||
- endpoints
|
||||
- selector
|
||||
type: object
|
||||
required:
|
||||
- spec
|
||||
type: object
|
||||
served: true
|
||||
storage: true
|
||||
+3711
File diff suppressed because it is too large
Load Diff
+810
@@ -0,0 +1,810 @@
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
kind: CustomResourceDefinition
|
||||
metadata:
|
||||
annotations:
|
||||
controller-gen.kubebuilder.io/version: v0.9.2
|
||||
creationTimestamp: null
|
||||
name: integrations.monitoring.grafana.com
|
||||
spec:
|
||||
group: monitoring.grafana.com
|
||||
names:
|
||||
categories:
|
||||
- agent-operator
|
||||
kind: Integration
|
||||
listKind: IntegrationList
|
||||
plural: integrations
|
||||
singular: integration
|
||||
scope: Namespaced
|
||||
versions:
|
||||
- name: v1alpha1
|
||||
schema:
|
||||
openAPIV3Schema:
|
||||
properties:
|
||||
apiVersion:
|
||||
type: string
|
||||
kind:
|
||||
type: string
|
||||
metadata:
|
||||
type: object
|
||||
spec:
|
||||
properties:
|
||||
config:
|
||||
type: object
|
||||
x-kubernetes-preserve-unknown-fields: true
|
||||
configMaps:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: array
|
||||
name:
|
||||
type: string
|
||||
secrets:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: array
|
||||
type:
|
||||
properties:
|
||||
allNodes:
|
||||
type: boolean
|
||||
unique:
|
||||
type: boolean
|
||||
type: object
|
||||
volumeMounts:
|
||||
items:
|
||||
properties:
|
||||
mountPath:
|
||||
type: string
|
||||
mountPropagation:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
subPath:
|
||||
type: string
|
||||
subPathExpr:
|
||||
type: string
|
||||
required:
|
||||
- mountPath
|
||||
- name
|
||||
type: object
|
||||
type: array
|
||||
volumes:
|
||||
items:
|
||||
properties:
|
||||
awsElasticBlockStore:
|
||||
properties:
|
||||
fsType:
|
||||
type: string
|
||||
partition:
|
||||
format: int32
|
||||
type: integer
|
||||
readOnly:
|
||||
type: boolean
|
||||
volumeID:
|
||||
type: string
|
||||
required:
|
||||
- volumeID
|
||||
type: object
|
||||
azureDisk:
|
||||
properties:
|
||||
cachingMode:
|
||||
type: string
|
||||
diskName:
|
||||
type: string
|
||||
diskURI:
|
||||
type: string
|
||||
fsType:
|
||||
type: string
|
||||
kind:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
required:
|
||||
- diskName
|
||||
- diskURI
|
||||
type: object
|
||||
azureFile:
|
||||
properties:
|
||||
readOnly:
|
||||
type: boolean
|
||||
secretName:
|
||||
type: string
|
||||
shareName:
|
||||
type: string
|
||||
required:
|
||||
- secretName
|
||||
- shareName
|
||||
type: object
|
||||
cephfs:
|
||||
properties:
|
||||
monitors:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
path:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
secretFile:
|
||||
type: string
|
||||
secretRef:
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
user:
|
||||
type: string
|
||||
required:
|
||||
- monitors
|
||||
type: object
|
||||
cinder:
|
||||
properties:
|
||||
fsType:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
secretRef:
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
volumeID:
|
||||
type: string
|
||||
required:
|
||||
- volumeID
|
||||
type: object
|
||||
configMap:
|
||||
properties:
|
||||
defaultMode:
|
||||
format: int32
|
||||
type: integer
|
||||
items:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
mode:
|
||||
format: int32
|
||||
type: integer
|
||||
path:
|
||||
type: string
|
||||
required:
|
||||
- key
|
||||
- path
|
||||
type: object
|
||||
type: array
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
csi:
|
||||
properties:
|
||||
driver:
|
||||
type: string
|
||||
fsType:
|
||||
type: string
|
||||
nodePublishSecretRef:
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
readOnly:
|
||||
type: boolean
|
||||
volumeAttributes:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
required:
|
||||
- driver
|
||||
type: object
|
||||
downwardAPI:
|
||||
properties:
|
||||
defaultMode:
|
||||
format: int32
|
||||
type: integer
|
||||
items:
|
||||
items:
|
||||
properties:
|
||||
fieldRef:
|
||||
properties:
|
||||
apiVersion:
|
||||
type: string
|
||||
fieldPath:
|
||||
type: string
|
||||
required:
|
||||
- fieldPath
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
mode:
|
||||
format: int32
|
||||
type: integer
|
||||
path:
|
||||
type: string
|
||||
resourceFieldRef:
|
||||
properties:
|
||||
containerName:
|
||||
type: string
|
||||
divisor:
|
||||
anyOf:
|
||||
- type: integer
|
||||
- type: string
|
||||
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
|
||||
x-kubernetes-int-or-string: true
|
||||
resource:
|
||||
type: string
|
||||
required:
|
||||
- resource
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
required:
|
||||
- path
|
||||
type: object
|
||||
type: array
|
||||
type: object
|
||||
emptyDir:
|
||||
properties:
|
||||
medium:
|
||||
type: string
|
||||
sizeLimit:
|
||||
anyOf:
|
||||
- type: integer
|
||||
- type: string
|
||||
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
|
||||
x-kubernetes-int-or-string: true
|
||||
type: object
|
||||
ephemeral:
|
||||
properties:
|
||||
volumeClaimTemplate:
|
||||
properties:
|
||||
metadata:
|
||||
type: object
|
||||
spec:
|
||||
properties:
|
||||
accessModes:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
dataSource:
|
||||
properties:
|
||||
apiGroup:
|
||||
type: string
|
||||
kind:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
required:
|
||||
- kind
|
||||
- name
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
dataSourceRef:
|
||||
properties:
|
||||
apiGroup:
|
||||
type: string
|
||||
kind:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
namespace:
|
||||
type: string
|
||||
required:
|
||||
- kind
|
||||
- name
|
||||
type: object
|
||||
resources:
|
||||
properties:
|
||||
claims:
|
||||
items:
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
required:
|
||||
- name
|
||||
type: object
|
||||
type: array
|
||||
x-kubernetes-list-map-keys:
|
||||
- name
|
||||
x-kubernetes-list-type: map
|
||||
limits:
|
||||
additionalProperties:
|
||||
anyOf:
|
||||
- type: integer
|
||||
- type: string
|
||||
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
|
||||
x-kubernetes-int-or-string: true
|
||||
type: object
|
||||
requests:
|
||||
additionalProperties:
|
||||
anyOf:
|
||||
- type: integer
|
||||
- type: string
|
||||
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
|
||||
x-kubernetes-int-or-string: true
|
||||
type: object
|
||||
type: object
|
||||
selector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
storageClassName:
|
||||
type: string
|
||||
volumeMode:
|
||||
type: string
|
||||
volumeName:
|
||||
type: string
|
||||
type: object
|
||||
required:
|
||||
- spec
|
||||
type: object
|
||||
type: object
|
||||
fc:
|
||||
properties:
|
||||
fsType:
|
||||
type: string
|
||||
lun:
|
||||
format: int32
|
||||
type: integer
|
||||
readOnly:
|
||||
type: boolean
|
||||
targetWWNs:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
wwids:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
type: object
|
||||
flexVolume:
|
||||
properties:
|
||||
driver:
|
||||
type: string
|
||||
fsType:
|
||||
type: string
|
||||
options:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
readOnly:
|
||||
type: boolean
|
||||
secretRef:
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
required:
|
||||
- driver
|
||||
type: object
|
||||
flocker:
|
||||
properties:
|
||||
datasetName:
|
||||
type: string
|
||||
datasetUUID:
|
||||
type: string
|
||||
type: object
|
||||
gcePersistentDisk:
|
||||
properties:
|
||||
fsType:
|
||||
type: string
|
||||
partition:
|
||||
format: int32
|
||||
type: integer
|
||||
pdName:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
required:
|
||||
- pdName
|
||||
type: object
|
||||
gitRepo:
|
||||
properties:
|
||||
directory:
|
||||
type: string
|
||||
repository:
|
||||
type: string
|
||||
revision:
|
||||
type: string
|
||||
required:
|
||||
- repository
|
||||
type: object
|
||||
glusterfs:
|
||||
properties:
|
||||
endpoints:
|
||||
type: string
|
||||
path:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
required:
|
||||
- endpoints
|
||||
- path
|
||||
type: object
|
||||
hostPath:
|
||||
properties:
|
||||
path:
|
||||
type: string
|
||||
type:
|
||||
type: string
|
||||
required:
|
||||
- path
|
||||
type: object
|
||||
iscsi:
|
||||
properties:
|
||||
chapAuthDiscovery:
|
||||
type: boolean
|
||||
chapAuthSession:
|
||||
type: boolean
|
||||
fsType:
|
||||
type: string
|
||||
initiatorName:
|
||||
type: string
|
||||
iqn:
|
||||
type: string
|
||||
iscsiInterface:
|
||||
type: string
|
||||
lun:
|
||||
format: int32
|
||||
type: integer
|
||||
portals:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
readOnly:
|
||||
type: boolean
|
||||
secretRef:
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
targetPortal:
|
||||
type: string
|
||||
required:
|
||||
- iqn
|
||||
- lun
|
||||
- targetPortal
|
||||
type: object
|
||||
name:
|
||||
type: string
|
||||
nfs:
|
||||
properties:
|
||||
path:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
server:
|
||||
type: string
|
||||
required:
|
||||
- path
|
||||
- server
|
||||
type: object
|
||||
persistentVolumeClaim:
|
||||
properties:
|
||||
claimName:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
required:
|
||||
- claimName
|
||||
type: object
|
||||
photonPersistentDisk:
|
||||
properties:
|
||||
fsType:
|
||||
type: string
|
||||
pdID:
|
||||
type: string
|
||||
required:
|
||||
- pdID
|
||||
type: object
|
||||
portworxVolume:
|
||||
properties:
|
||||
fsType:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
volumeID:
|
||||
type: string
|
||||
required:
|
||||
- volumeID
|
||||
type: object
|
||||
projected:
|
||||
properties:
|
||||
defaultMode:
|
||||
format: int32
|
||||
type: integer
|
||||
sources:
|
||||
items:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
items:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
mode:
|
||||
format: int32
|
||||
type: integer
|
||||
path:
|
||||
type: string
|
||||
required:
|
||||
- key
|
||||
- path
|
||||
type: object
|
||||
type: array
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
downwardAPI:
|
||||
properties:
|
||||
items:
|
||||
items:
|
||||
properties:
|
||||
fieldRef:
|
||||
properties:
|
||||
apiVersion:
|
||||
type: string
|
||||
fieldPath:
|
||||
type: string
|
||||
required:
|
||||
- fieldPath
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
mode:
|
||||
format: int32
|
||||
type: integer
|
||||
path:
|
||||
type: string
|
||||
resourceFieldRef:
|
||||
properties:
|
||||
containerName:
|
||||
type: string
|
||||
divisor:
|
||||
anyOf:
|
||||
- type: integer
|
||||
- type: string
|
||||
pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$
|
||||
x-kubernetes-int-or-string: true
|
||||
resource:
|
||||
type: string
|
||||
required:
|
||||
- resource
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
required:
|
||||
- path
|
||||
type: object
|
||||
type: array
|
||||
type: object
|
||||
secret:
|
||||
properties:
|
||||
items:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
mode:
|
||||
format: int32
|
||||
type: integer
|
||||
path:
|
||||
type: string
|
||||
required:
|
||||
- key
|
||||
- path
|
||||
type: object
|
||||
type: array
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
serviceAccountToken:
|
||||
properties:
|
||||
audience:
|
||||
type: string
|
||||
expirationSeconds:
|
||||
format: int64
|
||||
type: integer
|
||||
path:
|
||||
type: string
|
||||
required:
|
||||
- path
|
||||
type: object
|
||||
type: object
|
||||
type: array
|
||||
type: object
|
||||
quobyte:
|
||||
properties:
|
||||
group:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
registry:
|
||||
type: string
|
||||
tenant:
|
||||
type: string
|
||||
user:
|
||||
type: string
|
||||
volume:
|
||||
type: string
|
||||
required:
|
||||
- registry
|
||||
- volume
|
||||
type: object
|
||||
rbd:
|
||||
properties:
|
||||
fsType:
|
||||
type: string
|
||||
image:
|
||||
type: string
|
||||
keyring:
|
||||
type: string
|
||||
monitors:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
pool:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
secretRef:
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
user:
|
||||
type: string
|
||||
required:
|
||||
- image
|
||||
- monitors
|
||||
type: object
|
||||
scaleIO:
|
||||
properties:
|
||||
fsType:
|
||||
type: string
|
||||
gateway:
|
||||
type: string
|
||||
protectionDomain:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
secretRef:
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
sslEnabled:
|
||||
type: boolean
|
||||
storageMode:
|
||||
type: string
|
||||
storagePool:
|
||||
type: string
|
||||
system:
|
||||
type: string
|
||||
volumeName:
|
||||
type: string
|
||||
required:
|
||||
- gateway
|
||||
- secretRef
|
||||
- system
|
||||
type: object
|
||||
secret:
|
||||
properties:
|
||||
defaultMode:
|
||||
format: int32
|
||||
type: integer
|
||||
items:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
mode:
|
||||
format: int32
|
||||
type: integer
|
||||
path:
|
||||
type: string
|
||||
required:
|
||||
- key
|
||||
- path
|
||||
type: object
|
||||
type: array
|
||||
optional:
|
||||
type: boolean
|
||||
secretName:
|
||||
type: string
|
||||
type: object
|
||||
storageos:
|
||||
properties:
|
||||
fsType:
|
||||
type: string
|
||||
readOnly:
|
||||
type: boolean
|
||||
secretRef:
|
||||
properties:
|
||||
name:
|
||||
type: string
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
volumeName:
|
||||
type: string
|
||||
volumeNamespace:
|
||||
type: string
|
||||
type: object
|
||||
vsphereVolume:
|
||||
properties:
|
||||
fsType:
|
||||
type: string
|
||||
storagePolicyID:
|
||||
type: string
|
||||
storagePolicyName:
|
||||
type: string
|
||||
volumePath:
|
||||
type: string
|
||||
required:
|
||||
- volumePath
|
||||
type: object
|
||||
required:
|
||||
- name
|
||||
type: object
|
||||
type: array
|
||||
required:
|
||||
- config
|
||||
- name
|
||||
- type
|
||||
type: object
|
||||
type: object
|
||||
served: true
|
||||
storage: true
|
||||
+299
@@ -0,0 +1,299 @@
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
kind: CustomResourceDefinition
|
||||
metadata:
|
||||
annotations:
|
||||
controller-gen.kubebuilder.io/version: v0.9.2
|
||||
creationTimestamp: null
|
||||
name: logsinstances.monitoring.grafana.com
|
||||
spec:
|
||||
group: monitoring.grafana.com
|
||||
names:
|
||||
categories:
|
||||
- agent-operator
|
||||
kind: LogsInstance
|
||||
listKind: LogsInstanceList
|
||||
plural: logsinstances
|
||||
singular: logsinstance
|
||||
scope: Namespaced
|
||||
versions:
|
||||
- name: v1alpha1
|
||||
schema:
|
||||
openAPIV3Schema:
|
||||
properties:
|
||||
apiVersion:
|
||||
type: string
|
||||
kind:
|
||||
type: string
|
||||
metadata:
|
||||
type: object
|
||||
spec:
|
||||
properties:
|
||||
additionalScrapeConfigs:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
clients:
|
||||
items:
|
||||
properties:
|
||||
backoffConfig:
|
||||
properties:
|
||||
maxPeriod:
|
||||
type: string
|
||||
maxRetries:
|
||||
type: integer
|
||||
minPeriod:
|
||||
type: string
|
||||
type: object
|
||||
basicAuth:
|
||||
properties:
|
||||
password:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
username:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
batchSize:
|
||||
type: integer
|
||||
batchWait:
|
||||
type: string
|
||||
bearerToken:
|
||||
type: string
|
||||
bearerTokenFile:
|
||||
type: string
|
||||
externalLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
oauth2:
|
||||
properties:
|
||||
clientId:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
clientSecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
endpointParams:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
scopes:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
tokenUrl:
|
||||
minLength: 1
|
||||
type: string
|
||||
required:
|
||||
- clientId
|
||||
- clientSecret
|
||||
- tokenUrl
|
||||
type: object
|
||||
proxyUrl:
|
||||
type: string
|
||||
tenantId:
|
||||
type: string
|
||||
timeout:
|
||||
type: string
|
||||
tlsConfig:
|
||||
properties:
|
||||
ca:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
caFile:
|
||||
type: string
|
||||
cert:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
certFile:
|
||||
type: string
|
||||
insecureSkipVerify:
|
||||
type: boolean
|
||||
keyFile:
|
||||
type: string
|
||||
keySecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
serverName:
|
||||
type: string
|
||||
type: object
|
||||
url:
|
||||
type: string
|
||||
required:
|
||||
- url
|
||||
type: object
|
||||
type: array
|
||||
podLogsNamespaceSelector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
podLogsSelector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
targetConfig:
|
||||
properties:
|
||||
syncPeriod:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
type: object
|
||||
served: true
|
||||
storage: true
|
||||
+495
@@ -0,0 +1,495 @@
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
kind: CustomResourceDefinition
|
||||
metadata:
|
||||
annotations:
|
||||
controller-gen.kubebuilder.io/version: v0.9.2
|
||||
creationTimestamp: null
|
||||
name: metricsinstances.monitoring.grafana.com
|
||||
spec:
|
||||
group: monitoring.grafana.com
|
||||
names:
|
||||
categories:
|
||||
- agent-operator
|
||||
kind: MetricsInstance
|
||||
listKind: MetricsInstanceList
|
||||
plural: metricsinstances
|
||||
singular: metricsinstance
|
||||
scope: Namespaced
|
||||
versions:
|
||||
- name: v1alpha1
|
||||
schema:
|
||||
openAPIV3Schema:
|
||||
properties:
|
||||
apiVersion:
|
||||
type: string
|
||||
kind:
|
||||
type: string
|
||||
metadata:
|
||||
type: object
|
||||
spec:
|
||||
properties:
|
||||
additionalScrapeConfigs:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
maxWALTime:
|
||||
type: string
|
||||
minWALTime:
|
||||
type: string
|
||||
podMonitorNamespaceSelector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
podMonitorSelector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
probeNamespaceSelector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
probeSelector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
remoteFlushDeadline:
|
||||
type: string
|
||||
remoteWrite:
|
||||
items:
|
||||
properties:
|
||||
basicAuth:
|
||||
properties:
|
||||
password:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
username:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
bearerToken:
|
||||
type: string
|
||||
bearerTokenFile:
|
||||
type: string
|
||||
headers:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
metadataConfig:
|
||||
properties:
|
||||
send:
|
||||
type: boolean
|
||||
sendInterval:
|
||||
type: string
|
||||
type: object
|
||||
name:
|
||||
type: string
|
||||
oauth2:
|
||||
properties:
|
||||
clientId:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
clientSecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
endpointParams:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
scopes:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
tokenUrl:
|
||||
minLength: 1
|
||||
type: string
|
||||
required:
|
||||
- clientId
|
||||
- clientSecret
|
||||
- tokenUrl
|
||||
type: object
|
||||
proxyUrl:
|
||||
type: string
|
||||
queueConfig:
|
||||
properties:
|
||||
batchSendDeadline:
|
||||
type: string
|
||||
capacity:
|
||||
type: integer
|
||||
maxBackoff:
|
||||
type: string
|
||||
maxRetries:
|
||||
type: integer
|
||||
maxSamplesPerSend:
|
||||
type: integer
|
||||
maxShards:
|
||||
type: integer
|
||||
minBackoff:
|
||||
type: string
|
||||
minShards:
|
||||
type: integer
|
||||
retryOnRateLimit:
|
||||
type: boolean
|
||||
type: object
|
||||
remoteTimeout:
|
||||
type: string
|
||||
sigv4:
|
||||
properties:
|
||||
accessKey:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
profile:
|
||||
type: string
|
||||
region:
|
||||
type: string
|
||||
roleARN:
|
||||
type: string
|
||||
secretKey:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
tlsConfig:
|
||||
properties:
|
||||
ca:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
caFile:
|
||||
type: string
|
||||
cert:
|
||||
properties:
|
||||
configMap:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
secret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
type: object
|
||||
certFile:
|
||||
type: string
|
||||
insecureSkipVerify:
|
||||
type: boolean
|
||||
keyFile:
|
||||
type: string
|
||||
keySecret:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
name:
|
||||
type: string
|
||||
optional:
|
||||
type: boolean
|
||||
required:
|
||||
- key
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
serverName:
|
||||
type: string
|
||||
type: object
|
||||
url:
|
||||
type: string
|
||||
writeRelabelConfigs:
|
||||
items:
|
||||
properties:
|
||||
action:
|
||||
default: replace
|
||||
enum:
|
||||
- replace
|
||||
- Replace
|
||||
- keep
|
||||
- Keep
|
||||
- drop
|
||||
- Drop
|
||||
- hashmod
|
||||
- HashMod
|
||||
- labelmap
|
||||
- LabelMap
|
||||
- labeldrop
|
||||
- LabelDrop
|
||||
- labelkeep
|
||||
- LabelKeep
|
||||
- lowercase
|
||||
- Lowercase
|
||||
- uppercase
|
||||
- Uppercase
|
||||
- keepequal
|
||||
- KeepEqual
|
||||
- dropequal
|
||||
- DropEqual
|
||||
type: string
|
||||
modulus:
|
||||
format: int64
|
||||
type: integer
|
||||
regex:
|
||||
type: string
|
||||
replacement:
|
||||
type: string
|
||||
separator:
|
||||
type: string
|
||||
sourceLabels:
|
||||
items:
|
||||
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
|
||||
type: string
|
||||
type: array
|
||||
targetLabel:
|
||||
type: string
|
||||
type: object
|
||||
type: array
|
||||
required:
|
||||
- url
|
||||
type: object
|
||||
type: array
|
||||
serviceMonitorNamespaceSelector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
serviceMonitorSelector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
walTruncateFrequency:
|
||||
type: string
|
||||
writeStaleOnShutdown:
|
||||
type: boolean
|
||||
type: object
|
||||
type: object
|
||||
served: true
|
||||
storage: true
|
||||
@@ -0,0 +1,308 @@
|
||||
---
|
||||
apiVersion: apiextensions.k8s.io/v1
|
||||
kind: CustomResourceDefinition
|
||||
metadata:
|
||||
annotations:
|
||||
controller-gen.kubebuilder.io/version: v0.9.2
|
||||
creationTimestamp: null
|
||||
name: podlogs.monitoring.grafana.com
|
||||
spec:
|
||||
group: monitoring.grafana.com
|
||||
names:
|
||||
categories:
|
||||
- agent-operator
|
||||
kind: PodLogs
|
||||
listKind: PodLogsList
|
||||
plural: podlogs
|
||||
singular: podlogs
|
||||
scope: Namespaced
|
||||
versions:
|
||||
- name: v1alpha1
|
||||
schema:
|
||||
openAPIV3Schema:
|
||||
properties:
|
||||
apiVersion:
|
||||
type: string
|
||||
kind:
|
||||
type: string
|
||||
metadata:
|
||||
type: object
|
||||
spec:
|
||||
properties:
|
||||
jobLabel:
|
||||
type: string
|
||||
namespaceSelector:
|
||||
properties:
|
||||
any:
|
||||
type: boolean
|
||||
matchNames:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
type: object
|
||||
pipelineStages:
|
||||
items:
|
||||
properties:
|
||||
cri:
|
||||
type: object
|
||||
docker:
|
||||
type: object
|
||||
drop:
|
||||
properties:
|
||||
dropCounterReason:
|
||||
type: string
|
||||
expression:
|
||||
type: string
|
||||
longerThan:
|
||||
type: string
|
||||
olderThan:
|
||||
type: string
|
||||
source:
|
||||
type: string
|
||||
value:
|
||||
type: string
|
||||
type: object
|
||||
json:
|
||||
properties:
|
||||
expressions:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
source:
|
||||
type: string
|
||||
type: object
|
||||
labelAllow:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
labelDrop:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
labels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
limit:
|
||||
properties:
|
||||
burst:
|
||||
type: integer
|
||||
drop:
|
||||
type: boolean
|
||||
rate:
|
||||
type: integer
|
||||
type: object
|
||||
match:
|
||||
properties:
|
||||
action:
|
||||
type: string
|
||||
dropCounterReason:
|
||||
type: string
|
||||
pipelineName:
|
||||
type: string
|
||||
selector:
|
||||
type: string
|
||||
stages:
|
||||
type: string
|
||||
required:
|
||||
- selector
|
||||
type: object
|
||||
metrics:
|
||||
additionalProperties:
|
||||
properties:
|
||||
action:
|
||||
type: string
|
||||
buckets:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
countEntryBytes:
|
||||
type: boolean
|
||||
description:
|
||||
type: string
|
||||
matchAll:
|
||||
type: boolean
|
||||
maxIdleDuration:
|
||||
type: string
|
||||
prefix:
|
||||
type: string
|
||||
source:
|
||||
type: string
|
||||
type:
|
||||
type: string
|
||||
value:
|
||||
type: string
|
||||
required:
|
||||
- action
|
||||
- type
|
||||
type: object
|
||||
type: object
|
||||
multiline:
|
||||
properties:
|
||||
firstLine:
|
||||
type: string
|
||||
maxLines:
|
||||
type: integer
|
||||
maxWaitTime:
|
||||
type: string
|
||||
required:
|
||||
- firstLine
|
||||
type: object
|
||||
output:
|
||||
properties:
|
||||
source:
|
||||
type: string
|
||||
required:
|
||||
- source
|
||||
type: object
|
||||
pack:
|
||||
properties:
|
||||
ingestTimestamp:
|
||||
type: boolean
|
||||
labels:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- labels
|
||||
type: object
|
||||
regex:
|
||||
properties:
|
||||
expression:
|
||||
type: string
|
||||
source:
|
||||
type: string
|
||||
required:
|
||||
- expression
|
||||
type: object
|
||||
replace:
|
||||
properties:
|
||||
expression:
|
||||
type: string
|
||||
replace:
|
||||
type: string
|
||||
source:
|
||||
type: string
|
||||
required:
|
||||
- expression
|
||||
type: object
|
||||
template:
|
||||
properties:
|
||||
source:
|
||||
type: string
|
||||
template:
|
||||
type: string
|
||||
required:
|
||||
- source
|
||||
- template
|
||||
type: object
|
||||
tenant:
|
||||
properties:
|
||||
label:
|
||||
type: string
|
||||
source:
|
||||
type: string
|
||||
value:
|
||||
type: string
|
||||
type: object
|
||||
timestamp:
|
||||
properties:
|
||||
actionOnFailure:
|
||||
type: string
|
||||
fallbackFormats:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
format:
|
||||
type: string
|
||||
location:
|
||||
type: string
|
||||
source:
|
||||
type: string
|
||||
required:
|
||||
- format
|
||||
- source
|
||||
type: object
|
||||
type: object
|
||||
type: array
|
||||
podTargetLabels:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
relabelings:
|
||||
items:
|
||||
properties:
|
||||
action:
|
||||
default: replace
|
||||
enum:
|
||||
- replace
|
||||
- Replace
|
||||
- keep
|
||||
- Keep
|
||||
- drop
|
||||
- Drop
|
||||
- hashmod
|
||||
- HashMod
|
||||
- labelmap
|
||||
- LabelMap
|
||||
- labeldrop
|
||||
- LabelDrop
|
||||
- labelkeep
|
||||
- LabelKeep
|
||||
- lowercase
|
||||
- Lowercase
|
||||
- uppercase
|
||||
- Uppercase
|
||||
- keepequal
|
||||
- KeepEqual
|
||||
- dropequal
|
||||
- DropEqual
|
||||
type: string
|
||||
modulus:
|
||||
format: int64
|
||||
type: integer
|
||||
regex:
|
||||
type: string
|
||||
replacement:
|
||||
type: string
|
||||
separator:
|
||||
type: string
|
||||
sourceLabels:
|
||||
items:
|
||||
pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
|
||||
type: string
|
||||
type: array
|
||||
targetLabel:
|
||||
type: string
|
||||
type: object
|
||||
type: array
|
||||
selector:
|
||||
properties:
|
||||
matchExpressions:
|
||||
items:
|
||||
properties:
|
||||
key:
|
||||
type: string
|
||||
operator:
|
||||
type: string
|
||||
values:
|
||||
items:
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- key
|
||||
- operator
|
||||
type: object
|
||||
type: array
|
||||
matchLabels:
|
||||
additionalProperties:
|
||||
type: string
|
||||
type: object
|
||||
type: object
|
||||
x-kubernetes-map-type: atomic
|
||||
required:
|
||||
- selector
|
||||
type: object
|
||||
type: object
|
||||
served: true
|
||||
storage: true
|
||||
@@ -0,0 +1,70 @@
|
||||
{{/*
|
||||
Expand the name of the chart.
|
||||
*/}}
|
||||
{{- define "ga-operator.name" -}}
|
||||
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create a default fully qualified app name.
|
||||
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
|
||||
If release name contains chart name it will be used as a full name.
|
||||
*/}}
|
||||
{{- define "ga-operator.fullname" -}}
|
||||
{{- if .Values.fullnameOverride }}
|
||||
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
|
||||
{{- else }}
|
||||
{{- $name := default .Chart.Name .Values.nameOverride }}
|
||||
{{- if contains $name .Release.Name }}
|
||||
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
|
||||
{{- else }}
|
||||
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create chart name and version as used by the chart label.
|
||||
*/}}
|
||||
{{- define "ga-operator.chart" -}}
|
||||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Common labels
|
||||
*/}}
|
||||
{{- define "ga-operator.labels" -}}
|
||||
{{ include "ga-operator.selectorLabels" . }}
|
||||
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||
app.kubernetes.io/component: operator
|
||||
helm.sh/chart: {{ include "ga-operator.chart" . }}
|
||||
{{- if .Chart.AppVersion }}
|
||||
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||
{{- end }}
|
||||
{{- if .Values.customLabels }}
|
||||
{{ toYaml .Values.customLabels }}
|
||||
{{- end }}
|
||||
{{- with .Values.global.commonLabels }}
|
||||
{{ toYaml . }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Selector labels
|
||||
*/}}
|
||||
{{- define "ga-operator.selectorLabels" -}}
|
||||
app.kubernetes.io/name: {{ include "ga-operator.name" . }}
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create the name of the service account to use
|
||||
*/}}
|
||||
{{- define "ga-operator.serviceAccountName" -}}
|
||||
{{- if .Values.serviceAccount.create }}
|
||||
{{- default (include "ga-operator.fullname" .) .Values.serviceAccount.name }}
|
||||
{{- else }}
|
||||
{{- default "default" .Values.serviceAccount.name }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
@@ -0,0 +1,62 @@
|
||||
{{- if .Values.rbac.create -}}
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
kind: ClusterRole
|
||||
metadata:
|
||||
name: {{ include "ga-operator.fullname" . }}
|
||||
labels:
|
||||
{{ include "ga-operator.labels" . | indent 4 }}
|
||||
rules:
|
||||
- apiGroups: [monitoring.grafana.com]
|
||||
resources:
|
||||
- grafanaagents
|
||||
- metricsinstances
|
||||
- logsinstances
|
||||
- podlogs
|
||||
- integrations
|
||||
verbs: [get, list, watch]
|
||||
- apiGroups: [monitoring.grafana.com]
|
||||
resources:
|
||||
- grafanaagents/finalizers
|
||||
- metricsinstances/finalizers
|
||||
- logsinstances/finalizers
|
||||
- podlogs/finalizers
|
||||
- integrations/finalizers
|
||||
verbs: [get, list, watch, update]
|
||||
- apiGroups: [monitoring.coreos.com]
|
||||
resources:
|
||||
- podmonitors
|
||||
- probes
|
||||
- servicemonitors
|
||||
verbs: [get, list, watch]
|
||||
- apiGroups: [monitoring.coreos.com]
|
||||
resources:
|
||||
- podmonitors/finalizers
|
||||
- probes/finalizers
|
||||
- servicemonitors/finalizers
|
||||
verbs: [get, list, watch, update]
|
||||
- apiGroups: [""]
|
||||
resources:
|
||||
- namespaces
|
||||
- nodes
|
||||
verbs: [get, list, watch]
|
||||
- apiGroups: [""]
|
||||
resources:
|
||||
- secrets
|
||||
- services
|
||||
- configmaps
|
||||
- endpoints
|
||||
verbs: [get, list, watch, create, update, patch, delete]
|
||||
- apiGroups: ["apps"]
|
||||
resources:
|
||||
- statefulsets
|
||||
- daemonsets
|
||||
- deployments
|
||||
verbs: [get, list, watch, create, update, patch, delete]
|
||||
{{- with .Values.rbac.podSecurityPolicyName }}
|
||||
- apiGroups: [policy]
|
||||
resources:
|
||||
- podsecuritypolicies
|
||||
verbs: [use]
|
||||
resourceNames: [ {{ . }} ]
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,17 @@
|
||||
{{- if .Values.rbac.create -}}
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
kind: ClusterRoleBinding
|
||||
metadata:
|
||||
name: {{ include "ga-operator.fullname" . }}
|
||||
labels:
|
||||
{{ include "ga-operator.labels" . | indent 4 }}
|
||||
roleRef:
|
||||
apiGroup: rbac.authorization.k8s.io
|
||||
kind: ClusterRole
|
||||
name: {{ include "ga-operator.fullname" . }}
|
||||
subjects:
|
||||
- kind: ServiceAccount
|
||||
name: {{ template "ga-operator.serviceAccountName" . }}
|
||||
namespace: {{ .Release.Namespace }}
|
||||
{{- end -}}
|
||||
|
||||
@@ -0,0 +1,79 @@
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: {{ include "ga-operator.fullname" . }}
|
||||
namespace: {{ .Release.Namespace }}
|
||||
labels:
|
||||
{{ include "ga-operator.labels" . | indent 4 }}
|
||||
{{- with .Values.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
{{ include "ga-operator.selectorLabels" . | indent 6 }}
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
{{ include "ga-operator.selectorLabels" . | indent 8 }}
|
||||
{{- with .Values.podLabels }}
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.podAnnotations }}
|
||||
annotations:
|
||||
{{ toYaml . | indent 8 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- with .Values.priorityClassName }}
|
||||
priorityClassName: {{ . }}
|
||||
{{- end }}
|
||||
serviceAccountName: {{ template "ga-operator.serviceAccountName" . }}
|
||||
{{- with .Values.podSecurityContext }}
|
||||
securityContext:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
containers:
|
||||
- name: {{ include "ga-operator.name" . }}
|
||||
image: "{{ .Values.image.registry }}/{{ .Values.image.repository }}:{{ .Values.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
{{- with .Values.containerSecurityContext }}
|
||||
securityContext:
|
||||
{{- toYaml . | nindent 10 }}
|
||||
{{- end }}
|
||||
{{- with .Values.resources }}
|
||||
resources:
|
||||
{{- toYaml . | nindent 10 }}
|
||||
{{- end }}
|
||||
{{- if or (and .Values.kubeletService.namespace .Values.kubeletService.serviceName) (.Values.extraArgs) }}
|
||||
args:
|
||||
{{- if and .Values.kubeletService.namespace .Values.kubeletService.serviceName }}
|
||||
- --kubelet-service={{ .Values.kubeletService.namespace }}/{{ .Values.kubeletService.serviceName }}
|
||||
{{- end }}
|
||||
{{- if .Values.extraArgs }}
|
||||
{{- range .Values.extraArgs }}
|
||||
- {{ . }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- with .Values.image.pullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.hostAliases }}
|
||||
hostAliases:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.nodeSelector }}
|
||||
nodeSelector:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.tolerations }}
|
||||
tolerations:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- with .Values.affinity }}
|
||||
affinity:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
@@ -0,0 +1,10 @@
|
||||
{{- if .Values.serviceAccount.create -}}
|
||||
apiVersion: v1
|
||||
kind: ServiceAccount
|
||||
metadata:
|
||||
name: {{ template "ga-operator.serviceAccountName" . }}
|
||||
namespace: {{ .Release.Namespace }}
|
||||
labels:
|
||||
{{ include "ga-operator.labels" . | indent 4 }}
|
||||
{{- end -}}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user