@@ -25,6 +25,7 @@ type runOptions struct {
2525 kubeNamespace string
2626 stackName string
2727 cnabBundle string
28+ labels []string
2829}
2930
3031const longDescription = `Run an App from an App image.`
@@ -59,10 +60,11 @@ func runCmd(dockerCli command.Cli) *cobra.Command {
5960 }
6061 opts .parametersOptions .addFlags (cmd .Flags ())
6162 opts .credentialOptions .addFlags (cmd .Flags ())
62- cmd .Flags ().StringVar (& opts .orchestrator , "orchestrator" , "" , "Orchestrator to run on (swarm, kubernetes)" )
63- cmd .Flags ().StringVar (& opts .kubeNamespace , "namespace" , "default" , "Kubernetes namespace in which to run the App" )
64- cmd .Flags ().StringVar (& opts .stackName , "name" , "" , "Name of the running App" )
65- cmd .Flags ().StringVar (& opts .cnabBundle , "cnab-bundle-json" , "" , "Run a CNAB bundle instead of a Docker App image" )
63+ cmd .Flags ().StringVar (& opts .orchestrator , "orchestrator" , "" , "Orchestrator to install on (swarm, kubernetes)" )
64+ cmd .Flags ().StringVar (& opts .kubeNamespace , "namespace" , "default" , "Kubernetes namespace to install into" )
65+ cmd .Flags ().StringVar (& opts .stackName , "name" , "" , "Assign a name to the installation" )
66+ cmd .Flags ().StringVar (& opts .cnabBundle , "cnab-bundle-json" , "" , "Run a CNAB bundle instead of a Docker App" )
67+ cmd .Flags ().StringArrayVar (& opts .labels , "label" , nil , "Label to add to services" )
6668
6769 return cmd
6870}
@@ -130,6 +132,7 @@ func runBundle(dockerCli command.Cli, bndl *bundle.Bundle, opts runOptions, ref
130132 if err := mergeBundleParameters (installation ,
131133 withFileParameters (opts .parametersFiles ),
132134 withCommandLineParameters (opts .overrides ),
135+ withLabels (opts .labels ),
133136 withOrchestratorParameters (opts .orchestrator , opts .kubeNamespace ),
134137 withSendRegistryAuth (opts .sendRegistryAuth ),
135138 ); err != nil {
0 commit comments