未验证 提交 86bf40d0 编写于 作者: sangshuduo's avatar sangshuduo 提交者: GitHub

docs: update cloud doc cli to replace url/token to dsn (#13890)

* docs: describe how tdengine cli connect to cloud.

* docs: fix install link mistake

* docs: fix install client driver link

* docs: refine 07-tools/01-cli.md

* docs: refine 07-tools/01-cli.md

* docs: fix code block

* docs: refine 07-tools/01-cli.md

* docs: refine 07-tools/01-cli.md

* docs: refine 07-tools/01-cli.md

* docs: refine docs-en/07-tools/01-cli.md

* docs: update 07-tools/01-cli.md

* docs: fix docs-en/07-tools/01-cli.md

* docs: update 01-cli.md to change url/token to dsn
上级 79ddaa72
...@@ -11,36 +11,33 @@ The TDengine command-line interface (hereafter referred to as `TDengine CLI`) is ...@@ -11,36 +11,33 @@ The TDengine command-line interface (hereafter referred to as `TDengine CLI`) is
## Installation ## Installation
To run TDengine CLI to access TDengine cloud, please install [TDengine client installation package](https://www.taosdata.com/assets-download/TDengine-client-2.6.0.2-Linux-x64.tar.gz) first. To run TDengine CLI to access TDengine cloud, please install [TDengine client installation package](https://www.taosdata.com/assets-download/TDengine-client-2.6.0.4-Linux-x64.tar.gz) first.
<Tabs defaultValue="ConfigOnLinux" groupId="sys"> <Tabs defaultValue="ConfigOnLinux" groupId="sys">
<TabItem value="ConfigOnLinux" label="Config on Linux"> <TabItem value="ConfigOnLinux" label="Config on Linux">
Run this command in your Linux terminal to save your URL and token as variables: Run this command in your Linux terminal to save your URL and token as variable:
``` ```
export TDENGINE_CLOUD_URL=<URL> export TDENGINE_CLOUD_DSN=<DSN>
export TDENGINE_CLOUD_TOKEN=<token>
``` ```
</TabItem> </TabItem>
<TabItem value="ConfigOnWindows" label="Config on Windows (coming soon)"> <TabItem value="ConfigOnWindows" label="Config on Windows (coming soon)">
Run this command in your Windows terminal to save your URL and token as variables: Run this command in your Windows terminal to save your URL and token as variable:
``` ```
set TDENGINE_CLOUD_URL=<URL> set TDENGINE_CLOUD_DSN=<DSN>
set TDENGINE_CLOUD_TOKEN=<token>
``` ```
</TabItem> </TabItem>
<TabItem value="ConfigOnMac" label="Config on Mac (coming soon)" groupId="sys"> <TabItem value="ConfigOnMac" label="Config on Mac (coming soon)" groupId="sys">
Run this command in your Mac terminal to save your URL and token as variables: Run this command in your Mac terminal to save your URL and token as variable:
``` ```
export TDENGINE_CLOUD_URL=<URL> export TDENGINE_CLOUD_DSN=<DSN>
export TDENGINE_CLOUD_TOKEN=<token>
``` ```
</TabItem> </TabItem>
...@@ -49,28 +46,46 @@ export TDENGINE_CLOUD_TOKEN=<token> ...@@ -49,28 +46,46 @@ export TDENGINE_CLOUD_TOKEN=<token>
<Tabs defaultValue="ConnectOnLinux" groupId="sys"> <Tabs defaultValue="ConnectOnLinux" groupId="sys">
<TabItem value="ConnectOnLinux" label="Connect on Linux"> <TabItem value="ConnectOnLinux" label="Connect on Linux">
To access the TDengine Cloud, you can execute below command from a Linux terminal. To access the TDengine Cloud, you can execute `taos` if you already set the environment variable.
``` ```
taos -R -h $TDENGINE_CLOUD_URL -t $TDENGINE_CLOUD_TOKEN taos
```
If you did not set environment variable for a TDengine Cloud instance, or you want to access other TDengine Cloud instances rather than the instance you already set the environment variable, you can use `taos -E <DSN>` as below.
```
taos -E $TDENGINE_CLOUD_DSN
``` ```
</TabItem> </TabItem>
<TabItem value="ConnectOnWindows" label="Connect on Windows (coming soon)"> <TabItem value="ConnectOnWindows" label="Connect on Windows (coming soon)">
To access the TDengine Cloud, you can execute below command from a Windows terminal. To access the TDengine Cloud, you can execute `taos` if you already set the environment variable.
``` ```
taos -R -h %TDENGINE_CLOUD_URL% -t %TDENGINE_CLOUD_TOKEN% taos
```
If you did not set environment variable for a TDengine Cloud instance, or you want to access other TDengine Cloud instances rather than the instance you already set the environment variable, you can use `taos -E <DSN>` as below.
```
taos.exe -E $TDENGINE_CLOUD_DSN
``` ```
</TabItem> </TabItem>
<TabItem value="ConnectOnMac" label="Connect on Mac (coming soon)"> <TabItem value="ConnectOnMac" label="Connect on Mac (coming soon)">
To access the TDengine Cloud, you can execute below command from a Mac terminal. To access the TDengine Cloud, you can execute `taos` if you already set the environment variable.
```
taos
```
If you did not set environment variable for a TDengine Cloud instance, or you want to access other TDengine Cloud instances rather than the instance you already set the environment variable, you can use `taos -E <DSN>` as below.
``` ```
taos -R -h $TDENGINE_CLOUD_URL -t $TDENGINE_CLOUD_TOKEN taos -E $TDENGINE_CLOUD_DSN
``` ```
</TabItem> </TabItem>
...@@ -82,9 +97,11 @@ TDengine CLI will display a welcome message and version information if it succes ...@@ -82,9 +97,11 @@ TDengine CLI will display a welcome message and version information if it succes
```cmd ```cmd
Welcome to the TDengine shell from Linux, Client Version:2.6.0.2 Welcome to the TDengine shell from Linux, Client Version:2.6.0.4
Copyright (c) 2022 by TAOS Data, Inc. All rights reserved. Copyright (c) 2022 by TAOS Data, Inc. All rights reserved.
Successfully connect to cloud.tdengine.com:8085 in restful mode
taos> taos>
``` ```
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册