#!/sbin/openrc-run # # !!! This file is managed by Ansible !!! # name=$RC_SVCNAME command=/usr/bin/syncthing {% if services.syncthing.guiAddress is defined %} command_args="-no-browser -gui-address={{ services.syncthing.guiAddress }}" {% else %} command_args="-no-browser" {% endif %} command_user="{{ services.syncthing.user }}:{{ services.syncthing.user }}" pidfile=/run/${RC_SVCNAME}.pid command_background=yes start_stop_daemon_args="--stdout /var/log/$RC_SVCNAME/${RC_SVCNAME}.log --stderr /var/log/$RC_SVCNAME/${RC_SVCNAME}.log" depend() { use logger dns need net after firewall } start_pre() { checkpath --directory --owner $command_user --mode 0775 \ /var/log/$RC_SVCNAME }