Document the namespace format for expose CLI command
This commit is contained in:
parent
7069150ee1
commit
05a8f4d95a
|
@ -37,16 +37,18 @@ type cmd struct {
|
||||||
func (c *cmd) init() {
|
func (c *cmd) init() {
|
||||||
c.flags = flag.NewFlagSet("", flag.ContinueOnError)
|
c.flags = flag.NewFlagSet("", flag.ContinueOnError)
|
||||||
c.flags.StringVar(&c.ingressGateway, "ingress-gateway", "",
|
c.flags.StringVar(&c.ingressGateway, "ingress-gateway", "",
|
||||||
"The name of the ingress gateway service to use. Required.")
|
"(Required) The name of the ingress gateway service to use. A namespace "+
|
||||||
|
"can optionally be specified as a prefix via the 'namespace/service' format.")
|
||||||
|
|
||||||
c.flags.StringVar(&c.service, "service", "",
|
c.flags.StringVar(&c.service, "service", "",
|
||||||
"The name of destination service to expose. Required.")
|
"(Required) The name of destination service to expose. A namespace "+
|
||||||
|
"can optionally be specified as a prefix via the 'namespace/service' format.")
|
||||||
|
|
||||||
c.flags.StringVar(&c.portRaw, "port", "",
|
c.flags.StringVar(&c.portRaw, "port", "",
|
||||||
"The listener port to use for the service on the Ingress gateway. Required.")
|
"(Required) The listener port to use for the service on the Ingress gateway.")
|
||||||
|
|
||||||
c.flags.StringVar(&c.protocol, "protocol", "tcp",
|
c.flags.StringVar(&c.protocol, "protocol", "tcp",
|
||||||
"The protocol for the service. Defaults to 'tcp'. Optional.")
|
"The protocol for the service. Defaults to 'tcp'.")
|
||||||
|
|
||||||
c.http = &flags.HTTPFlags{}
|
c.http = &flags.HTTPFlags{}
|
||||||
flags.Merge(c.flags, c.http.ClientFlags())
|
flags.Merge(c.flags, c.http.ClientFlags())
|
||||||
|
|
|
@ -33,14 +33,18 @@ Usage: consul connect expose [options]
|
||||||
|
|
||||||
#### Expose Options
|
#### Expose Options
|
||||||
|
|
||||||
- `-ingress-gateway` - The name of the ingress gateway service to use. Required.
|
- `-ingress-gateway` - (Required) The name of the ingress gateway service to use.
|
||||||
|
A namespace can optionally be specified as a prefix via the
|
||||||
|
'namespace/service' format
|
||||||
|
|
||||||
- `-port` - The listener port to use for the service on the Ingress gateway.
|
- `-port` - (Required) The listener port to use for the service on the Ingress
|
||||||
Required.
|
gateway.
|
||||||
|
|
||||||
- `-protocol` - The protocol for the service. Defaults to 'tcp'. Optional.
|
- `-protocol` - The protocol for the service. Defaults to 'tcp'.
|
||||||
|
|
||||||
- `-service` - The name of destination service to expose. Required.
|
- `-service` - (Required) The name of destination service to expose. A namespace
|
||||||
|
can optionally be specified as a prefix via the 'namespace/service'
|
||||||
|
format.
|
||||||
|
|
||||||
## Examples
|
## Examples
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue