Skip to content

Commit

Permalink
Add configmap for the agent (#44)
Browse files Browse the repository at this point in the history
* Add configmap for the agent

* Bump to 4.2.0
  • Loading branch information
mkuratczyk authored Mar 1, 2023
1 parent 6758803 commit c98af7b
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 2 deletions.
2 changes: 1 addition & 1 deletion charts/parca/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 4.1.0
version: 4.2.0

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
Expand Down
3 changes: 2 additions & 1 deletion charts/parca/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# parca

![Version: 4.1.0](https://img.shields.io/badge/Version-4.1.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.15.0](https://img.shields.io/badge/AppVersion-0.15.0-informational?style=flat-square)
![Version: 4.2.0](https://img.shields.io/badge/Version-4.2.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.15.0](https://img.shields.io/badge/AppVersion-0.15.0-informational?style=flat-square)

Open Source Infrastructure-wide continuous profiling

Expand Down Expand Up @@ -61,6 +61,7 @@ helm repo add parca https://parca-dev.github.io/helm-charts

| Key | Type | Default | Description |
|-----|------|---------|-------------|
| agent.config | object | `{"relabel_configs":null}` | parca agent config block |
| agent.enablePsp | bool | `false` | If the PodSecurityPolicy should be enabled |
| agent.enabled | bool | `true` | Allows disabling parca agent |
| agent.extraArgs | list | `[]` | additional arguments to pass to the agent |
Expand Down
11 changes: 11 additions & 0 deletions charts/parca/templates/agent-configmap.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{{- if .Values.agent.enabled -}}
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ include "parca.fullname" . }}-agent-config
labels:
{{- include "parca.labels.agent" . | nindent 4 }}
data:
parca-agent.yaml: |-
{{ toYaml .Values.agent.config | indent 4 }}
{{- end }}
6 changes: 6 additions & 0 deletions charts/parca/templates/agent-daemonset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ spec:
- /bin/parca-agent
- --log-level={{ .Values.agent.logLevel }}
- --node=$(NODE_NAME)
- --config-path=/var/parca/parca-agent.yaml
{{- if .Values.agent.remoteStoreAddress }}
- --remote-store-address={{ .Values.agent.remoteStoreAddress }}
{{- else }}
Expand Down Expand Up @@ -78,6 +79,8 @@ spec:
name: cgroup
- mountPath: /sys/fs/bpf
name: bpffs
- mountPath: /var/parca
name: {{ include "parca.fullname" . }}-agent-config
{{- if .Values.agent.remoteStoreBearerToken }}
- mountPath: /var/parca-agent-remote-store-bearer-token
name: parca-agent-remote-store-bearer-token
Expand All @@ -103,6 +106,9 @@ spec:
- hostPath:
path: /sys/kernel/debug
name: debugfs
- configMap:
name: {{ include "parca.fullname" . }}-agent-config
name: {{ include "parca.fullname" . }}-agent-config
{{- if .Values.agent.remoteStoreBearerToken }}
- name: parca-agent-remote-store-bearer-token
secret:
Expand Down
4 changes: 4 additions & 0 deletions charts/parca/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ agent:
# -- Allows disabling parca agent
enabled: true

# -- parca agent config block
config:
relabel_configs:

# -- If the PodSecurityPolicy should be enabled
enablePsp: false

Expand Down

0 comments on commit c98af7b

Please sign in to comment.