Open 0lIvIa09 opened 3 months ago
It should work with multiple organisations. The plugin shouldn't have any limitations with multi org setup.
Do you have any issues with multi org setup? If so, please report them here so we can try to fix them.
I haven't tried it as of yet. Do I just add another block in the reporter.yml file with another org, like so:
apps:
- type: mahendrapaipuri-dashboardreporter-app
org_id: 32
org_name: Test
disabled: false
org_id: 33
org_name: Test 2
Also I have another question about the logo. It is base64 encoded, but shows up like this on my generated report. Is there anything I'm doing wrong?
Provisioning should be rather like below:
apps:
- type: mahendrapaipuri-dashboardreporter-app
org_id: 1
org_name: Main Org.
disabled: false
jsonData:
appUrl: http://localhost:3000
- type: mahendrapaipuri-dashboardreporter-app
org_id: 2
org_name: Main Org.
disabled: false
jsonData:
appUrl: http://localhost:3000
About the logo, the encoding should be of a PNG file. If you still have issues, you can enable Persist Data Files
in plugin config in Grafana UI which will save all the templated HTML files in $GRAFANA_PATH_DATA/reports/debug
folder and there you can inspect the footer.html
if logo has been correctly embedded or not.
I enabled the Persist Data Files, but no footer.html is created only report.html. I am encoding a PNG file and putting its path in the report.yml file like /etc/grafana/provisioning/plugins/logo.
Yeah, you are right. There wont be any footer.html
file. The templated footer will be passed to chromium
directly without saving to filesystem.
You will to put the actual encoded string in the report.yml
file. For example it would be somthing like
apps:
- type: mahendrapaipuri-dashboardreporter-app
org_id: 1
org_name: Main Org.
disabled: false
jsonData:
appUrl: http://localhost:3000
logo: iVBORw0KGgoAAAANSUhEUgAAABcAAAAXCAYAAADgKtSgAAAAAXNSR0IArs4c6QAAAAlwSFlzAAASdAAAEnQB3mYfeAAAABl0RVh0U29mdHdhcmUATWljcm9zb2Z0IE9mZmljZX/tNXEAAAVbSURBVEhLbVVdbFRFFP7mzty9+9N2W4NIqQq2pRSt+OS/IMS/8EAMEtTEYOKLIT7x4oMPZLNBY2LiC09qYngwJhoIiRhDCKIhNIRISEAKpaWlLVBopZXdbXe3vT8zfnO3W37sZCd378zcc77znW/OUfl8HkuN3LjX6KBlo9TO6zDYZIzp4rk0hJgVBgNCi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XOYxnap0Ue+QU40TGlVWOvE8wMI+F1sYiwlviYCTRODNzEXBjGN3SSNJwYuIXR6TLGChUY1pt+KuXgmWGcG5vm+VoNguL3mimM/P7QaT+j8m39xb0jyw8Y464XiXSb9HyUmLiDp4dw9OxI/H+WCH88ORCraHqOlTKZwOmhSQxen0aZhu0Z6ZEOlxL1q9dkgJ/y7acqceEKE8VflE49SfHuEplsQ1guYqpYwZSlhYgEpThZLhMVQ6cyFLmfqTLCAtfIu0NnTibLfV0UOvzB9/QRazc2nm+b/zc3Nv+dDHRGqOROJ9Pc4LjsXPfW87RN1AK3RpMBJsJlc1Je7anDEmvL/nC+/D3r+cyi8djBqokr7ERfwzMV46a2C0ethscPbSeyThZqT+zA5oZ3r3Y9mNQoHBZh5YAqF7/ds1Qnsg72dBaGc32te1XmzkXqjD002UUFZDlZeyhVNlB7tymROa6VaJVog4tSzx/yVfHwnu75GHF9/K9B53v6i9zcz0Z9wMlW2f0pUyFetbXCXmkIU+UFGRB+wO4vFrr/P0t2//8A3e1remyXHJwAAAAASUVORK5CYII=
You dont need to include the header data:image/png;base64
as it will be included automatically by the plugin.
Thanks the logo appears now. The issue was that I put the path to the base64 encoded file in report.yml instead of just the encoded string. Is there any way I can make the logo any bigger?
Is there any way I can make the logo any bigger?
Unfortunately, no. As placing panel PNGs in the report is always tricky with CSS magic, the logo size is hard coded to the size of footer to avoid distortions.
Hi, how do I customise the text in the report. What file do I make this change in?
Hey, there is no way to customize the report content as of now. There are few features in pipeline that can allow the users to be able to do this.
If I may know your use case, what exactly you would like to change? This helps us to better draft the feature.
I am looking to add like a cover page to the report with my logo, name, title of the report etc. Also maybe customise the text at the top of every page so that it doesn't show and only the images are on the pages.
We will definitely allow the users to customize the header and footer of the report so that you can remove the title from each page. Regarding the cover page, we will look into it if we can support it. If not you can generate the cover page with third party tools and merge it with generated report.
Hi, does this plugin work with multiple organisations within Grafana, or is only one org supported?