Skip to content

Instantly share code, notes, and snippets.

@ssbostan
Created March 11, 2023 22:07
Show Gist options
  • Save ssbostan/c308e3c3a767c67d3181b99f162e3a2c to your computer and use it in GitHub Desktop.
Save ssbostan/c308e3c3a767c67d3181b99f162e3a2c to your computer and use it in GitHub Desktop.
Kubernetes Hacks and Tricks - #5 Pod DNS Policy and DNS Config options
apiVersion: v1
kind: Service
metadata:
name: test
spec:
type: ClusterIP
ports:
- port: 80
---
apiVersion: v1
kind: Pod
metadata:
name: test
spec:
dnsPolicy: ClusterFirst
containers:
- name: test
image: alpine:latest
command: ["sleep", "1000"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment