diff --git a/services/pad.libre-service.eu.md b/services/pad.libre-service.eu.md index 0872eb8..0a2814a 100644 --- a/services/pad.libre-service.eu.md +++ b/services/pad.libre-service.eu.md @@ -128,13 +128,12 @@ git clone --branch master https://github.com/ether/etherpad-lite.git pad.libre-s chown -R etherpad:etherpad /var/www/pad.libre-service.eu ``` -Premier lancement : +Créer le fichier de configuration : ``` -su etherpad -c "cd /var/www/pad.libre-service.eu/ && ./bin/installDeps.sh && ./src/bin/run.sh" +cd /var/www/pad.libre-service.eu/ && cp settings.json settings.json.template ``` - -Configuration dans le fichier `/var/www/pad.libre-service.eu/settings.json` : +Configurer dans `/var/www/pad.libre-service.eu/settings.json` : ``` - "dbType" : "dirty", - "dbSettings" : { @@ -150,24 +149,29 @@ Configuration dans le fichier `/var/www/pad.libre-service.eu/settings.json` : "database": "etherpad", "charset": "utf8mb4" }, - +[…] "trustProxy": true, - -Define a password for the admin user:Advertisement - +[…] "users": { "admin": { - "password": "adminpassword", + "password": "xxxxxxxxxxxxxxxx", "is_admin": true }, ``` -Installer les dépendances nécessaires : +Premier lancement : ``` -su etherpad -c "cd /var/www/pad.libre-service.eu/ && ./bin/installDeps.sh" +su etherpad -c "cd /var/www/pad.libre-service.eu/ && ./bin/installDeps.sh && ./src/bin/run.sh" ``` +Neutraliser les vulnéralités : +``` +su etherpad -c "cd /var/www/pad.libre-service.eu/ && npm audit" +su etherpad -c "cd /var/www/pad.libre-service.eu/ && npm i --package-lock-only" +su etherpad -c "cd /var/www/pad.libre-service.eu/ && npm audit fix" +su etherpad -c "cd /var/www/pad.libre-service.eu/ && npm audit" +``` ## Configuration Systemd @@ -175,7 +179,7 @@ Créer le fichier `/etc/systemd/system/etherpad.service` : ``` [Unit] Description=Etherpad-lite, the collaborative editor. -After=syslog.target network.target +After=syslog.target network.target postgresql.target [Service] Type=simple @@ -184,8 +188,7 @@ Group=etherpad WorkingDirectory=/var/www/pad.libre-service.eu/ Environment=NODE_ENV=production -ExecStart=/usr/bin/node /var/www/pad.libre-service.eu/bin/run.sh -# src???/node/server.js +ExecStart=/var/www/pad.libre-service.eu/bin/run.sh Restart=always