Skip to content

Instantly share code, notes, and snippets.

@dockerlead
Created November 4, 2020 03:17
Show Gist options
  • Save dockerlead/e9b816e1e50ee211314b0d2e535ea955 to your computer and use it in GitHub Desktop.
Save dockerlead/e9b816e1e50ee211314b0d2e535ea955 to your computer and use it in GitHub Desktop.
Nginx as main container, Curl as sidecar container, making a multiple container pod.
apiVersion: v1
kind: Pod
metadata:
name: nginx
labels:
app: nginx
spec:
containers:
- name: nginx-container
image: nginx
ports:
- containerPort: 80
- name: sidecar
image: curlimages/curl
command: ["/bin/sh"]
args: ["-c", "echo Hello from the sidecar container; sleep 300"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment