mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-07 04:03:20 +00:00
Merge pull request #5522 from fabioy/expose-label.fix
Add "--labels" option to the "expose" kubectl command.
This commit is contained in:
@@ -56,6 +56,7 @@ func (f *Factory) NewCmdExposeService(out io.Writer) *cobra.Command {
|
||||
cmd.Flags().Int("port", -1, "The port that the service should serve on. Required.")
|
||||
cmd.Flags().Bool("create-external-load-balancer", false, "If true, create an external load balancer for this service. Implementation is cloud provider dependent. Default is 'false'.")
|
||||
cmd.Flags().String("selector", "", "A label selector to use for this service. If empty (the default) infer the selector from the replication controller.")
|
||||
cmd.Flags().StringP("labels", "l", "", "Labels to apply to the service created by this call.")
|
||||
cmd.Flags().Bool("dry-run", false, "If true, only print the object that would be sent, without creating it.")
|
||||
cmd.Flags().String("container-port", "", "Name or number for the port on the container that the service should direct traffic to. Optional.")
|
||||
cmd.Flags().String("public-ip", "", "Name of a public IP address to set for the service. The service will be assigned this IP in addition to its generated service IP.")
|
||||
|
Reference in New Issue
Block a user