1
0
Fork 0
mirror of https://github.com/roles-ansible/role-grafana-kiosk.git synced 2024-08-16 10:09:49 +02:00

improve systemd file

This commit is contained in:
L3D 2020-07-02 14:33:02 +02:00 committed by L3D
parent ff747b4ffb
commit e55d16a9be
No known key found for this signature in database
GPG key ID: 5215C3441797AB2B
2 changed files with 10 additions and 7 deletions

View file

@ -1,18 +1,21 @@
[Unit]
Description=Grafana Kiosk
Documentation=https://github.com/grafana/grafana-kiosk.git
Documentation=https://grafana.com/blog/2019/05/02/grafana-tutorial-how-to-create-kiosks-to-display-dashboards-on-a-tv
Documentation=https://github.com/DO1JLR/role-grafana-kiosk.git
Documentation=https://github.com/grafana/grafana-kiosk.git
After=network.target
[Service]
User={{ grafana_kiosk.user }}
Restart = always
RestartSec=5s
Type=simple
Environment="{{ grafana_kiosk.display }}"
{% if not grafana_kiosk.general.autofit | bool -%}
Enviroment="KIOSK_AUTOFIT={{ grafana_kiosk.general.autofit | ternary("true", "false") }}"
{%- endif %}
Environment="XAUTHORITY=/home/{{ grafana_kiosk.user }}/.Xauthority"
ExecStart=/usr/bin/grafana-kiosk -c /etc/grafana-kiosk/config.yml
ExecStart=
{%- if not grafana_kiosk.general.autofit | bool -%}
KIOSK_AUTOFIT={{ grafana_kiosk.general.autofit | ternary("true", "false") }}{{ ' ' }}
{%- endif -%}
/usr/bin/grafana-kiosk -c /etc/grafana-kiosk/config.yml
[Install]
WantedBy=graphical.target

View file

@ -32,5 +32,5 @@ _dl_matrix:
'armv6l': "grafana-kiosk.linux.armv6"
'armv5l': "grafana-kiosk.linux.armv5"
playbook_version_number: 12 # should be an integer
playbook_version_number: 13 # should be an integer
playbook_version_path: 'role-grafana-kiosk_roles-ansible_github.com.version' # unique string