mirror of
https://github.com/overleaf/toolkit.git
synced 2025-04-19 07:18:06 +02:00
Merge pull request #263 from overleaf/msm-redis-appendonly
Added '--appendonly yes' configuration to redis
This commit is contained in:
commit
2bc0c9d71b
5 changed files with 22 additions and 0 deletions
|
@ -1,5 +1,11 @@
|
||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 2024-07-27
|
||||||
|
### Added
|
||||||
|
- Added "--appendonly yes" configuration to redis.
|
||||||
|
|
||||||
|
redis persistence documentation: https://redis.io/docs/latest/operate/oss_and_stack/management/persistence/
|
||||||
|
|
||||||
## 2024-07-16
|
## 2024-07-16
|
||||||
### Added
|
### Added
|
||||||
- Added support for Mongo 6.0.
|
- Added support for Mongo 6.0.
|
||||||
|
|
|
@ -109,6 +109,17 @@ function set_redis_vars() {
|
||||||
DOCKER_COMPOSE_FLAGS+=(-f "$TOOLKIT_ROOT/lib/docker-compose.redis.yml")
|
DOCKER_COMPOSE_FLAGS+=(-f "$TOOLKIT_ROOT/lib/docker-compose.redis.yml")
|
||||||
export REDIS_IMAGE
|
export REDIS_IMAGE
|
||||||
export REDIS_DATA_PATH
|
export REDIS_DATA_PATH
|
||||||
|
|
||||||
|
if [[ -z "${REDIS_AOF_PERSISTENCE:-}" ]]; then
|
||||||
|
echo "WARNING: the value of REDIS_AOF_PERSISTENCE is not set in config/overleaf.rc"
|
||||||
|
echo "See https://github.com/overleaf/overleaf/wiki/Release-Notes-5.x.x/_edit#redis-aof-persistence-enabled-by-default"
|
||||||
|
REDIS_COMMAND="redis-server"
|
||||||
|
elif [[ $REDIS_AOF_PERSISTENCE == "true" ]]; then
|
||||||
|
REDIS_COMMAND="redis-server --appendonly yes"
|
||||||
|
else
|
||||||
|
REDIS_COMMAND="redis-server"
|
||||||
|
fi
|
||||||
|
export REDIS_COMMAND
|
||||||
}
|
}
|
||||||
|
|
||||||
# Set environment variables for docker-compose.mongo.yml
|
# Set environment variables for docker-compose.mongo.yml
|
||||||
|
|
|
@ -256,6 +256,9 @@ function check_config_files() {
|
||||||
if [[ "${REDIS_IMAGE:-null}" != "null" ]]; then
|
if [[ "${REDIS_IMAGE:-null}" != "null" ]]; then
|
||||||
print_point 2 "REDIS_IMAGE: $REDIS_IMAGE"
|
print_point 2 "REDIS_IMAGE: $REDIS_IMAGE"
|
||||||
fi
|
fi
|
||||||
|
if [[ "${REDIS_AOF_PERSISTENCE:-null}" != "null" ]]; then
|
||||||
|
print_point 2 "REDIS_AOF_PERSISTENCE: $REDIS_AOF_PERSISTENCE"
|
||||||
|
fi
|
||||||
if [[ "${REDIS_DATA_PATH:-null}" != "null" ]]; then
|
if [[ "${REDIS_DATA_PATH:-null}" != "null" ]]; then
|
||||||
print_point 2 "REDIS_DATA_PATH: $REDIS_DATA_PATH"
|
print_point 2 "REDIS_DATA_PATH: $REDIS_DATA_PATH"
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -23,6 +23,7 @@ MONGO_IMAGE=mongo:5.0
|
||||||
REDIS_ENABLED=true
|
REDIS_ENABLED=true
|
||||||
REDIS_DATA_PATH=data/redis
|
REDIS_DATA_PATH=data/redis
|
||||||
REDIS_IMAGE=redis:6.2
|
REDIS_IMAGE=redis:6.2
|
||||||
|
REDIS_AOF_PERSISTENCE=true
|
||||||
|
|
||||||
# Git-bridge configuration (Server Pro only)
|
# Git-bridge configuration (Server Pro only)
|
||||||
GIT_BRIDGE_ENABLED=false
|
GIT_BRIDGE_ENABLED=false
|
||||||
|
|
|
@ -8,6 +8,7 @@ services:
|
||||||
volumes:
|
volumes:
|
||||||
- "${REDIS_DATA_PATH}:/data"
|
- "${REDIS_DATA_PATH}:/data"
|
||||||
container_name: redis
|
container_name: redis
|
||||||
|
command: ${REDIS_COMMAND}
|
||||||
expose:
|
expose:
|
||||||
- 6379
|
- 6379
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue