gogs.service 568 B

12345678910111213141516171819202122232425
  1. [Unit]
  2. Description=Gogs
  3. After=syslog.target
  4. After=network.target
  5. After=mariadb.service
  6. [Service]
  7. Type=simple
  8. User=git
  9. Group=git
  10. WorkingDirectory=/opt/gogs
  11. ExecStart=/opt/gogs/gogs web
  12. Restart=always
  13. Environment=USER=git HOME=/opt/gogs
  14. AmbientCapabilities=CAP_NET_BIND_SERVICE
  15. # Some distributions may not support these hardening directives. If you cannot start th>
  16. # to an unknown option, comment out the ones not supported by your version of systemd.
  17. #ProtectSystem=full
  18. #PrivateDevices=yes
  19. PrivateTmp=yes
  20. NoNewPrivileges=true
  21. [Install]
  22. WantedBy=multi-user.target