trojan.service.j2 356 B

1234567891011121314151617
  1. [Unit]
  2. Description=Trojan-Go Server
  3. After=network.target
  4. [Service]
  5. Type=simple
  6. User={{ trojan_user }}
  7. Group={{ trojan_user }}
  8. ExecStart={{ trojan_bin_path }} -config {{ trojan_config_path }}
  9. ExecReload=/bin/kill -HUP $MAINPID
  10. Restart=on-failure
  11. RestartSec=5
  12. LimitNOFILE=65536
  13. AmbientCapabilities=CAP_NET_BIND_SERVICE
  14. [Install]
  15. WantedBy=multi-user.target