Skip to content

Instantly share code, notes, and snippets.

@schoren
Created September 9, 2024 16:33
Show Gist options
  • Save schoren/bfc1937d50c5557899fcf0f8bfc535ea to your computer and use it in GitHub Desktop.
Save schoren/bfc1937d50c5557899fcf0f8bfc535ea to your computer and use it in GitHub Desktop.
#/usr/bin/env sh
cat <<EOF > /tmp/values.yaml
# Section for configuring the postgres database that will be used by Tracetest
postgresql:
# if enabled is true, the postgres chart will be installed.
# it can be turned off if you already have a postgres database running.
# In that case, you need to pass the values for "postgres.auth"
enabled: true
architecture: standalone
image:
tag: 14.7.0-debian-11-r29
primary:
persistence:
enabled: false
# credentials for accessing the database
auth:
# host is only required if not using the postgres chart
host: ""
port: 5432
params: sslmode=disable
database: "tracetest"
username: "tracetest"
password: not-secure-database-password
existingSecret: ""
# Provisioning allows to define initial settings to be loaded into the database on first run.
# These will only be applied when running tracetest against an empty database. If tracetest has already
# been configured, the provisioning settings are ignored.
provisioning: |
---
type: DataStore
spec:
name: Jaeger
# Indicates that this datastore is a jaeger instance
type: jaeger
# Configures how tracetest connects to jaeger.
jaeger:
endpoint: jaeger-query:16685
tls:
insecure: true
---
type: PollingProfile
spec:
name: Custom Profile
strategy: periodic
default: true
periodic:
timeout: 30s
retryDelay: 500ms
# Section to configure how telemetry works in Tracetest.
telemetry:
# exporters are opentelemetry exporters. It configures how tracetest generates and send telemetry to
# a datastore.
exporters:
# This is an exporter called collector, but it could be named anything else.
collector:
# configures the service.name attribute in all trace spans generated by tracetest
serviceName: tracetest
# indicates the percentage of traces that would be sent to the datastore. 100 = 100%
sampling: 100
# configures the exporter
exporter:
# Tracetest sends data using the opentelemetry collector. For now there is no other
# alternative. But the collector is flexible enough to send traces to any other tracing backend
# you might need.
type: collector
collector:
# endpoint to send traces to the collector
endpoint: otel-collector:4317
# Configures the server
server:
# Indicates the port that Tracetest will run ons
httpPort: 11633
otlpGrpcPort: 4317
otlpHttpPort: 4318
# Indicates which telemetry components will be used by Tracetest
telemetry:
# The exporter that tracetest will use to send telemetry
# exporter: collector
# The exporter that tracetest will send the triggering transaction span. This is optional. If you
# want to have the trigger transaction span in your trace, you have to configure this field to
# send the span to the same place your application sends its telemetry.
# applicationExporter: collector
replicaCount: 1
# You don't have to change anything bellow this line.
image:
repository: kubeshop/tracetest
pullPolicy: IfNotPresent
# Overrides the image tag whose default is the chart appVersion.
tag: ""
environmentVars:
- name: TRACETEST_DEV
value: "false"
imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""
# If set, it allows to pass a custom configmap to the tracetest server
configMapOverride: ""
serviceAccount:
# Specifies whether a service account should be created
create: false
# 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: ""
podAnnotations: {}
podSecurityContext: {}
# fsGroup: 2000
securityContext: {}
# capabilities:
# drop:
# - ALL
# readOnlyRootFilesystem: true
# runAsNonRoot: true
# runAsUser: 1000
service:
type: ClusterIP
annotations: {}
ingress:
enabled: false
className: ""
annotations: {}
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: "true"
hosts:
- host: chart-example.local
paths:
- path: /
pathType: ImplementationSpecific
tls: []
# - secretName: chart-example-tls
# hosts:
# - chart-example.local
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: 250m
memory: 512Mi
autoscaling:
enabled: false
minReplicas: 1
maxReplicas: 100
targetCPUUtilizationPercentage: 80
# targetMemoryUtilizationPercentage: 80
nodeSelector: {}
tolerations: []
affinity: {}
EOF
kind delete cluster --name provisioning-test
kind create cluster --name provisioning-test
helm install tracetest kubeshop/tracetest \
--create-namespace \
--namespace=tracetest \
--set image.tag=sha-12cf76aa \
-f /tmp/values.yaml
kubectl wait --namespace tracetest --for=condition=available --timeout=60s deployment/tracetest
kubectl get pods --namespace tracetest
kubectl logs --namespace tracetest deployment/tracetest
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment