IzakMarais / reporter

Service that generates a PDF report from a Grafana dashboard
Apache License 2.0
963 stars 309 forks source link

Where ouput pdf files are saved? #295

Closed luckyluke3423 closed 3 years ago

luckyluke3423 commented 3 years ago

Hi everyone, I pulled docker image and run the container as command line like the command below on a Red Hat 7.9 machine. Everything looks fine in the output logs but cannot find the output pdf file. Could you please help me?

Run Command:
docker run izakmarais/grafana-reporter -cmd_enable=1 -cmd_apiKey xxxxx -ip grafana_host:80 -cmd_dashboard 463Ezd2Gz -cmd_ts 'from=now-2h&to=now' -cmd_o '/tmp/eyup.pdf'

output logs: 2021/05/07 14:22:36 grafana reporter, version: 2.3-1 hash: 6cfc3e220dc4f8fc0175ae0ec8698d35546d8c10 2021/05/07 14:22:36 serving at ':8686' and using grafana at 'http://grafana_host:80' 2021/05/07 14:22:36 SSL check enforced 2021/05/07 14:22:36 Using sequential report layout. Consider enabling 'grid-layout' so that your report more closely follow the dashboard layout. 2021/05/07 14:22:36 Called with command line mode enabled, will save report to file and exit. 2021/05/07 14:22:36 Called with command line mode 'dashboard' '463Ezd2Gz' 2021/05/07 14:22:36 Called with command line mode 'apiKey' 'xxxxx' 2021/05/07 14:22:36 Called with command line mode 'apiVersion' 'v5' 2021/05/07 14:22:36 Called with command line mode 'outputFile' '/tmp/eyup.pdf' 2021/05/07 14:22:36 Called with command line mode 'timeSpan' 'from=now-2h&to=now' 2021/05/07 14:22:36 Reporter called 2021/05/07 14:22:36 Called with api Token: xxxxx 2021/05/07 14:22:36 Called without variable 2021/05/07 14:22:36 Called with dashboard: 463Ezd2Gz 2021/05/07 14:22:36 Called with time range: {now-2h now} 2021/05/07 14:22:36 Connecting to dashboard at http://grafana_host:80/api/dashboards/uid/463Ezd2Gz 2021/05/07 14:22:36 Populated dashboard datastructure: {Title:PKS Resource Dashboard Description:jmx exporter monitor VariableValues: Rows:[] Panels:[{Id:125 Type:graph Title:Cluster Avarage Memory Usage GridPos:{H:5 W:10 X:0 Y:1}} {Id:143 Type:graph Title:Cluster Avarage Memory Usage GridPos:{H:5 W:10 X:10 Y:1}} {Id:134 Type:singlestat Title:Total Node Count GridPos:{H:5 W:4 X:20 Y:1}} {Id:112 Type:gauge Title:\$node GridPos:{H:3 W:6 X:0 Y:6}} {Id:182 Type:gauge Title:\$node GridPos:{H:3 W:6 X:6 Y:6}} {Id:183 Type:gauge Title:\$node GridPos:{H:3 W:6 X:12 Y:6}} {Id:184 Type:gauge Title:\$node GridPos:{H:3 W:6 X:18 Y:6}} {Id:185 Type:gauge Title:\$node GridPos:{H:3 W:6 X:0 Y:9}} {Id:186 Type:gauge Title:\$node GridPos:{H:3 W:6 X:6 Y:9}} {Id:187 Type:gauge Title:\$node GridPos:{H:3 W:6 X:12 Y:9}} {Id:188 Type:gauge Title:\$node GridPos:{H:3 W:6 X:18 Y:9}} {Id:189 Type:gauge Title:\$node GridPos:{H:3 W:6 X:0 Y:12}} {Id:190 Type:gauge Title:\$node GridPos:{H:3 W:6 X:6 Y:12}} {Id:191 Type:gauge Title:\$node GridPos:{H:3 W:6 X:12 Y:12}} {Id:192 Type:gauge Title:\$node GridPos:{H:3 W:6 X:18 Y:12}} {Id:181 Type:graph Title:Cluster Avarage Memory Usage GridPos:{H:5 W:24 X:0 Y:16}} {Id:158 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:0 Y:21}} {Id:193 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:6 Y:21}} {Id:194 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:12 Y:21}} {Id:195 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:18 Y:21}} {Id:196 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:0 Y:24}} {Id:197 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:6 Y:24}} {Id:198 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:12 Y:24}} {Id:199 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:18 Y:24}} {Id:200 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:0 Y:27}} {Id:201 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:6 Y:27}} {Id:202 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:12 Y:27}} {Id:203 Type:gauge Title:CPU - \$nodename GridPos:{H:3 W:6 X:18 Y:27}}]} 2021/05/07 14:22:36 Downloading image 143 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=143&theme=light&to=now&width=1000 2021/05/07 14:22:36 Downloading image 125 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=125&theme=light&to=now&width=1000 2021/05/07 14:22:36 Downloading image 134 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=150&panelId=134&theme=light&to=now&width=300 2021/05/07 14:22:36 Downloading image 112 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=112&theme=light&to=now&width=1000 2021/05/07 14:22:36 Downloading image 182 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=182&theme=light&to=now&width=1000 2021/05/07 14:22:42 Downloading image 183 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=183&theme=light&to=now&width=1000 2021/05/07 14:22:42 Downloading image 184 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=184&theme=light&to=now&width=1000 2021/05/07 14:22:42 Downloading image 185 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=185&theme=light&to=now&width=1000 2021/05/07 14:22:42 Downloading image 186 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=186&theme=light&to=now&width=1000 2021/05/07 14:22:42 Downloading image 187 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=187&theme=light&to=now&width=1000 2021/05/07 14:22:46 Downloading image 188 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=188&theme=light&to=now&width=1000 2021/05/07 14:22:46 Downloading image 189 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=189&theme=light&to=now&width=1000 2021/05/07 14:22:47 Downloading image 190 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=190&theme=light&to=now&width=1000 2021/05/07 14:22:47 Downloading image 191 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=191&theme=light&to=now&width=1000 2021/05/07 14:22:48 Downloading image 192 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=192&theme=light&to=now&width=1000 2021/05/07 14:22:52 Downloading image 181 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=181&theme=light&to=now&width=1000 2021/05/07 14:22:53 Downloading image 158 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=158&theme=light&to=now&width=1000 2021/05/07 14:22:54 Downloading image 193 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=193&theme=light&to=now&width=1000 2021/05/07 14:22:54 Downloading image 194 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=194&theme=light&to=now&width=1000 2021/05/07 14:22:54 Downloading image 195 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=195&theme=light&to=now&width=1000 2021/05/07 14:22:56 Downloading image 196 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=196&theme=light&to=now&width=1000 2021/05/07 14:22:57 Downloading image 197 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=197&theme=light&to=now&width=1000 2021/05/07 14:22:58 Downloading image 198 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=198&theme=light&to=now&width=1000 2021/05/07 14:22:59 Downloading image 199 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=199&theme=light&to=now&width=1000 2021/05/07 14:23:00 Downloading image 200 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=200&theme=light&to=now&width=1000 2021/05/07 14:23:02 Downloading image 201 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=201&theme=light&to=now&width=1000 2021/05/07 14:23:03 Downloading image 202 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=202&theme=light&to=now&width=1000 2021/05/07 14:23:03 Downloading image 203 http://grafana_host:80/render/d-solo/463Ezd2Gz/_?from=now-2h&height=500&panelId=203&theme=light&to=now&width=1000 2021/05/07 14:23:07 Calling LaTeX - preprocessing 2021/05/07 14:23:09 Calling LaTeX and building PDF 2021/05/07 14:23:09 Extracted filename from dashboard title: PKS Resource Dashboard.pdf 2021/05/07 14:23:09 Report generated correctly

luckyluke3423 commented 3 years ago

Found. In is written in the docker /tmp directory.