blob: ba3c27c93997eb4a18394df33ba7bf1290c46561 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
|
---
- name: pip install mercurial
become: yes
pip: name="mercurial" executable="pip3"
- name: apt install uwsgi
become: yes
apt: name="{{item}}"
loop:
- "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="uwsgi.service" enabled="yes"
|