소스 검색

add systemctl service file

zfl9 8 년 전
부모
커밋
19dbbf9ccd
1개의 변경된 파일16개의 추가작업 그리고 0개의 파일을 삭제
  1. 16 0
      ss-tproxy.service

+ 16 - 0
ss-tproxy.service

@@ -0,0 +1,16 @@
+[Unit]
+Description=ss-tproxy
+ConditionFileIsExecutable=/usr/local/bin/ss-tproxy
+ConditionFileNotEmpty=/etc/tproxy/ss-tproxy.conf
+Requires=network-online.target haveged.service
+After=network-online.target haveged.service
+
+[Service]
+Type=oneshot
+ExecStart=/usr/local/bin/ss-tproxy start
+ExecStop=/usr/local/bin/ss-tproxy stop
+ExecReload=/usr/local/bin/ss-tproxy restart
+RemainAfterExit=yes
+
+[Install]
+WantedBy=multi-user.target