summarylogtreecommitdiffstats
path: root/asterisk.service
blob: 284477f2bcae466127f17ce633264f227fb8f3e7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
[Unit]
Description=Asterisk PBX and telephony daemon
Documentation=man:asterisk(8)
Wants=network.target
After=network.target

[Service]
Type=simple
User=asterisk
Group=asterisk
ExecStart=/usr/bin/asterisk -f -C /etc/asterisk/asterisk.conf
ExecStop=/usr/bin/asterisk -rx 'core stop now'
ExecReload=/usr/bin/asterisk -rx 'core reload'

# safe_asterisk emulation
Restart=on-failure
RestartSec=10
RestartPreventExitStatus=0

[Install]
WantedBy=multi-user.target