Skip to content

Commit

Permalink
update tracing docs (#860)
Browse files Browse the repository at this point in the history
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
  • Loading branch information
eddycharly committed May 22, 2023
1 parent 444bb7d commit 10a39fb
Show file tree
Hide file tree
Showing 3 changed files with 110 additions and 36 deletions.
58 changes: 49 additions & 9 deletions content/en/docs/Tracing/_index.md
Expand Up @@ -28,15 +28,55 @@ When you install Kyverno via Helm, you need to set a couple of values to enable
```shell
$ values.yaml

...
extraArgs:
# enable tracing
- --enableTracing
# configure tracing endpoint
- --tracingAddress=<backend url>
# configure tracing port
- --tracingPort=4317
...
# ...

# Enable tracing in the admission controller
admissionController:
tracing:
# -- Enable tracing
enabled: true
# -- Traces receiver address
address: <backend url>
# -- Traces receiver port
port: 4317

# ...

# Enable tracing in the background controller
backgroundController:
tracing:
# -- Enable tracing
enabled: true
# -- Traces receiver address
address: <backend url>
# -- Traces receiver port
port: 4317

# ...

# Enable tracing in the cleanup controller
cleanupController:
tracing:
# -- Enable tracing
enabled: true
# -- Traces receiver address
address: <backend url>
# -- Traces receiver port
port: 4317

# ...

# Enable tracing in the reports controller
reportsController:
tracing:
# -- Enable tracing
enabled: true
# -- Traces receiver address
address: <backend url>
# -- Traces receiver port
port: 4317

# ...
```

Tracing is disabled by default and depending on the backend the associated cost can be significant.
Expand Down
43 changes: 30 additions & 13 deletions content/en/docs/Tracing/jaeger-walkthrough.md
Expand Up @@ -68,7 +68,7 @@ Jaeger is made of multiple components and is capable of using multiple storage s
We can deploy Jaeger using Helm with the following command:

```shell
helm upgrade --install jaeger --namespace monitoring --create-namespace --wait \
helm install jaeger --namespace monitoring --create-namespace --wait \
--repo https://jaegertracing.github.io/helm-charts jaeger \
--values - <<EOF
storage:
Expand Down Expand Up @@ -99,19 +99,27 @@ We now need to install Kyverno with tracing enabled and pointing to our Jaeger c
We can deploy Kyverno using Helm with the following command:

```shell
helm upgrade --install kyverno --namespace kyverno --create-namespace --wait \
helm install kyverno --namespace kyverno --create-namespace --wait \
--repo https://kyverno.github.io/kyverno kyverno \
--values - <<EOF
# kyverno controller
extraArgs:
# enable tracing
- --enableTracing
# jaeger backend url
- --tracingAddress=jaeger-collector.monitoring
# jaeger backend port for opentelemetry traces
- --tracingPort=4317
# cleanup controller
admissionController:
tracing:
# enable tracing
enabled: true
# jaeger backend url
address: jaeger-collector.monitoring
# jaeger backend port for opentelemetry traces
port: 4317
backgroundController:
tracing:
# enable tracing
enabled: true
# jaeger backend url
address: jaeger-collector.monitoring
# jaeger backend port for opentelemetry traces
port: 4317
cleanupController:
tracing:
# enable tracing
Expand All @@ -120,6 +128,15 @@ cleanupController:
address: jaeger-collector.monitoring
# jaeger backend port for opentelemetry traces
port: 4317
reportsController:
tracing:
# enable tracing
enabled: true
# jaeger backend url
address: jaeger-collector.monitoring
# jaeger backend port for opentelemetry traces
port: 4317
EOF
```

Expand All @@ -130,7 +147,7 @@ Finally we need to deploy some policies in the cluster so that Kyverno can confi
We are going to deploy the `kyverno-policies` Helm chart (with the `Baseline` profile of PSS) using the following command:

```shell
helm upgrade --install kyverno-policies --namespace kyverno --create-namespace --wait \
helm install kyverno-policies --namespace kyverno --create-namespace --wait \
--repo https://kyverno.github.io/kyverno kyverno-policies \
--values - <<EOF
validationFailureAction: Enforce
Expand Down
45 changes: 31 additions & 14 deletions content/en/docs/Tracing/tempo-walkthrough.md
Expand Up @@ -62,7 +62,7 @@ kubectl wait --namespace ingress-nginx --for=condition=ready pod --selector=app.
We can deploy Grafana using Helm with the following command:

```shell
helm upgrade --install grafana --namespace monitoring --create-namespace --wait \
helm install grafana --namespace monitoring --create-namespace --wait \
--repo https://grafana.github.io/helm-charts grafana \
--values - <<EOF
adminPassword: admin
Expand Down Expand Up @@ -96,7 +96,7 @@ At this point Grafana should be available at http://localhost/grafana (log in wi
We can deploy Tempo using Helm with the following command:

```shell
helm upgrade --install tempo --namespace monitoring --create-namespace --wait \
helm install tempo --namespace monitoring --create-namespace --wait \
--repo https://grafana.github.io/helm-charts tempo \
--values - <<EOF
tempo:
Expand Down Expand Up @@ -137,19 +137,27 @@ We now need to install Kyverno with tracing enabled and pointing to our Tempo ba
We can deploy Kyverno using Helm with the following command:

```shell
helm upgrade --install kyverno --namespace kyverno --create-namespace --wait \
helm install kyverno --namespace kyverno --create-namespace --wait \
--repo https://kyverno.github.io/kyverno kyverno \
--values - <<EOF
# kyverno controller
extraArgs:
# enable tracing
- --enableTracing
# tempo backend url
- --tracingAddress=tempo.monitoring
# tempo backend port for opentelemetry traces
- --tracingPort=4317
# cleanup controller
admissionController:
tracing:
# enable tracing
enabled: true
# tempo backend url
address: tempo.monitoring
# tempo backend port for opentelemetry traces
port: 4317
backgroundController:
tracing:
# enable tracing
enabled: true
# tempo backend url
address: tempo.monitoring
# tempo backend port for opentelemetry traces
port: 4317
cleanupController:
tracing:
# enable tracing
Expand All @@ -158,6 +166,15 @@ cleanupController:
address: tempo.monitoring
# tempo backend port for opentelemetry traces
port: 4317
reportsController:
tracing:
# enable tracing
enabled: true
# tempo backend url
address: tempo.monitoring
# tempo backend port for opentelemetry traces
port: 4317
EOF
```

Expand All @@ -168,7 +185,7 @@ Finally we need to deploy some policies in the cluster so that Kyverno can confi
We are going to deploy the `kyverno-policies` Helm chart (with the `Baseline` profile of PSS) using the following command:

```shell
helm upgrade --install kyverno-policies --namespace kyverno --create-namespace --wait \
helm install kyverno-policies --namespace kyverno --create-namespace --wait \
--repo https://kyverno.github.io/kyverno kyverno-policies \
--values - <<EOF
validationFailureAction: Enforce
Expand Down

0 comments on commit 10a39fb

Please sign in to comment.