github.com/elopio/cli@v6.21.2-0.20160902224010-ea909d1fdb2f+incompatible/commands/v2/update_service_command.go (about) 1 package v2 2 3 import ( 4 "os" 5 6 "code.cloudfoundry.org/cli/cf/cmd" 7 "code.cloudfoundry.org/cli/commands" 8 "code.cloudfoundry.org/cli/commands/flags" 9 ) 10 11 type UpdateServiceCommand struct { 12 RequiredArgs flags.ServiceInstance `positional-args:"yes"` 13 ParametersAsJSON string `short:"c" description:"Valid JSON object containing service-specific configuration parameters, provided either in-line or in a file. For a list of supported configuration parameters, see documentation for the particular service offering."` 14 Plan string `short:"p" description:"Change service plan for a service instance"` 15 Tags string `short:"t" description:"User provided tags"` 16 usage interface{} `usage:"CF_NAME update-service SERVICE_INSTANCE [-p NEW_PLAN] [-c PARAMETERS_AS_JSON] [-t TAGS]\n\n Optionally provide service-specific configuration parameters in a valid JSON object in-line.\n CF_NAME update-service -c '{\"name\":\"value\",\"name\":\"value\"}'\n\n Optionally provide a file containing service-specific configuration parameters in a valid JSON object. \n The path to the parameters file can be an absolute or relative path to a file.\n CF_NAME update-service -c PATH_TO_FILE\n\n Example of valid JSON object:\n {\n \"cluster_nodes\": {\n \"count\": 5,\n \"memory_mb\": 1024\n }\n }\n\n Optionally provide a list of comma-delimited tags that will be written to the VCAP_SERVICES environment variable for any bound applications.\n\nEXAMPLES:\n CF_NAME update-service mydb -p gold\n CF_NAME update-service mydb -c '{\"ram_gb\":4}'\n CF_NAME update-service mydb -c ~/workspace/tmp/instance_config.json\n CF_NAME update-service mydb -t \"list,of, tags\""` 17 relatedCommands interface{} `related_commands:"rename-service, services, update-user-provided-service"` 18 } 19 20 func (_ UpdateServiceCommand) Setup(config commands.Config, ui commands.UI) error { 21 return nil 22 } 23 24 func (_ UpdateServiceCommand) Execute(args []string) error { 25 cmd.Main(os.Getenv("CF_TRACE"), os.Args) 26 return nil 27 }