Follow

When you install several Castopod instances on CloudPanel with Redis, you need to know which Redis databases are already in use so that you can pick one that is not.

Here is a script that will help you listing all Redis db used by your Castopod instances:

#!/bin/sh
for d in /home/cloudpanel/htdocs/*/; do
if [ -f "$d/.env" ]; then
redisdatabase=`sed -n 's/cache\.redis\.database=\([0-9]\+\)/\1/p' $d/.env`
echo "$(basename $d)\t\t$redisdatabase"
fi
done

· · Web · 0 · 1 · 1
Sign in to participate in the conversation
Castopod

designed and built by and for podcasts lovers