From 76b8394bd943b90a4fe0724ea434cb4cabd0aff6 Mon Sep 17 00:00:00 2001 From: Viyurz <128215328+Viyurz@users.noreply.github.com> Date: Sun, 3 Dec 2023 09:22:27 +0000 Subject: [PATCH] Ajout Etebase & Cryptpad --- cryptpad/docker-compose.yaml | 26 ++++++++++++++++++++++++++ etebase/docker-compose.yaml | 14 ++++++++++++++ maj.sh | 2 +- nginx-rp/reverse-proxy.conf | 33 +++++++++++++++++++++++++++++++++ ports.txt | 2 ++ 5 files changed, 76 insertions(+), 1 deletion(-) create mode 100644 cryptpad/docker-compose.yaml create mode 100644 etebase/docker-compose.yaml diff --git a/cryptpad/docker-compose.yaml b/cryptpad/docker-compose.yaml new file mode 100644 index 0000000..a05883c --- /dev/null +++ b/cryptpad/docker-compose.yaml @@ -0,0 +1,26 @@ +services: + cryptpad: + image: "cryptpad/cryptpad:version-5.5.0" + container_name: cryptpad + restart: always + hostname: cryptpad + environment: + - CPAD_MAIN_DOMAIN=https://cryptpad.viyurz.fr + - CPAD_SANDBOX_DOMAIN=https://cryptpad-sandbox.viyurz.fr + - CPAD_CONF=/cryptpad/config/config.js + volumes: + - /mnt/cryptpaddata/config/config.js:/cryptpad/config/config.js + - /mnt/cryptpaddata/blob:/cryptpad/blob + - /mnt/cryptpaddata/data/block:/cryptpad/block + - /mnt/cryptpaddata/customize:/cryptpad/customize + - /mnt/cryptpaddata/data/data:/cryptpad/data + - /mnt/cryptpaddata/data/files:/cryptpad/datastore + ports: + - "[::1]:3000:3000" + - "[::1]:3001:3001" + - "[::1]:3003:3003" + ulimits: + nofile: + soft: 1000000 + hard: 1000000 + user: cryptpad # useradd -u 4001 cryptpad diff --git a/etebase/docker-compose.yaml b/etebase/docker-compose.yaml new file mode 100644 index 0000000..dd8fb31 --- /dev/null +++ b/etebase/docker-compose.yaml @@ -0,0 +1,14 @@ +services: + etebase: + image: victorrds/etebase:alpine + container_name: etebase + restart: always + environment: + SERVER: http + ALLOWED_HOSTS: etebase.viyurz.fr + SUPER_USER: v444599a8zJUBud60fu9uk9Vo3xXHinp + AUTO_UPDATE: 'true' + ports: + - "[::1]:3735:3735" + volumes: + - /mnt/etebasedata:/data diff --git a/maj.sh b/maj.sh index bd52091..a74a7a7 100755 --- a/maj.sh +++ b/maj.sh @@ -1,7 +1,7 @@ #!/bin/bash -services=(mc nginx-www searxng synapse syncthing vw) +services=(cryptpad etebase mc nginx-www searxng synapse syncthing vw) if [[ ! $(echo "${services[*]} all" | grep -P "\b$1\b" ) ]]; then diff --git a/nginx-rp/reverse-proxy.conf b/nginx-rp/reverse-proxy.conf index 426399a..9f4128c 100644 --- a/nginx-rp/reverse-proxy.conf +++ b/nginx-rp/reverse-proxy.conf @@ -136,6 +136,39 @@ server { +# Cryptpad +server { + listen 443 ssl http2; + listen [::]:443 ssl http2; + + server_name cryptpad.viyurz.fr cryptpad-sandbox.viyurz.fr; + + location / { + proxy_pass http://localhost:3000; + + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection upgrade; + client_max_body_size 150m; + } +} + + + +# Etebase +server { + listen 443 ssl http2; + listen [::]:443 ssl http2; + + server_name etebase.viyurz.fr; + + location ~ ^/(?!admin) { + proxy_pass http://localhost:3735; + } +} + + + # Homepage server { listen 443 ssl http2; diff --git a/ports.txt b/ports.txt index 757c3b2..1689664 100644 --- a/ports.txt +++ b/ports.txt @@ -1,5 +1,7 @@ 80/443 -> NGINX reverse proxy 995 -> SSH +3000-3003 -> Cryptpad +3735 -> Etebase 5432 -> Syncthing 8008 -> Synapse 8080 -> Nextcloud AIO