github.com/dcarley/cf-cli@v6.24.1-0.20170220111324-4225ff346898+incompatible/command/v2/unmap_route_command.go (about) 1 package v2 2 3 import ( 4 "os" 5 6 "code.cloudfoundry.org/cli/cf/cmd" 7 "code.cloudfoundry.org/cli/command" 8 "code.cloudfoundry.org/cli/command/flag" 9 ) 10 11 type UnmapRouteCommand struct { 12 RequiredArgs flag.AppDomain `positional-args:"yes"` 13 Hostname string `long:"hostname" short:"n" description:"Hostname used to identify the HTTP route"` 14 Path string `long:"path" description:"Path used to identify the HTTP route"` 15 Port int `long:"port" description:"Port used to identify the TCP route"` 16 usage interface{} `usage:"Unmap an HTTP route:\n CF_NAME unmap-route APP_NAME DOMAIN [--hostname HOSTNAME] [--path PATH]\n\n Unmap a TCP route:\n CF_NAME unmap-route APP_NAME DOMAIN --port PORT\n\nEXAMPLES:\n CF_NAME unmap-route my-app example.com # example.com\n CF_NAME unmap-route my-app example.com --hostname myhost # myhost.example.com\n CF_NAME unmap-route my-app example.com --hostname myhost --path foo # myhost.example.com/foo\n CF_NAME unmap-route my-app example.com --port 5000 # example.com:5000"` 17 relatedCommands interface{} `related_commands:"delete-route, routes"` 18 } 19 20 func (_ UnmapRouteCommand) Setup(config command.Config, ui command.UI) error { 21 return nil 22 } 23 24 func (_ UnmapRouteCommand) Execute(args []string) error { 25 cmd.Main(os.Getenv("CF_TRACE"), os.Args) 26 return nil 27 }