mirror of https://github.com/knative/client.git
Mark deprecated options as 'hidden' (#1500)
so that they do not appear in the help messages
This commit is contained in:
parent
5197287f08
commit
e7e5372594
|
|
@ -35,7 +35,6 @@ kn container add NAME
|
|||
--env-file string Path to a file containing environment variables (e.g. --env-file=/home/knative/service1/env).
|
||||
--env-from stringArray Add environment variables from a ConfigMap (prefix cm: or config-map:) or a Secret (prefix secret:). Example: --env-from cm:myconfigmap or --env-from secret:mysecret. You can use this flag multiple times. To unset a ConfigMap/Secret reference, append "-" to the name, e.g. --env-from cm:myconfigmap-.
|
||||
--env-value-from stringArray Add environment variable from a value of key in ConfigMap (prefix cm: or config-map:) or a Secret (prefix sc: or secret:). Example: --env-value-from NAME=cm:myconfigmap:key or --env-value-from NAME=secret:mysecret:key. You can use this flag multiple times. To unset a value from a ConfigMap/Secret key reference, append "-" to the key, e.g. --env-value-from ENV-.
|
||||
--extra-containers string Deprecated, use --containers instead.
|
||||
-h, --help help for add
|
||||
--image string Image to run.
|
||||
--limit strings The resource requirement limits for this Service. For example, 'cpu=100m,memory=256Mi'. You can use this flag multiple times. To unset a resource limit, append "-" to the resource name, e.g. '--limit memory-'.
|
||||
|
|
|
|||
|
|
@ -33,18 +33,14 @@ kn service apply s0 --filename my-svc.yml
|
|||
--annotation-revision stringArray Revision annotation to set. name=value; you may provide this flag any number of times to set multiple annotations. To unset, specify the annotation name followed by a "-" (e.g., name-). This flag takes precedence over the "annotation" flag.
|
||||
--annotation-service stringArray Service annotation to set. name=value; you may provide this flag any number of times to set multiple annotations. To unset, specify the annotation name followed by a "-" (e.g., name-). This flag takes precedence over the "annotation" flag.
|
||||
--arg stringArray Add argument to the container command. Example: --arg myArg1 --arg --myArg2 --arg myArg3=3. You can use this flag multiple times.
|
||||
--autoscale-window string Deprecated option, please use --scale-window
|
||||
--cluster-local Specify that the service be private. (--no-cluster-local will make the service publicly available)
|
||||
--cmd stringArray Specify command to be used as entrypoint instead of default one. Example: --cmd /app/start or --cmd sh --cmd /app/start.sh or --cmd /app/start --arg myArg to pass additional arguments.
|
||||
--concurrency-limit int Hard Limit of concurrent requests to be processed by a single replica.
|
||||
--concurrency-target int Deprecated, use --scale-target instead.
|
||||
--concurrency-utilization int Deprecated, use --scale-utilization instead. (default 70)
|
||||
--containers string Specify path to file including definition for additional containers, alternatively use '-' to read from stdin. Example: --containers ./containers.yaml or --containers -.
|
||||
-e, --env stringArray Environment variable to set. NAME=value; you may provide this flag any number of times to set multiple environment variables. To unset, specify the environment variable name followed by a "-" (e.g., NAME-).
|
||||
--env-file string Path to a file containing environment variables (e.g. --env-file=/home/knative/service1/env).
|
||||
--env-from stringArray Add environment variables from a ConfigMap (prefix cm: or config-map:) or a Secret (prefix secret:). Example: --env-from cm:myconfigmap or --env-from secret:mysecret. You can use this flag multiple times. To unset a ConfigMap/Secret reference, append "-" to the name, e.g. --env-from cm:myconfigmap-.
|
||||
--env-value-from stringArray Add environment variable from a value of key in ConfigMap (prefix cm: or config-map:) or a Secret (prefix sc: or secret:). Example: --env-value-from NAME=cm:myconfigmap:key or --env-value-from NAME=secret:mysecret:key. You can use this flag multiple times. To unset a value from a ConfigMap/Secret key reference, append "-" to the key, e.g. --env-value-from ENV-.
|
||||
--extra-containers string Deprecated, use --containers instead.
|
||||
-f, --filename string Create a service from file. The created service can be further modified by combining with other options. For example, -f /path/to/file --env NAME=value adds also an environment variable.
|
||||
--force Create service forcefully, replaces existing service if any.
|
||||
-h, --help help for apply
|
||||
|
|
|
|||
|
|
@ -58,18 +58,14 @@ kn service create NAME --image IMAGE
|
|||
--annotation-revision stringArray Revision annotation to set. name=value; you may provide this flag any number of times to set multiple annotations. To unset, specify the annotation name followed by a "-" (e.g., name-). This flag takes precedence over the "annotation" flag.
|
||||
--annotation-service stringArray Service annotation to set. name=value; you may provide this flag any number of times to set multiple annotations. To unset, specify the annotation name followed by a "-" (e.g., name-). This flag takes precedence over the "annotation" flag.
|
||||
--arg stringArray Add argument to the container command. Example: --arg myArg1 --arg --myArg2 --arg myArg3=3. You can use this flag multiple times.
|
||||
--autoscale-window string Deprecated option, please use --scale-window
|
||||
--cluster-local Specify that the service be private. (--no-cluster-local will make the service publicly available)
|
||||
--cmd stringArray Specify command to be used as entrypoint instead of default one. Example: --cmd /app/start or --cmd sh --cmd /app/start.sh or --cmd /app/start --arg myArg to pass additional arguments.
|
||||
--concurrency-limit int Hard Limit of concurrent requests to be processed by a single replica.
|
||||
--concurrency-target int Deprecated, use --scale-target instead.
|
||||
--concurrency-utilization int Deprecated, use --scale-utilization instead. (default 70)
|
||||
--containers string Specify path to file including definition for additional containers, alternatively use '-' to read from stdin. Example: --containers ./containers.yaml or --containers -.
|
||||
-e, --env stringArray Environment variable to set. NAME=value; you may provide this flag any number of times to set multiple environment variables. To unset, specify the environment variable name followed by a "-" (e.g., NAME-).
|
||||
--env-file string Path to a file containing environment variables (e.g. --env-file=/home/knative/service1/env).
|
||||
--env-from stringArray Add environment variables from a ConfigMap (prefix cm: or config-map:) or a Secret (prefix secret:). Example: --env-from cm:myconfigmap or --env-from secret:mysecret. You can use this flag multiple times. To unset a ConfigMap/Secret reference, append "-" to the name, e.g. --env-from cm:myconfigmap-.
|
||||
--env-value-from stringArray Add environment variable from a value of key in ConfigMap (prefix cm: or config-map:) or a Secret (prefix sc: or secret:). Example: --env-value-from NAME=cm:myconfigmap:key or --env-value-from NAME=secret:mysecret:key. You can use this flag multiple times. To unset a value from a ConfigMap/Secret key reference, append "-" to the key, e.g. --env-value-from ENV-.
|
||||
--extra-containers string Deprecated, use --containers instead.
|
||||
-f, --filename string Create a service from file. The created service can be further modified by combining with other options. For example, -f /path/to/file --env NAME=value adds also an environment variable.
|
||||
--force Create service forcefully, replaces existing service if any.
|
||||
-h, --help help for create
|
||||
|
|
|
|||
|
|
@ -47,18 +47,14 @@ kn service update NAME
|
|||
--annotation-revision stringArray Revision annotation to set. name=value; you may provide this flag any number of times to set multiple annotations. To unset, specify the annotation name followed by a "-" (e.g., name-). This flag takes precedence over the "annotation" flag.
|
||||
--annotation-service stringArray Service annotation to set. name=value; you may provide this flag any number of times to set multiple annotations. To unset, specify the annotation name followed by a "-" (e.g., name-). This flag takes precedence over the "annotation" flag.
|
||||
--arg stringArray Add argument to the container command. Example: --arg myArg1 --arg --myArg2 --arg myArg3=3. You can use this flag multiple times.
|
||||
--autoscale-window string Deprecated option, please use --scale-window
|
||||
--cluster-local Specify that the service be private. (--no-cluster-local will make the service publicly available)
|
||||
--cmd stringArray Specify command to be used as entrypoint instead of default one. Example: --cmd /app/start or --cmd sh --cmd /app/start.sh or --cmd /app/start --arg myArg to pass additional arguments.
|
||||
--concurrency-limit int Hard Limit of concurrent requests to be processed by a single replica.
|
||||
--concurrency-target int Deprecated, use --scale-target instead.
|
||||
--concurrency-utilization int Deprecated, use --scale-utilization instead. (default 70)
|
||||
--containers string Specify path to file including definition for additional containers, alternatively use '-' to read from stdin. Example: --containers ./containers.yaml or --containers -.
|
||||
-e, --env stringArray Environment variable to set. NAME=value; you may provide this flag any number of times to set multiple environment variables. To unset, specify the environment variable name followed by a "-" (e.g., NAME-).
|
||||
--env-file string Path to a file containing environment variables (e.g. --env-file=/home/knative/service1/env).
|
||||
--env-from stringArray Add environment variables from a ConfigMap (prefix cm: or config-map:) or a Secret (prefix secret:). Example: --env-from cm:myconfigmap or --env-from secret:mysecret. You can use this flag multiple times. To unset a ConfigMap/Secret reference, append "-" to the name, e.g. --env-from cm:myconfigmap-.
|
||||
--env-value-from stringArray Add environment variable from a value of key in ConfigMap (prefix cm: or config-map:) or a Secret (prefix sc: or secret:). Example: --env-value-from NAME=cm:myconfigmap:key or --env-value-from NAME=secret:mysecret:key. You can use this flag multiple times. To unset a value from a ConfigMap/Secret key reference, append "-" to the key, e.g. --env-value-from ENV-.
|
||||
--extra-containers string Deprecated, use --containers instead.
|
||||
-h, --help help for update
|
||||
--image string Image to run.
|
||||
-l, --label stringArray Labels to set for both Service and Revision. name=value; you may provide this flag any number of times to set multiple labels. To unset, specify the label name followed by a "-" (e.g., name-).
|
||||
|
|
|
|||
|
|
@ -24,7 +24,6 @@ kn source container create NAME --image IMAGE --sink SINK
|
|||
--env-file string Path to a file containing environment variables (e.g. --env-file=/home/knative/service1/env).
|
||||
--env-from stringArray Add environment variables from a ConfigMap (prefix cm: or config-map:) or a Secret (prefix secret:). Example: --env-from cm:myconfigmap or --env-from secret:mysecret. You can use this flag multiple times. To unset a ConfigMap/Secret reference, append "-" to the name, e.g. --env-from cm:myconfigmap-.
|
||||
--env-value-from stringArray Add environment variable from a value of key in ConfigMap (prefix cm: or config-map:) or a Secret (prefix sc: or secret:). Example: --env-value-from NAME=cm:myconfigmap:key or --env-value-from NAME=secret:mysecret:key. You can use this flag multiple times. To unset a value from a ConfigMap/Secret key reference, append "-" to the key, e.g. --env-value-from ENV-.
|
||||
--extra-containers string Deprecated, use --containers instead.
|
||||
-h, --help help for create
|
||||
--image string Image to run.
|
||||
--limit strings The resource requirement limits for this Service. For example, 'cpu=100m,memory=256Mi'. You can use this flag multiple times. To unset a resource limit, append "-" to the resource name, e.g. '--limit memory-'.
|
||||
|
|
|
|||
|
|
@ -24,7 +24,6 @@ kn source container update NAME --image IMAGE
|
|||
--env-file string Path to a file containing environment variables (e.g. --env-file=/home/knative/service1/env).
|
||||
--env-from stringArray Add environment variables from a ConfigMap (prefix cm: or config-map:) or a Secret (prefix secret:). Example: --env-from cm:myconfigmap or --env-from secret:mysecret. You can use this flag multiple times. To unset a ConfigMap/Secret reference, append "-" to the name, e.g. --env-from cm:myconfigmap-.
|
||||
--env-value-from stringArray Add environment variable from a value of key in ConfigMap (prefix cm: or config-map:) or a Secret (prefix sc: or secret:). Example: --env-value-from NAME=cm:myconfigmap:key or --env-value-from NAME=secret:mysecret:key. You can use this flag multiple times. To unset a value from a ConfigMap/Secret key reference, append "-" to the key, e.g. --env-value-from ENV-.
|
||||
--extra-containers string Deprecated, use --containers instead.
|
||||
-h, --help help for update
|
||||
--image string Image to run.
|
||||
--limit strings The resource requirement limits for this Service. For example, 'cpu=100m,memory=256Mi'. You can use this flag multiple times. To unset a resource limit, append "-" to the resource name, e.g. '--limit memory-'.
|
||||
|
|
|
|||
|
|
@ -103,6 +103,7 @@ func (p *ConfigurationEditFlags) addSharedFlags(command *cobra.Command) {
|
|||
// DEPRECATED since 1.0
|
||||
command.Flags().StringVar(&p.ScaleWindow, "autoscale-window", "", "Deprecated option, please use --scale-window")
|
||||
p.markFlagMakesRevision("autoscale-window")
|
||||
command.Flags().MarkHidden("autoscale-window")
|
||||
|
||||
command.Flags().StringVar(&p.ScaleWindow, "scale-window", "", "Duration to look back for making auto-scaling decisions. The service is scaled to zero if no request was received in during that time. (eg: 10s)")
|
||||
p.markFlagMakesRevision("scale-window")
|
||||
|
|
@ -114,6 +115,7 @@ func (p *ConfigurationEditFlags) addSharedFlags(command *cobra.Command) {
|
|||
command.Flags().IntVar(&p.ScaleTarget, "concurrency-target", 0,
|
||||
"Deprecated, use --scale-target instead.")
|
||||
p.markFlagMakesRevision("concurrency-target")
|
||||
command.Flags().MarkHidden("concurrency-target")
|
||||
|
||||
command.Flags().IntVar(&p.ScaleTarget, "scale-target", 0,
|
||||
"Recommendation for when to scale up based on the concurrent number of incoming request. "+
|
||||
|
|
@ -128,6 +130,7 @@ func (p *ConfigurationEditFlags) addSharedFlags(command *cobra.Command) {
|
|||
command.Flags().IntVar(&p.ScaleUtilization, "concurrency-utilization", 70,
|
||||
"Deprecated, use --scale-utilization instead.")
|
||||
p.markFlagMakesRevision("concurrency-utilization")
|
||||
command.Flags().MarkHidden("concurrency-utilization")
|
||||
|
||||
command.Flags().IntVar(&p.ScaleUtilization, "scale-utilization", 70,
|
||||
"Percentage of concurrent requests utilization before scaling up.")
|
||||
|
|
|
|||
|
|
@ -132,6 +132,7 @@ func (p *PodSpecFlags) AddFlags(flagset *pflag.FlagSet) []string {
|
|||
// DEPRECATED since 1.0
|
||||
flagset.StringVarP(&p.ExtraContainers, "extra-containers", "", "",
|
||||
"Deprecated, use --containers instead.")
|
||||
flagset.MarkHidden("extra-containers")
|
||||
flagNames = append(flagNames, "containers")
|
||||
|
||||
flagset.StringVarP(&p.ExtraContainers, "containers", "", "",
|
||||
|
|
|
|||
Loading…
Reference in New Issue