test.service 591 B

123456789101112131415161718192021222324
  1. [Unit]
  2. Description=My Service
  3. Documentation=https://example.com/docs/my-service.html
  4. #After=/home/heyicong/DragonReach/parse_test/test1.service
  5. #OnFailure=/home/heyicong/DragonReach/parse_test/test1.service
  6. [Service]
  7. Type=simple
  8. ExecStart=/bin/gdb
  9. #ExecStartPos=/bin/echo start_pos
  10. #ExecStartPre=/bin/echo start_pre
  11. #ExecStopPost=/bin/echo stop_pos
  12. #ExecReload=/bin/echo reload
  13. WorkingDirectory=/home/heyicong/
  14. User=myuser
  15. Group=mygroup
  16. Environment=VAR1=value1
  17. Environment=VAR2=value2
  18. Restart=always
  19. RestartSec=1s
  20. TimeoutStartSec=10s
  21. TimeoutStopSec=5s
  22. [Install]
  23. #WantedBy=multi-user.target