Editing Kind: Pod
Jump to navigation
Jump to search
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 18: | Line 18: | ||
https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ | https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ | ||
− | + | --- | |
+ | apiVersion: v1 | ||
+ | kind: Pod | ||
+ | metadata: | ||
+ | name: frontend | ||
+ | [[spec:]] | ||
+ | containers: | ||
+ | - name: app | ||
+ | image: images.my-company.example/app:v4 | ||
+ | resources: | ||
+ | requests: | ||
+ | memory: "64Mi" | ||
+ | [[cpu:]] "250m" | ||
+ | limits: | ||
+ | memory: "128Mi" | ||
+ | cpu: "500m" | ||
+ | - name: log-aggregator | ||
+ | image: images.my-company.example/log-aggregator:v6 | ||
+ | [[resources:]] | ||
+ | requests: | ||
+ | memory: "64Mi" | ||
+ | cpu: "250m" | ||
+ | limits: | ||
+ | memory: "128Mi" | ||
+ | cpu: "500m" | ||
Line 41: | Line 65: | ||
image: busybox:1.28 | image: busybox:1.28 | ||
command: ['sh', '-c', "until nslookup mydb.$(cat /var/run/secrets/kubernetes.io/serviceaccount/namespace).svc.cluster.local; do echo waiting for mydb; sleep 2; done"] | command: ['sh', '-c', "until nslookup mydb.$(cat /var/run/secrets/kubernetes.io/serviceaccount/namespace).svc.cluster.local; do echo waiting for mydb; sleep 2; done"] | ||
− | |||
− | |||
− | |||
− | |||
== Related == | == Related == | ||
Line 60: | Line 80: | ||
* <code>[[kubectl run]]</code> | * <code>[[kubectl run]]</code> | ||
* [[Configure a Security Context for a Pod or Container]] | * [[Configure a Security Context for a Pod or Container]] | ||
− | |||
== See also == | == See also == |
Advertising: