Difference between revisions of "Kubernetes metadata"

From wikieduonline
Jump to navigation Jump to search
 
(11 intermediate revisions by 4 users not shown)
Line 5: Line 5:
 
  metadata:
 
  metadata:
 
   name: hello
 
   name: hello
  spec:
+
  [[spec:]]
 
   schedule: "*/1 * * * *"
 
   schedule: "*/1 * * * *"
 +
.../...
 +
 +
[[kind: PersistentVolumeClaim]]
 +
metadata:
 +
    name: YourVolumeName
 
  .../...
 
  .../...
  
Line 14: Line 19:
 
  .../...
 
  .../...
  
  apiVersion: v1
+
  [[apiVersion: v1]]
 
  [[kind: ConfigMap]]
 
  [[kind: ConfigMap]]
 
  [[metadata:]]
 
  [[metadata:]]
 
   ...
 
   ...
  data:
+
  [[data:]]
 
   ...
 
   ...
 
  [[immutable]]: true
 
  [[immutable]]: true
Line 28: Line 33:
 
     [[kubernetes.io/psp]]: [[eks.privileged]]
 
     [[kubernetes.io/psp]]: [[eks.privileged]]
  
 +
 +
{{kubernetes manifest official example}}
 +
 +
== Related ==
 +
* <code>[[kind: Pod]]</code>
 +
* [[template.metadata]]
 +
* <code>[[kubectl apply]]</code>, <code>[[creationTimestamp]]</code>
  
 
== See also ==
 
== See also ==
* {{K8s}}
+
* {{kind}}
 +
* {{kubectl label}}
 +
* {{Kubernetes labels}}
  
 
[[Category:K8s]]
 
[[Category:K8s]]

Latest revision as of 15:06, 9 August 2023


apiVersion: batch/v1
kind: CronJob
metadata:
  name: hello
spec:
  schedule: "*/1 * * * *"
.../...
kind: PersistentVolumeClaim
metadata:
    name: YourVolumeName
.../...
.../...
metadata:
 labels:
.../...
apiVersion: v1
kind: ConfigMap
metadata:
  ...
data:
  ...
immutable: true


metadata:
  annotations:
    kubernetes.io/psp: eks.privileged


resource "kubernetes_manifest" "test-configmap" {
 manifest = {
   "apiVersion" = "v1"
   "kind"       = "ConfigMap"
   "metadata" = {
     "name"      = "test-config"
     "namespace" = "default"
   }
   "data" = {
     "foo" = "bar"
   }
 }
}

Related[edit]

See also[edit]

Advertising: