Merge pull request #104 from plotly/support-local-config
Support locally-installed redis.conf
This commit is contained in:
@@ -36,7 +36,11 @@ service_create() {
|
||||
mkdir -p "$SERVICE_ROOT" || dokku_log_fail "Unable to create service directory"
|
||||
mkdir -p "$SERVICE_ROOT/data" || dokku_log_fail "Unable to create service data directory"
|
||||
mkdir -p "$SERVICE_ROOT/config" || dokku_log_fail "Unable to create service config directory"
|
||||
curl -sSL "https://raw.githubusercontent.com/antirez/redis/${PLUGIN_IMAGE_VERSION:0:3}/redis.conf" > "$SERVICE_ROOT/config/redis.conf" || dokku_log_fail "Unable to download the default redis.conf to the config directory"
|
||||
if [[ -z $REDIS_CONFIG_PATH ]] ; then
|
||||
curl -sSL "https://raw.githubusercontent.com/antirez/redis/${PLUGIN_IMAGE_VERSION:0:3}/redis.conf" > "$SERVICE_ROOT/config/redis.conf" || dokku_log_fail "Unable to download the default redis.conf to the config directory"
|
||||
else
|
||||
cp "$REDIS_CONFIG_PATH" "$SERVICE_ROOT/config/redis.conf" || dokku_log_fail "Unable to copy the ${REDIS_CONFIG_PATH} to the config directory"
|
||||
fi
|
||||
PASSWORD=$(openssl rand -hex 32)
|
||||
if [[ -n "$SERVICE_PASSWORD" ]]; then
|
||||
PASSWORD="$SERVICE_PASSWORD"
|
||||
|
||||
Reference in New Issue
Block a user