Matrix Docker Ansible eploy
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
 
 

45 строки
1.6 KiB

  1. #jinja2: lstrip_blocks: "True"
  2. [Unit]
  3. Description=Matrix riot-web server
  4. {% for service in matrix_riot_web_systemd_required_services_list %}
  5. Requires={{ service }}
  6. After={{ service }}
  7. {% endfor %}
  8. [Service]
  9. Type=simple
  10. ExecStartPre=-{{ matrix_host_command_docker }} kill matrix-riot-web
  11. ExecStartPre=-{{ matrix_host_command_docker }} rm matrix-riot-web
  12. ExecStart={{ matrix_host_command_docker }} run --rm --name matrix-riot-web \
  13. --log-driver=none \
  14. --user={{ matrix_user_uid }}:{{ matrix_user_gid }} \
  15. --cap-drop=ALL \
  16. --read-only \
  17. --network={{ matrix_docker_network }} \
  18. {% if matrix_riot_web_container_http_host_bind_port %}
  19. -p {{ matrix_riot_web_container_http_host_bind_port }}:8080 \
  20. {% endif %}
  21. --tmpfs=/tmp:rw,noexec,nosuid,size=10m \
  22. -v {{ matrix_riot_web_data_path }}/nginx.conf:/etc/nginx/nginx.conf:ro \
  23. -v /dev/null:/etc/nginx/conf.d/default.conf:ro \
  24. -v {{ matrix_riot_web_data_path }}/config.json:/app/config.json:ro \
  25. -v {{ matrix_riot_web_data_path }}/config.json:/app/config.{{ matrix_server_fqn_riot }}.json:ro \
  26. {% if matrix_riot_web_embedded_pages_home_path is not none %}
  27. -v {{ matrix_riot_web_data_path }}/home.html:/app/home.html:ro \
  28. {% endif %}
  29. -v {{ matrix_riot_web_data_path }}/welcome.html:/app/welcome.html:ro \
  30. {% for arg in matrix_riot_web_container_extra_arguments %}
  31. {{ arg }} \
  32. {% endfor %}
  33. {{ matrix_riot_web_docker_image }}
  34. ExecStop=-{{ matrix_host_command_docker }} kill matrix-riot-web
  35. ExecStop=-{{ matrix_host_command_docker }} rm matrix-riot-web
  36. Restart=always
  37. RestartSec=30
  38. SyslogIdentifier=matrix-riot-web
  39. [Install]
  40. WantedBy=multi-user.target