Skip to main content

Sidecar Container

In Kubernetes or OpenShift, you can set Sidecar Container for your application or microservice.
This page explains you how.


1. In your manifest repository's main branch, you will find the values.yaml file, it showld be in the following folder structure [environment]/[project]/[application]

2. In the values.yaml file, search for the Additional Customizations section, you will find it like this:


## Additional Customizations #################################################

3. Bellow the section title, add the following configuration and change the values as you need:

  # - Sidecar Container
sidecar:
enabled: true
name: debug-sidecar
imageRepository: "docker.io/busybox"
imageTag: "stable"
imagePullPolicy: Always
command: '["sh","-c","sleep infinity"]'
shared:
variables:
enabled: false
secrets:
enabled: false
configMap:
enabled: false
volume:
enabled: false
name: logs
mountPath: /tmp/logs
configMap:
enabled: false
additionalLabels:
#key: value
annotations:
#key: value
mountPath: /tmp/sidecar-config.json
data: |
# Here your config content
{
host: "localhost-sidecar",
port: 8080,
protocol: "https"
}
#####

4. Commit and enjoy! ✨