DenCowboy
DenCowboy

Reputation: 15116

Yaml templates in Kubernetes

Where can I find an official template which describes how to create your .yaml file to setup services/pods in Kubernetes?

Upvotes: 10

Views: 13434

Answers (1)

Sebastian
Sebastian

Reputation: 776

You can find the specification for a pod here http://kubernetes.io/docs/api-reference/v1/definitions/#_v1_pod

A good starting point is also the examples https://github.com/kubernetes/kubernetes/tree/master/examples

Additional you can create the ressource via kubectl and export the resource to yaml

e.g. for a pod you can run this command:

kubectl run nginx --image=nginx kubectl get pods ngnix -o yaml > pod.yaml

Upvotes: 6

Related Questions