set maxmemory-policy to noeviction to prevent warnings

This commit is contained in:
Girish Ramakrishnan 2023-07-11 09:31:20 +05:30
parent 73730f82fe
commit 902a3c34b3

View file

@ -82,6 +82,13 @@ update_config() {
echo "==> Changing ownership"
chown -R cloudron:cloudron /app/data /run/peertube /tmp/peertube
# Set eviction policy to prevent warnings - https://docs.bullmq.io/guide/going-to-production#max-memory-policy
while ! REDISCLI_AUTH="${CLOUDRON_REDIS_PASSWORD}" redis-cli -h "${CLOUDRON_REDIS_HOST}" -p "${CLOUDRON_REDIS_PORT}" ping >/dev/null; do
echo "==> Waiting for redis"
sleep 5
done
REDISCLI_AUTH="${CLOUDRON_REDIS_PASSWORD}" redis-cli -h "${CLOUDRON_REDIS_HOST}" -p "${CLOUDRON_REDIS_PORT}" CONFIG SET maxmemory-policy noeviction
# cd /var/www/peertube/peertube-latest/scripts && sudo -H -u peertube ./upgrade.sh
if [[ ! -f "/app/data/production.yaml" ]]; then
echo "==> First run. creating config"