I am java developer and my devops expertice is not deep. Currently we use containers everywhere: docker, k8s etc.
In most cases we put single application into separated container, put it into separated k8s pod.
Is there ant scenarious when we should put
- 2 or more applications into the same container
- 2 or more containers into the same pod ?
2
Answers
Sidecar containers are containers that are needed to run alongside the main container. The two containers share resources like pod storage and network interfaces. The sidecar containers can also share storage volumes with the main containers, allowing the main containers to access the data in the sidecars.
Multiple containers
in a Pod
:Helper or side application to your main application — Called
Side-Car
containers. example of side-car containers would be: back-up container, Authentication, Synchronising, etcAlso we have
Pause Containers
:Pause
container in each Podsandbox
containersMore Resources: