logo

pleroma

My custom branche(s) on git.pleroma.social/pleroma/pleroma git clone https://anongit.hacktivis.me/git/pleroma.git/

pleroma (590B)


  1. #!/sbin/openrc-run
  2. supervisor=supervise-daemon
  3. # Requires OpenRC >= 0.35
  4. directory=/opt/pleroma
  5. command=/opt/pleroma/bin/pleroma
  6. command_args="start"
  7. command_user=pleroma
  8. command_background=1
  9. no_new_privs="yes"
  10. # Ask process to terminate within 30 seconds, otherwise kill it
  11. retry="SIGTERM/30/SIGKILL/5"
  12. pidfile="/var/run/pleroma.pid"
  13. # Needs OpenRC >= 0.42
  14. respawn_max=200
  15. respawn_period=86400 # 1*day
  16. depend() {
  17. want nginx
  18. need postgresql
  19. }
  20. start_pre() {
  21. ebegin "run migrations if any"
  22. su -s /bin/sh -c '/opt/pleroma/bin/pleroma_ctl migrate' -l "${command_user}"
  23. eend "$?"
  24. }