mirror of
https://github.com/SCST-project/scst.git
synced 2026-08-16 12:16:17 +00:00
debian, scstadmin: Add systemd scst.service
Add systemd service file when packaging for Debian. Current systemd will automatically generate one, but this functionality will be removed in a future version of systemd.
This commit is contained in:
Vendored
+1
@@ -90,6 +90,7 @@ install:
|
||||
mv "$(DESTDIR)"/usr/man "$(DESTDIR)"/usr/share/man && \
|
||||
dh_install && \
|
||||
dh_installman && \
|
||||
dh_installsystemd --name=scst --no-start && \
|
||||
dh_installchangelogs && \
|
||||
dh_compress && \
|
||||
dh_fixperms && \
|
||||
|
||||
Vendored
+1
@@ -1,4 +1,5 @@
|
||||
etc/init.d/scst
|
||||
lib/systemd/system/scst.service
|
||||
usr/sbin/scstadmin
|
||||
usr/share/perl/
|
||||
usr/lib/
|
||||
|
||||
@@ -110,6 +110,12 @@ install install_vendor:
|
||||
mkdir -p $(DESTDIR)$(DEFAULTDIR); \
|
||||
install -m 755 default/scst $(DESTDIR)$(DEFAULTDIR); \
|
||||
fi
|
||||
# Install systemd service file
|
||||
if [ -d systemd ]; then \
|
||||
install -d $(DESTDIR)/lib/systemd/system; \
|
||||
install -m 644 systemd/scst.service \
|
||||
$(DESTDIR)/lib/systemd/system/scst.service; \
|
||||
fi
|
||||
for s in iscsi-scst qla2x00t; do \
|
||||
{ $(call REMOVE_FN,$$s); } >/dev/null 2>&1; \
|
||||
done
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
[Unit]
|
||||
Description=SCST - A Generic SCSI Target Subsystem
|
||||
Documentation=man:scstadmin(1) man:scst.conf(5)
|
||||
After=network-online.target local-fs.target
|
||||
Wants=network-online.target
|
||||
DefaultDependencies=no
|
||||
Before=shutdown.target
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
RemainAfterExit=yes
|
||||
EnvironmentFile=-/etc/default/scst
|
||||
ExecStart=/etc/init.d/scst start
|
||||
ExecStop=/etc/init.d/scst stop
|
||||
ExecReload=/etc/init.d/scst reload
|
||||
TimeoutStartSec=5min
|
||||
TimeoutStopSec=5min
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Reference in New Issue
Block a user