[etherpad] Deploy a second instance
Signed-off-by: Yohann D'ANELLO <ynerant@crans.org>certbot_on_virtu
parent
2321121ec0
commit
5b52a5eeab
|
@ -14,8 +14,11 @@
|
||||||
- name: Clone EtherPad
|
- name: Clone EtherPad
|
||||||
git:
|
git:
|
||||||
repo: https://github.com/ether/etherpad-lite.git
|
repo: https://github.com/ether/etherpad-lite.git
|
||||||
dest: /var/www/etherpad-lite
|
dest: "/var/www/{{ item }}"
|
||||||
version: 1.8.4
|
version: 1.8.4
|
||||||
|
loop:
|
||||||
|
- "etherpad-lite"
|
||||||
|
- "etherpad-lite-tmp"
|
||||||
become: true
|
become: true
|
||||||
become_user: etherpad
|
become_user: etherpad
|
||||||
|
|
||||||
|
@ -27,14 +30,20 @@
|
||||||
- name: Install EtherPad systemd unit
|
- name: Install EtherPad systemd unit
|
||||||
template:
|
template:
|
||||||
src: systemd/system/etherpad-lite.service.j2
|
src: systemd/system/etherpad-lite.service.j2
|
||||||
dest: /etc/systemd/system/etherpad-lite.service
|
dest: "/etc/systemd/system/{{ item }}.service"
|
||||||
|
loop:
|
||||||
|
- "etherpad-lite"
|
||||||
|
- "etherpad-lite-tmp"
|
||||||
|
|
||||||
- name: Activate EtherPad service
|
- name: Activate EtherPad service
|
||||||
systemd:
|
systemd:
|
||||||
daemon_reload: true
|
daemon_reload: true
|
||||||
name: etherpad-lite
|
name: "{{ item }}"
|
||||||
enabled: true
|
enabled: true
|
||||||
state: started
|
state: started
|
||||||
|
loop:
|
||||||
|
- "etherpad-lite"
|
||||||
|
- "etherpad-lite-tmp"
|
||||||
|
|
||||||
- name: Indicate role in motd
|
- name: Indicate role in motd
|
||||||
template:
|
template:
|
||||||
|
|
|
@ -9,7 +9,7 @@ Type=simple
|
||||||
User=etherpad
|
User=etherpad
|
||||||
Group=etherpad
|
Group=etherpad
|
||||||
Environment=NODE_ENV=production
|
Environment=NODE_ENV=production
|
||||||
ExecStart=/var/www/etherpad-lite/bin/run.sh --stack-size=4096
|
ExecStart=/var/www/{{ item }}/bin/run.sh --stack-size=4096
|
||||||
Restart=always
|
Restart=always
|
||||||
RestartSec=5s
|
RestartSec=5s
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue