K6 InfluxDB + Grafana Docker:如何预加载仪表板 [英] K6 InfluxDB + Grafana Docker : How to preload a dashboard
问题描述
我正在使用K6进行负载测试.
I am using K6 for Load Testing.
我已经从此处克隆了K6,Grafana,InfluxDB docker-comset设置:
I have cloned the K6, Grafana, InfluxDB docker-compose set up from here:
https://github.com/loadimpact/k6
每次启动Grafana时,我都必须手动导入要使用的仪表板(导入"-ID2587-加载).
Each time I start Grafana, I have to manually import the dashboard I want to use ('Import' - ID2587 - Load).
我是Docker(和Grafana!)的新手....是否有将这个仪表板预加载到容器中的消息,所以我不必每次都手动添加它?
I am new to Docker (and Grafana!)....is there anyway to have this dashboard preloaded in the container so I don't have to manually add it each time?
推荐答案
将您的仪表板和数据源安装到grafana容器中
运行docker-compose up -d influxdb grafana
时
请参阅docker-compose文件和grafana文件夹此处
mount your dashboard and datasources into grafana container
when running docker-compose up -d influxdb grafana
refer the docker-compose file and grafana folder here
并确保使用您在datasource.yml中提到的数据源名称更新了dashboard.json中的数据源
And make sure the datasource in your dashboard.json is updated with name of the datasource mentioned in datasource.yml
我在k6中创建了一个小教程社区.希望这能解决您的情况.
I have created a small tutorial in k6 community. Hope this solves your case.
这篇关于K6 InfluxDB + Grafana Docker:如何预加载仪表板的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!