4.0.14-debian-10-r10 release

This commit is contained in:
Bitnami Bot 2020-02-05 02:13:22 +00:00
parent 0af6b4f29c
commit 5a5fda3bb0
4 changed files with 49 additions and 10 deletions

View File

@ -17,7 +17,7 @@ RUN /build/install-gosu.sh
COPY rootfs /
RUN /postunpack.sh
ENV BITNAMI_APP_NAME="redis-sentinel" \
BITNAMI_IMAGE_VERSION="4.0.14-debian-10-r9" \
BITNAMI_IMAGE_VERSION="4.0.14-debian-10-r10" \
PATH="/opt/bitnami/redis-sentinel/bin:$PATH"
EXPOSE 26379

View File

@ -5,18 +5,56 @@
# Functions
########################
# Ensure a line exists in the file by replacing a matching line.
# Replace a regex in a file
# Arguments:
# $1 - filename
# $2 - line
# $3 - match
# $2 - match regex
# $3 - substitute regex
# $4 - use POSIX regex. Default: true
# Returns:
# None
#########################
file_contains_line() {
replace_in_file() {
local filename="${1:?filename is required}"
local line="${2:?line is required}"
local match="${3:?match is required}"
local match_regex="${2:?match regex is required}"
local substitute_regex="${3:?substitute regex is required}"
local posix_regex=${4:-true}
sed --in-place "s/^$match\$/$line/" "$filename"
local result
# We should avoid using 'sed in-place' substitutions
# 1) They are not compatible with files mounted from ConfigMap(s)
# 2) We found incompatibility issues with Debian10 and "in-place" substitutions
if [[ $posix_regex = true ]]; then
result="$(sed -E "s@$match_regex@$substitute_regex@g" "$filename")"
else
result="$(sed "s@$match_regex@$substitute_regex@g" "$filename")"
fi
echo "$result" > "$filename"
}
########################
# Remove a line in a file based on a regex
# Arguments:
# $1 - filename
# $2 - match regex
# $3 - use POSIX regex. Default: true
# Returns:
# None
#########################
remove_in_file() {
local filename="${1:?filename is required}"
local match_regex="${2:?match regex is required}"
local posix_regex=${3:-true}
local result
# We should avoid using 'sed in-place' substitutions
# 1) They are not compatible with files mounted from ConfigMap(s)
# 2) We found incompatibility issues with Debian10 and "in-place" substitutions
if [[ $posix_regex = true ]]; then
result="$(sed -E "/$match_regex/d" "$filename")"
else
result="$(sed "/$match_regex/d" "$filename")"
fi
echo "$result" > "$filename"
}

View File

@ -5,6 +5,7 @@
# shellcheck disable=SC1091
# Load Generic Libraries
. /libfile.sh
. /liblog.sh
. /libnet.sh
. /libos.sh
@ -34,7 +35,7 @@ redis_conf_set() {
[[ "$value" = "" ]] && value="\"$value\""
if grep -q "^\s*$key .*" "$REDIS_SENTINEL_CONF_FILE"; then
sed -i "s|^\s*$key .*|$key $value|g" "$REDIS_SENTINEL_CONF_FILE"
replace_in_file "$REDIS_SENTINEL_CONF_FILE" "^\s*${key} .*" "${key} ${value}" false
else
printf '\n%s %s' "$key" "$value" >> "$REDIS_SENTINEL_CONF_FILE"
fi

View File

@ -59,7 +59,7 @@ Learn more about the Bitnami tagging policy and the difference between rolling t
* [`5.0-ol-7`, `5.0.7-ol-7-r76` (5.0/ol-7/Dockerfile)](https://github.com/bitnami/bitnami-docker-redis-sentinel/blob/5.0.7-ol-7-r76/5.0/ol-7/Dockerfile)
* [`5.0-debian-10`, `5.0.7-debian-10-r10`, `5.0`, `5.0.7`, `latest` (5.0/debian-10/Dockerfile)](https://github.com/bitnami/bitnami-docker-redis-sentinel/blob/5.0.7-debian-10-r10/5.0/debian-10/Dockerfile)
* [`4.0-ol-7`, `4.0.14-ol-7-r320` (4.0/ol-7/Dockerfile)](https://github.com/bitnami/bitnami-docker-redis-sentinel/blob/4.0.14-ol-7-r320/4.0/ol-7/Dockerfile)
* [`4.0-debian-10`, `4.0.14-debian-10-r9`, `4.0`, `4.0.14` (4.0/debian-10/Dockerfile)](https://github.com/bitnami/bitnami-docker-redis-sentinel/blob/4.0.14-debian-10-r9/4.0/debian-10/Dockerfile)
* [`4.0-debian-10`, `4.0.14-debian-10-r10`, `4.0`, `4.0.14` (4.0/debian-10/Dockerfile)](https://github.com/bitnami/bitnami-docker-redis-sentinel/blob/4.0.14-debian-10-r10/4.0/debian-10/Dockerfile)
Subscribe to project updates by watching the [bitnami/redis-sentinel GitHub repo](https://github.com/bitnami/bitnami-docker-redis-sentinel).