| {# |
| SPDX-FileCopyrightText: © 2020 Open Networking Foundation <support@opennetworking.org> |
| SPDX-License-Identifier: Apache-2.0 |
| #} |
| # /etc/systemd/system/timesheetsdb |
| # {{ ansible_managed }} |
| [Unit] |
| Description=Timesheets DB Service |
| Documentation=https://github.com/opennetworkinglab/timesheetsdb |
| After=network-online.target |
| Wants=network-online.target |
| |
| [Service] |
| Type=simple |
| |
| User={{ timesheets_username }} |
| Group={{ timesheets_groupname }} |
| |
| EnvironmentFile=/etc/default/timesheetsdb |
| WorkingDirectory={{ timesheets_dir }}/db |
| ExecStart=/usr/bin/npm run start:prod |
| |
| Restart=on-failure |
| RestartSec=30 |
| PrivateTmp=true |
| |
| [Install] |
| WantedBy=multi-user.target |