feat: Simplify nginx-nodeport example with worker-only deployment and improved learning path
This commit is contained in:
@@ -16,6 +16,20 @@ spec:
|
||||
spec:
|
||||
hostNetwork: false
|
||||
dnsPolicy: ClusterFirst
|
||||
# Prefer worker nodes only (not master nodes)
|
||||
affinity:
|
||||
nodeAffinity:
|
||||
preferredDuringSchedulingIgnoredDuringExecution:
|
||||
- weight: 100
|
||||
preference:
|
||||
matchExpressions:
|
||||
- key: node-role.kubernetes.io/master
|
||||
operator: DoesNotExist
|
||||
- weight: 50
|
||||
preference:
|
||||
matchExpressions:
|
||||
- key: node-role.kubernetes.io/control-plane
|
||||
operator: DoesNotExist
|
||||
containers:
|
||||
- name: nginx
|
||||
image: nginx:alpine
|
||||
|
||||
Reference in New Issue
Block a user