用于libreoffice / openoffice的systemd服务脚本

我正在试图在debian jessie上正确设置一个无头 libreoffice / openoffice服务器。 我使用以下内容创build了名为/etc/systemd/system/openoffice.service的脚本

[Unit] Description=OpenOffice service After=syslog.target [Service] ExecStart=/usr/bin/soffice '--accept=socket,host=localhost,port=8101;urp;StarOffice.ServiceManager' --headless --nofirststartwizard --nologo Restart=always KillSignal=SIGQUIT Type=notify StandardError=syslog NotifyAccess=all User=www-data [Install] WantedBy=multi-user.target 

我启用它:

 systemctl enable openoffice.service 

我处于只是部分工作的情况:

我一直无法find一个工作的例子,我也想了解如何创build使用系统的debian /etc/init.d脚本…

您在服务中设置了Type=notify 。 这意味着只用于特定的服务,这些服务在完成启动时通知systemd 。 目前,这些都是不常见的,我不认为LibreOffice是其中之一。

你应该最有可能使用Type=simple来代替。