From d476c34a5b3f15a637debc4d9c8d67a060f66057 Mon Sep 17 00:00:00 2001 From: Huo Linhe Date: Sat, 11 Jun 2022 19:32:06 +0800 Subject: [PATCH] docs(Grafana): add more variables docs for Grafana Ref [TD-16448](https://jira.taosdata.com:18080/browse/TD-16448) --- docs-cn/20-third-party/01-grafana.mdx | 12 ++++++++++++ docs-en/20-third-party/01-grafana.mdx | 12 +++++++++++- 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/docs-cn/20-third-party/01-grafana.mdx b/docs-cn/20-third-party/01-grafana.mdx index 31cd434080..09c0d786cf 100644 --- a/docs-cn/20-third-party/01-grafana.mdx +++ b/docs-cn/20-third-party/01-grafana.mdx @@ -38,6 +38,16 @@ export TDENGINE_API=http://tdengine.local:6041 # user + password export TDENGINE_USER=user export TDENGINE_PASSWORD=password + +# 其他环境变量: +# - 是否安装数据源,默认为 true,表示安装 +export TDENGINE_DS_ENABLED=false +# - 数据源名称,默认为 TDengine +export TDENGINE_DS_NAME=TDengine +# - 数据源所属组织 ID,默认为 1 +export GF_ORG_ID=1 +# - 数据源是否可通过管理面板编辑,默认为 0,表示不可编辑 +export TDENGINE_EDITABLE=1 ``` 运行安装脚本: @@ -48,6 +58,8 @@ bash -c "$(curl -fsSL https://raw.githubusercontent.com/taosdata/grafanaplugin/m 该脚本将自动安装 Grafana 插件并配置数据源。安装完毕后,需要重启 Grafana 服务后生效。 +保存该脚本并执行 `./install.sh --help` 可查看详细帮助文档。 + diff --git a/docs-en/20-third-party/01-grafana.mdx b/docs-en/20-third-party/01-grafana.mdx index 033ef3b206..9076f163be 100644 --- a/docs-en/20-third-party/01-grafana.mdx +++ b/docs-en/20-third-party/01-grafana.mdx @@ -40,6 +40,16 @@ export TDENGINE_API=http://tdengine.local:6041 # user + password export TDENGINE_USER=user export TDENGINE_PASSWORD=password + +# Other useful variables +# - If to install TDengine data source, default is true +export TDENGINE_DS_ENABLED=false +# - Data source name to be created, default is TDengine +export TDENGINE_DS_NAME=TDengine +# - Data source organization id, default is 1 +export GF_ORG_ID=1 +# - Data source is editable in admin ui or not, default is 0 (false) +export TDENGINE_EDITABLE=1 ``` Run `install.sh`: @@ -48,7 +58,7 @@ Run `install.sh`: bash -c "$(curl -fsSL https://raw.githubusercontent.com/taosdata/grafanaplugin/master/install.sh)" ``` -With this script, TDengine data source plugin and the Grafana data source will be installed and created automatically with Grafana provisioning configurations. +With this script, TDengine data source plugin and the Grafana data source will be installed and created automatically with Grafana provisioning configurations. Save the script and type `./install.sh --help` for the full usage of the script. And then, restart Grafana service and open Grafana in web-browser, usually . -- GitLab