Services on CC: Difference between revisions

From Creative Crowds wiki
Jump to navigation Jump to search
Line 47: Line 47:


==etherpad-lite==
==etherpad-lite==
'''installed'''


  /opt/etherpad-lite/
  /opt/etherpad-lite/


* database: sqlite (878MB on 7 Nov 2025)
'''database'''
* /etc/systemd/system/etherpad-lite.service (generated by installation)
 
sqlite (878MB on 7 Nov 2025)
 
'''nginx'''
 
# ----------------------------------------------------
# ETHERPAD
location /pad/ {
        proxy_buffering off;
        proxy_set_header Host $host;
        # optional headers
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $remote_addr; # EP logs to show the actual remote IP
        proxy_set_header X-Forwarded-Proto $scheme; # for EP to set secure cookie flag when https is used
        # recommended with keepalive connections
        proxy_http_version 1.1;
        # WebSocket support
        proxy_set_header Upgrade $http_upgrade;
        # upstream
        proxy_pass http://127.0.0.1:9001/;
}
# make sure that /pad also works
location = /pad {
        return 301 /pad/;
}
 
 
'''symstemd'''
 
/etc/systemd/system/etherpad-lite.service (generated by installation)


<pre>
<pre>

Revision as of 18:56, 11 December 2025

debian

  • OVH server: debian 11 (bullseye)
  • Servus server: debian 12 (bookworm)
  • latest stable: debian 13 (trixie)

apt

OVH server

  • sources: /etc/apt/sources.list
deb http://deb.debian.org/debian bullseye main
deb-src http://deb.debian.org/debian bullseye main
deb http://security.debian.org/debian-security bullseye-security main
deb-src http://security.debian.org/debian-security bullseye-security main
deb http://deb.debian.org/debian bullseye-updates main
deb-src http://deb.debian.org/debian bullseye-updates main
deb http://deb.debian.org/debian bullseye-backports main
deb-src http://deb.debian.org/debian bullseye-backports main

backports were added for cobbled-paths installation?

i think we can do without when we upgrade to trixie on the Servus server

Servus server

upgrading from bookworm to trixie: https://www.debian.org/releases/trixie/release-notes/upgrading.en.html

  • sources: /etc/apt/sources.list.d/debian.sources
Types: deb
URIs: https://deb.debian.org/debian
Suites: trixie trixie-updates
Components: main non-free-firmware non-free contrib
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg

Types: deb
URIs: https://security.debian.org/debian-security
Suites: trixie-security
Components: main non-free-firmware non-free contrib
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg

etherpad-lite

installed

/opt/etherpad-lite/

database

sqlite (878MB on 7 Nov 2025)

nginx

# ----------------------------------------------------
# ETHERPAD

location /pad/ {
       proxy_buffering off;
       proxy_set_header Host $host;
       # optional headers
       proxy_set_header X-Real-IP $remote_addr;
       proxy_set_header X-Forwarded-For $remote_addr; # EP logs to show the actual remote IP
       proxy_set_header X-Forwarded-Proto $scheme; # for EP to set secure cookie flag when https is used
       # recommended with keepalive connections
       proxy_http_version 1.1;
       # WebSocket support
       proxy_set_header Upgrade $http_upgrade;
       # upstream
       proxy_pass http://127.0.0.1:9001/;
}
# make sure that /pad also works 
location = /pad {
       return 301 /pad/;
}


symstemd

/etc/systemd/system/etherpad-lite.service (generated by installation)

[Unit]
Description=etherpad-lite (real-time collaborative document editing)
After=syslog.target network.target

[Service]
Type=simpleUser=etherpad-lite
User=etherpad-lite
Group=etherpad-lite
Environment=NODE_ENV=production
ExecStart=/bin/sh /srv/etherpad-lite/src/bin/run.sh

[Install]
WantedBy=multi-user.target

installing on Servus server

see: Install_Etherpad-lite

mediawiki

/var/www/html/wiki/
/opt/wiki/
  • php: php7.4

octomode

/var/www/octomode/
  • flask application
  • /etc/systemd/system/octomode.service
[Unit]
Description=Collective PDF rendering environment
After=network.target

[Service]
User=octomode
WorkingDirectory=/var/www/octomode
ExecStart=/usr/bin/make action
Restart=always
StandardOutput=append:/var/log/octomode/octomode.log
StandardError=append:/var/log/octomode/octomode.log

[Install]
WantedBy=multi-user.target

wiki-to-print

/var/www/wiki2print/
  • flask application
  • /etc/systemd/system/wiki2print.service
[Unit]
Description=wiki2print
After=network.target

[Service]
User=www-data
WorkingDirectory=/var/www/wiki2print/web-interface/
ExecStart=/usr/bin/make server
#ExecStart=export SCRIPT_NAME=/wiki-to-print && /var/www/wiki2print/web-interface/venv/bin/gunicorn -b localhost:5522 --reload web-interface:APP
Restart=always

[Install]
WantedBy=multi-user.target

backups through crontab:

# every night at 3:33
33 3 * * * mysqldump --user=wiki --password=XXX wikidb > /var/www/html/wiki/ wikidb_backup.sql
33 3 * * * mysqldump --user=wiki --password=XXX wikidb --xml > /var/www/html/wiki/wikidb_backup.xml

cobbled-paths

/var/www/cobbled-paths/

nginx

/var/www/html/
/home/manetta/public_html/
/home/simoon/public_html/
/home/friends/public_html/

certbot

auto-renewal through crontab:

# every night at 04:44
44 4 * * * certbot renew --pre-hook "systemctl stop nginx" --post-hook "systemctl start nginx" --quiet