Permalink
Cannot retrieve contributors at this time
# https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/ | |
# https://cheatsheet.dennyzhang.com/kubernetes-yaml-templates | |
apiVersion: v1 | |
kind: Pod | |
metadata: | |
name: hostaliases-pod | |
spec: | |
restartPolicy: Never | |
hostAliases: | |
- ip: "127.0.0.1" | |
hostnames: | |
- "foo.local" | |
- "bar.local" | |
- ip: "10.1.2.3" | |
hostnames: | |
- "foo.remote" | |
- "bar.remote" | |
containers: | |
- name: dummy-hosts | |
image: busybox | |
args: [/bin/sh, -c, | |
'i=0; while true; do echo "$i: $(date)"; i=$((i+1)); sleep 1; done'] |