blob: d4a075dd9d6dd3c786a19bf7fdf1f53c4b7a2fac (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
# This file is derived from the default unit file for shadowsocks-rust.
# This is the user-specific version of this unit.
#
# Users should create a new directory under $XDG_CONFIG_HOME/shadowsocks-rust/local
# as the profile directory and place a "ss.json5" file under it.
#
# For example, if you want to name your profile "foo", you should have
# the following directory structure:
#
# $XDG_CONFIG_HOME/shadowsocks-rust/local/foo
# └─ ss.json5
#
# You can now enable your service like this:
#
# systemctl --user enable --now shadowsocks-rust-local@foo.service
[Unit]
Description=Shadowsocks-rust Local Client Service for %I
Documentation=https://github.com/shadowsocks/shadowsocks-rust
After=network.target
StartLimitIntervalSec=30s
StartLimitBurst=5
[Service]
Type=simple
WorkingDirectory=%E/shadowsocks-rust/local/%i
ExecStart=/usr/bin/sslocal --log-without-time -c ss.json5
Restart=always
RestartSec=3s
[Install]
WantedBy=default.target
|