Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
################################################################################

APP_NAME = kbcli
VERSION ?= 0.9.0-alpha.0
VERSION ?= 1.0.1-beta.0
GITHUB_PROXY ?=
GIT_COMMIT = $(shell git rev-list -1 HEAD)
GIT_VERSION = $(shell git describe --always --abbrev=0 --tag)
Expand Down
79 changes: 0 additions & 79 deletions docs/user_docs/cli/kbcli_cluster_create_oriol.md

This file was deleted.

75 changes: 0 additions & 75 deletions docs/user_docs/cli/kbcli_cluster_create_tidb.md

This file was deleted.

58 changes: 58 additions & 0 deletions docs/user_docs/cli/kbcli_cluster_upgrade-to-v1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
---
title: kbcli cluster upgrade-to-v1
---

upgrade cluster to v1 api version.

```
kbcli cluster upgrade-to-v1 [NAME] [flags]
```

### Examples

```
# upgrade a v1alpha1 cluster to v1 cluster
kbcli cluster upgrade-to-v1 mycluster

# upgrade a v1alpha1 cluster with --dry-run
kbcli cluster upgrade-to-v1 mycluster --dry-run
```

### Options

```
--dry-run dry run mode
-h, --help help for upgrade-to-v1
--no-diff only print the new cluster yaml
```

### Options inherited from parent commands

```
--as string Username to impersonate for the operation. User could be a regular user or a service account in a namespace.
--as-group stringArray Group to impersonate for the operation, this flag can be repeated to specify multiple groups.
--as-uid string UID to impersonate for the operation.
--cache-dir string Default cache directory (default "$HOME/.kube/cache")
--certificate-authority string Path to a cert file for the certificate authority
--client-certificate string Path to a client certificate file for TLS
--client-key string Path to a client key file for TLS
--cluster string The name of the kubeconfig cluster to use
--context string The name of the kubeconfig context to use
--disable-compression If true, opt-out of response compression for all requests to the server
--insecure-skip-tls-verify If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure
--kubeconfig string Path to the kubeconfig file to use for CLI requests.
--match-server-version Require server version to match client version
-n, --namespace string If present, the namespace scope for this CLI request
--request-timeout string The length of time to wait before giving up on a single server request. Non-zero values should contain a corresponding time unit (e.g. 1s, 2m, 3h). A value of zero means don't timeout requests. (default "0")
-s, --server string The address and port of the Kubernetes API server
--tls-server-name string Server name to use for server certificate validation. If it is not provided, the hostname used to contact the server is used
--token string Bearer token for authentication to the API server
--user string The name of the kubeconfig user to use
```

### SEE ALSO

* [kbcli cluster](kbcli_cluster.md) - Cluster command.

#### Go Back to [CLI Overview](cli.md) Homepage.

10 changes: 6 additions & 4 deletions pkg/cmd/report/report.go
Original file line number Diff line number Diff line change
Expand Up @@ -437,10 +437,12 @@ func (o *reportClusterOptions) complete(f cmdutil.Factory) error {
if err := o.reportOptions.complete(f); err != nil {
return err
}
// update namespace
o.namespace, _, err = f.ToRawKubeConfigLoader().Namespace()
if err != nil {
return err
// update namespace if not specified
if o.namespace == "" {
o.namespace, _, err = f.ToRawKubeConfigLoader().Namespace()
if err != nil {
return err
}
}
// complete file name

Expand Down
Loading