appstore-1panel/apps/redis/7.2.5/scripts/init.sh

19 lines
320 B
Bash
Raw Normal View History

#!/bin/bash
if [ -f .env ]; then
source .env
mkdir -p "$REDIS_ROOT_PATH"
mkdir -p "$REDIS_ROOT_PATH/data"
mkdir -p "$REDIS_ROOT_PATH/config"
mkdir -p "$REDIS_ROOT_PATH/logs"
cp ./config/redis.conf "$REDIS_ROOT_PATH/config/redis.conf"
echo "Check Finish."
else
echo "Error: .env file not found."
fi