1
0

synapse.supervisord.conf.j2 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. {% if use_forking_launcher %}
  2. [program:synapse_fork]
  3. command=/usr/local/bin/python -m synapse.app.complement_fork_starter
  4. {{ main_config_path }}
  5. synapse.app.homeserver
  6. --config-path="{{ main_config_path }}"
  7. --config-path=/conf/workers/shared.yaml
  8. {%- for worker in workers %}
  9. -- {{ worker.app }}
  10. --config-path="{{ main_config_path }}"
  11. --config-path=/conf/workers/shared.yaml
  12. --config-path=/conf/workers/{{ worker.name }}.yaml
  13. {%- endfor %}
  14. stdout_logfile=/dev/stdout
  15. stdout_logfile_maxbytes=0
  16. stderr_logfile=/dev/stderr
  17. stderr_logfile_maxbytes=0
  18. autorestart=unexpected
  19. exitcodes=0
  20. {% else %}
  21. [program:synapse_main]
  22. command=/usr/local/bin/prefix-log /usr/local/bin/python -m synapse.app.homeserver
  23. --config-path="{{ main_config_path }}"
  24. --config-path=/conf/workers/shared.yaml
  25. priority=10
  26. # Log startup failures to supervisord's stdout/err
  27. # Regular synapse logs will still go in the configured data directory
  28. stdout_logfile=/dev/stdout
  29. stdout_logfile_maxbytes=0
  30. stderr_logfile=/dev/stderr
  31. stderr_logfile_maxbytes=0
  32. autorestart=unexpected
  33. exitcodes=0
  34. {% for worker in workers %}
  35. [program:synapse_{{ worker.name }}]
  36. command=/usr/local/bin/prefix-log /usr/local/bin/python -m {{ worker.app }}
  37. --config-path="{{ main_config_path }}"
  38. --config-path=/conf/workers/shared.yaml
  39. --config-path=/conf/workers/{{ worker.name }}.yaml
  40. autorestart=unexpected
  41. priority=500
  42. exitcodes=0
  43. stdout_logfile=/dev/stdout
  44. stdout_logfile_maxbytes=0
  45. stderr_logfile=/dev/stderr
  46. stderr_logfile_maxbytes=0
  47. {% endfor %}
  48. {% endif %}