I am looking for different set of commands for kubectl run to generate yaml file.
Service (different options)
I checked Kubectl Reference Docs
but I am unable to figure out which command need to run for which option
$ run NAME --image=image [–env=“key=value”] [–port=port] [–replicas=replicas] [–dry-run=bool] [–overrides=inline-json] [–command] – [COMMAND] [args…]
For example :
$ kubectl run NAME --image=IMAGE-NAME --labels=run=LABLE --dry-run -o yaml > test.yaml
It creates deployment but I dont know what needs to be change to create other types of yaml.