A simple TicTacToe app with Golang backend and WebSockets gluing it all together.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
694 B

  1. [Unit]
  2. Description=TicTacToe API service
  3. ConditionPathExists=/root/go/src/tictactoe-api
  4. After=network.target
  5. [Service]
  6. Type=simple
  7. User=root
  8. Group=root
  9. LimitNOFILE=1024
  10. Environment="GIN_MODE=release"
  11. Restart=on-failure
  12. RestartSec=10
  13. WorkingDirectory=/root/go/src/tictactoe-api
  14. ExecStart=/bin/bash -c "/root/go/src/tictactoe-api/tictactoe-api"
  15. # make sure log directory exists and owned by syslog
  16. PermissionsStartOnly=true
  17. ExecStartPre=/bin/mkdir -p /var/log/tictactoeapi
  18. ExecStartPre=/bin/chown syslog:adm /var/log/tictactoeapi
  19. ExecStartPre=/bin/chmod 755 /var/log/tictactoeapi
  20. StandardOutput=syslog
  21. StandardError=syslog
  22. SyslogIdentifier=tictactoeapi
  23. [Install]
  24. WantedBy=multi-user.target