mercurial/web/tasks/main.yaml
author Luke Hoersten <luke@hoersten.org>
Sun, 06 Nov 2022 23:10:04 -0600
changeset 203 4be395f0d127
parent 195 da34c8d7511d
child 227 2e0366f2dcbe
permissions -rw-r--r--
Reduced number of open connections for dendrite due to startup error.

---

- name: apt install uwsgi
  become: yes
  apt: name="{{item}}"
  loop:
    - "mercurial"
    - "uwsgi"
    - "uwsgi-plugin-python3"
    - "python3-pygments"
  notify: restart uwsgi

- name: configure hgweb
  become: yes
  template: src="{{item}}.j2" dest="{{mercurial_uwsgi_root}}/{{item}}"
  loop:
    - "hgweb.config"
    - "hgweb.wsgi"
  notify: restart uwsgi

- name: install uwsgi site
  become: yes
  template: src="hgweb.ini.j2" dest="/etc/uwsgi/apps-available/hgweb.ini"
  notify: restart uwsgi

- name: enable uwsgi site
  become: yes
  file:
    src:  "/etc/uwsgi/apps-available/hgweb.ini"
    dest: "/etc/uwsgi/apps-enabled/hgweb.ini"
    state: "link"
  notify: restart uwsgi

- name: ensure uwsgi service is started
  become: yes
  systemd: name="[email protected]" enabled="yes"

- name: ensure uwsgi service is started
  become: yes
  systemd: name="[email protected]" enabled="yes"