Created
July 17, 2023 10:34
-
-
Save ssbostan/566f3d257bb24d6b43b2559aaf992aa5 to your computer and use it in GitHub Desktop.
Kubernetes Hacks and Tricks - #5 Pod DNS Policy and DNS Config options
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: test | |
spec: | |
type: ClusterIP | |
ports: | |
- port: 80 | |
--- | |
apiVersion: v1 | |
kind: Pod | |
metadata: | |
name: test | |
spec: | |
hostNetwork: true | |
dnsPolicy: ClusterFirstWithHostNet | |
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