-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
使用deploymane来模拟daemonset | 打工笔记 #39
Labels
utterance
utterance
Comments
apiVersion: apps/v1
kind: Deployment
metadata:
creationTimestamp: null
labels:
id: very-important
name: deploy-important
namespace: project-tiger
spec:
replicas: 3
selector:
matchLabels:
id: very-important
strategy: {}
template:
metadata:
creationTimestamp: null
labels:
id: very-important
spec:
affinity:
podAntiAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
- topologyKey: kubernetes.io/hostname
labelSelector:
matchExpressions:
- key: id
operator: In
values:
- very-important
containers:
- image: nginx:1.17.6-alpine
imagePullPolicy: Never
name: container1
resources: {}
- name: container2
image: kubernetes/pause
status: {} |
apiVersion: v1
kind: Pod
metadata:
creationTimestamp: null
labels:
run: secret-pod
name: secret-pod
namespace: secret
spec:
containers:
- image: busybox:1.31.1
name: secret-pod
env:
- name: APP_USER
valueFrom:
secretKeyRef:
name: secret2
key: user
- name: APP_PASS
valueFrom:
secretKeyRef:
name: secret2
key: pass
command:
- "sh"
- "-c"
- "sleep 3600"
volumeMounts:
- name: foo
mountPath: /tmp/secret1
resources: {}
dnsPolicy: ClusterFirst
restartPolicy: Always
tolerations:
- effect: NoSchedule
operator: Exists
- effect: NoExecute
operator: Exists
volumes:
- name: foo
secret:
secretName: secret1
tolerations:
- effect: NoSchedule
operator: Exists
key: node-role.kubernetes.io/master
status: {} |
kubectl -n secret create secret generic secret3 --from-literal=user=user1 --from-literal=pass=1234 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
使用deploymane来模拟daemonset | 打工笔记
打工笔记
https://amrom66.github.io/2022/2022-05-12-use-deployment-simuator-daemonset/
The text was updated successfully, but these errors were encountered: