Merge pull request 'moved app source to dedicated dir /app/ to seperate home dir from app dir preventing git conflicts; fixed loading modules as etherpad user' (#7) from 1.8.18 into master

Reviewed-on: #7
Reviewed-by: meaz <meaz@no-reply@disroot.org>
This commit is contained in:
muppeth 2022-06-21 19:16:25 +00:00
commit f0de627f05
6 changed files with 13 additions and 9 deletions

2
Vagrantfile vendored
View File

@ -8,7 +8,7 @@
Vagrant.configure("2") do |config|
#config.ssh.insert_key = false
config.vm.define "etherpad" do |etherpad|
etherpad.vm.box = "generic/debian10"
etherpad.vm.box = "generic/debian11"
etherpad.vm.provider :libvirt do |libvirt|
libvirt.memory = 256
end

View File

@ -1,6 +1,6 @@
---
etherpad_version: '1.8.17'
etherpad_version: '1.8.18'
etherpad_skin: 'colibris'
etherpad_skinVariants: 'super-light-toolbar super-light-editor light-background'
etherpad_username: 'etherpad'
@ -74,7 +74,7 @@ etherpad_plugins:
- name: ep_real_time_chat
install: true
- name: ep_delete_after_delay
install: false
install: true
- name: ep_align
install: true
- name: ep_font_size

View File

@ -11,7 +11,7 @@
- name: '[CONFIGURE] - Deploy config'
template:
src: var/www/etherpad-lite/settings.json.j2
dest: "{{ etherpad_app_dir }}/settings.json"
dest: "{{ etherpad_app_dir }}/app/settings.json"
owner: "{{ etherpad_username }}"
group: "{{ etherpad_group }}"
mode: 0644

View File

@ -3,7 +3,7 @@
- name: '[GIT] - Deploy source'
git:
repo: https://github.com/ether/etherpad-lite.git
dest: "{{ etherpad_app_dir }}"
dest: "{{ etherpad_app_dir }}/app"
force: yes
update: yes
version: "{{ etherpad_version }}"

View File

@ -3,9 +3,11 @@
- name: '[Modules] - Install modules'
npm:
name: "{{ item.name }}"
path: "{{ etherpad_app_dir }}"
path: "{{ etherpad_app_dir }}/app"
state: latest
with_items: "{{ etherpad_plugins }}"
become: yes
become_user: "{{ etherpad_username }}"
when: item.install|lower == 'true'
notify:
restart etherpad
@ -13,9 +15,11 @@
- name: '[Modules] - Uninstall modules'
npm:
name: "{{ item.name }}"
path: "{{ etherpad_app_dir }}"
path: "{{ etherpad_app_dir }}/app"
state: absent
with_items: "{{ etherpad_plugins }}"
become: yes
become_user: "{{ etherpad_username }}"
when: item.install|lower == 'false'
notify:
restart etherpad

View File

@ -6,9 +6,9 @@ After=syslog.target network.target
Type=simple
User={{ etherpad_username }}
Group={{ etherpad_group }}
WorkingDirectory={{ etherpad_app_dir }}
WorkingDirectory={{ etherpad_app_dir }}/app
Environment=NODE_ENV=production
ExecStart={{ etherpad_app_dir }}/bin/run.sh
ExecStart={{ etherpad_app_dir }}/app/bin/run.sh
StandardOutput=file:{{ etherpad_logfile }}
Restart=always
RestartSec=3