chore: Add config for etherpad plugin ep_delete_after_delay

This commit is contained in:
Gerardo Navarro 2022-08-21 23:47:22 +02:00
parent 54195d0212
commit 5796419f49
2 changed files with 39 additions and 12 deletions

View file

@ -42,7 +42,7 @@ services:
mariadb_prod:
image: mariadb
# Pass config parameters to the postgres server.
# Pass config parameters to the mysql server.
# Find more information below when you need to generate the ssl-relevant file your self
command:
- --character-set-server=utf8mb4
@ -56,20 +56,21 @@ services:
MARIADB_RANDOM_ROOT_PASSWORD: 'yes'
MARIADB_USER: ${DOCKER_COMPOSE_MARIADB_PROD_ENV_MARIADB_USER:?}
volumes:
# To setup an ssl-enabled postgres server locally, you need to generate a self-signed ssl certificate.
# ```bash
# mkdir -p ./ca
# openssl req -new -text -passout pass:abcd -subj /CN=localhost -out ./ca/server.req -keyout ./ca/privkey.pem
# openssl rsa -in ./ca/privkey.pem -passin pass:abcd -out ./ca/server.key
# openssl req -x509 -in ./ca/server.req -text -key ./ca/server.key -out ./ca/server.crt
# chmod 600 ./ca/server.key
# test $(uname -s) = Linux && chown 70 ./ca/server.key
# ```
# To setup an ssl-enabled mysql server locally, you need to generate a self-signed ssl certificate.
#
# ```bash
# mkdir -p ./ca
# openssl req -new -text -passout pass:abcd -subj /CN=localhost -out ./ca/server.req -keyout ./ca/privkey.pem
# openssl rsa -in ./ca/privkey.pem -passin pass:abcd -out ./ca/server.key
# openssl req -x509 -in ./ca/server.req -text -key ./ca/server.key -out ./ca/server.crt
# chmod 600 ./ca/server.key
# test $(uname -s) = Linux && chown 70 ./ca/server.key
# ```
#
# Afterwards, the ssl_cert_file and ssl_key_file are mounted into the docker container, see below
- ./ca/server.crt:/var/lib/mysql/server.crt
- ./ca/server.key:/var/lib/mysql/server.key
- mariadb_prod_data:/var/lib/postgresql/data/pgdata
- mariadb_prod_data:/var/lib/mysql
volumes:
mariadb_prod_data:

View file

@ -587,5 +587,31 @@
"loglevel": "${LOGLEVEL:INFO}",
/* Override any strings found in locale directories */
"customLocaleStrings": {}
"customLocaleStrings": {},
/*
* Allow only some file formats
*/
"ep_disable_imports": {
"allow": ["etherpad", "docx", "odt", "txt", "rtf", "pdf"]
},
/*
* Delete pads after delay
*/
"ep_delete_after_delay": {
"delay": 2592000, // thirty days, in seconds
"loop": true,
"loopDelay": 3600, // one hour, in seconds
"deleteAtStart": true,
"text": "The content of this pad has been deleted since it was older than the configured delay."
},
/*
* Configure image upload
*/
"ep_image_upload": {
"fileTypes": ["jpeg", "jpg", "bmp", "gif", "png"],
"maxFileSize": 2000000
}
}