Skip to content

Instantly share code, notes, and snippets.

@gerred
Last active November 6, 2023 08:23
Show Gist options
  • Save gerred/3cac803b9f8f581b22f562b509d897cf to your computer and use it in GitHub Desktop.
Save gerred/3cac803b9f8f581b22f562b509d897cf to your computer and use it in GitHub Desktop.
apiVersion: extensions/v1beta1
kind: DaemonSet
metadata:
labels:
name: logspout
name: logspout
namespace: default
spec:
selector:
matchLabels:
name: logspout
template:
metadata:
labels:
name: logspout
spec:
containers:
- env:
- name: SYSLOG_TAG
value: '{{ index .Container.Config.Labels "io.kubernetes.pod.namespace"
}}[{{ index .Container.Config.Labels "io.kubernetes.pod.name" }}]'
- name: SYSLOG_HOSTNAME
value: '{{ index .Container.Config.Labels "io.kubernetes.container.name"
}}'
image: mdsol/logspout:latest
imagePullPolicy: IfNotPresent
args:
- "cloudwatch://auto"
name: logspout
resources:
limits:
memory: 500Mi
requests:
cpu: 150m
volumeMounts:
- mountPath: /var/run/docker.sock
name: log
restartPolicy: Always
volumes:
- hostPath:
path: /var/run/docker.sock
type: ""
name: log
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment