mirror of
https://github.com/bitnami/containers.git
synced 2026-04-03 15:57:46 +08:00
4.0.9-ol-7-r13 release
Maintenance release
This commit is contained in:
26
bitnami/redis/4.0/ol-7/Dockerfile
Normal file
26
bitnami/redis/4.0/ol-7/Dockerfile
Normal file
@@ -0,0 +1,26 @@
|
||||
FROM bitnami/oraclelinux-extras:7-r3
|
||||
LABEL maintainer "Bitnami <containers@bitnami.com>"
|
||||
|
||||
ENV BITNAMI_PKG_CHMOD="-R g+rwX" \
|
||||
HOME="/"
|
||||
|
||||
# Install required system packages and dependencies
|
||||
RUN bitnami-pkg unpack redis-4.0.9-1 --checksum 856ee72c7ff72958a83b48c6c862bc502f5ae9ff4a301e9eab33b991f2b452dd
|
||||
|
||||
COPY rootfs /
|
||||
ENV ALLOW_EMPTY_PASSWORD="no" \
|
||||
BITNAMI_APP_NAME="redis" \
|
||||
BITNAMI_IMAGE_VERSION="4.0.9-ol-7-r13" \
|
||||
PATH="/opt/bitnami/redis/bin:$PATH" \
|
||||
REDIS_DISABLE_COMMANDS="" \
|
||||
REDIS_MASTER_HOST="" \
|
||||
REDIS_MASTER_PASSWORD="" \
|
||||
REDIS_MASTER_PORT_NUMBER="6379" \
|
||||
REDIS_PASSWORD="" \
|
||||
REDIS_REPLICATION_MODE=""
|
||||
|
||||
EXPOSE 6379
|
||||
|
||||
USER 1001
|
||||
ENTRYPOINT ["/app-entrypoint.sh"]
|
||||
CMD ["/run.sh"]
|
||||
17
bitnami/redis/4.0/ol-7/docker-compose.yml
Normal file
17
bitnami/redis/4.0/ol-7/docker-compose.yml
Normal file
@@ -0,0 +1,17 @@
|
||||
version: '2'
|
||||
|
||||
services:
|
||||
redis:
|
||||
image: 'bitnami/redis:4.0-ol-7'
|
||||
environment:
|
||||
# ALLOW_EMPTY_PASSWORD is recommended only for development.
|
||||
- ALLOW_EMPTY_PASSWORD=yes
|
||||
- REDIS_DISABLE_COMMANDS=FLUSHDB,FLUSHALL
|
||||
ports:
|
||||
- '6379:6379'
|
||||
volumes:
|
||||
- 'redis_data:/bitnami'
|
||||
|
||||
volumes:
|
||||
redis_data:
|
||||
driver: local
|
||||
14
bitnami/redis/4.0/ol-7/rootfs/app-entrypoint.sh
Executable file
14
bitnami/redis/4.0/ol-7/rootfs/app-entrypoint.sh
Executable file
@@ -0,0 +1,14 @@
|
||||
#!/bin/bash -e
|
||||
|
||||
. /opt/bitnami/base/functions
|
||||
. /opt/bitnami/base/helpers
|
||||
|
||||
print_welcome_page
|
||||
|
||||
if [[ "$1" == "nami" && "$2" == "start" ]] || [[ "$1" == "/run.sh" ]]; then
|
||||
. /init.sh
|
||||
nami_initialize redis
|
||||
info "Starting redis... "
|
||||
fi
|
||||
|
||||
exec tini -- "$@"
|
||||
30
bitnami/redis/4.0/ol-7/rootfs/init.sh
Normal file
30
bitnami/redis/4.0/ol-7/rootfs/init.sh
Normal file
@@ -0,0 +1,30 @@
|
||||
##
|
||||
## @brief Helper function to show an error when a password is empty and exit
|
||||
## param $1 Input name
|
||||
##
|
||||
empty_password_error() {
|
||||
error "The $1 environment variable is empty or not set. Set the environment variable ALLOW_EMPTY_PASSWORD=yes to allow the container to be started with blank passwords. This is recommended only for development."
|
||||
exit 1
|
||||
}
|
||||
|
||||
##
|
||||
## @brief Helper function to show a warning when the ALLOW_EMPTY_PASSWORD flag is enabled
|
||||
##
|
||||
empty_password_enabled_warn() {
|
||||
warn "You set the environment variable ALLOW_EMPTY_PASSWORD=${ALLOW_EMPTY_PASSWORD}. For safety reasons, do not use this flag in a production environment."
|
||||
}
|
||||
|
||||
|
||||
# Validate passwords
|
||||
if [[ "$ALLOW_EMPTY_PASSWORD" =~ ^(yes|Yes|YES)$ ]]; then
|
||||
empty_password_enabled_warn
|
||||
else
|
||||
# Root user
|
||||
if [[ -z "$REDIS_PASSWORD" ]]; then
|
||||
empty_password_error REDIS_PASSWORD
|
||||
fi
|
||||
# Replication user
|
||||
if [[ "$REDIS_REPLICATION_MODE" == "slave" && -z "$REDIS_MASTER_PASSWORD" ]]; then
|
||||
empty_password_error REDIS_MASTER_PASSWORD
|
||||
fi
|
||||
fi
|
||||
9
bitnami/redis/4.0/ol-7/rootfs/redis-inputs.json
Normal file
9
bitnami/redis/4.0/ol-7/rootfs/redis-inputs.json
Normal file
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"allowEmptyPassword": "{{$global.env.ALLOW_EMPTY_PASSWORD}}",
|
||||
"disableCommands": "{{$global.env.REDIS_DISABLE_COMMANDS}}",
|
||||
"masterHost": "{{$global.env.REDIS_MASTER_HOST}}",
|
||||
"masterPassword": "{{$global.env.REDIS_MASTER_PASSWORD}}",
|
||||
"masterPort": "{{$global.env.REDIS_MASTER_PORT_NUMBER}}",
|
||||
"password": "{{$global.env.REDIS_PASSWORD}}",
|
||||
"replicationMode": "{{$global.env.REDIS_REPLICATION_MODE}}"
|
||||
}
|
||||
23
bitnami/redis/4.0/ol-7/rootfs/run.sh
Executable file
23
bitnami/redis/4.0/ol-7/rootfs/run.sh
Executable file
@@ -0,0 +1,23 @@
|
||||
#!/bin/bash
|
||||
. /opt/bitnami/base/functions
|
||||
. /opt/bitnami/base/helpers
|
||||
|
||||
USER=redis
|
||||
DAEMON=redis-server
|
||||
EXEC=$(which $DAEMON)
|
||||
ARGS="/opt/bitnami/redis/conf/redis.conf --daemonize no"
|
||||
|
||||
# configure extra command line flags
|
||||
if [[ -n "$REDIS_EXTRA_FLAGS" ]]; then
|
||||
ARGS+=" $REDIS_EXTRA_FLAGS"
|
||||
fi
|
||||
|
||||
# log output to stdout
|
||||
sed -i 's/^logfile /# logfile /g' /opt/bitnami/redis/conf/redis.conf
|
||||
|
||||
# If container is started as `root` user
|
||||
if [ $EUID -eq 0 ]; then
|
||||
exec gosu ${USER} ${EXEC} ${ARGS}
|
||||
else
|
||||
exec ${EXEC} ${ARGS}
|
||||
fi
|
||||
@@ -27,6 +27,13 @@ $ docker-compose up -d
|
||||
* Bitnami images are built on CircleCI and automatically pushed to the Docker Hub.
|
||||
* All our images are based on [minideb](https://github.com/bitnami/minideb) a minimalist Debian based container image which gives you a small base container image and the familiarity of a leading linux distribution.
|
||||
|
||||
# Supported tags and respective `Dockerfile` links
|
||||
|
||||
* [`4.0`, `4.0.9-r12`, `latest` (4.0/Dockerfile)](https://github.com/bitnami/bitnami-docker-redis/blob/4.0.9-r12/4.0/Dockerfile)
|
||||
* [`4.0-ol-7`, `4.0.9-ol-7-r13` (4.0/ol-7/Dockerfile)](https://github.com/bitnami/bitnami-docker-redis/blob/4.0.9-ol-7-r13/4.0/ol-7/Dockerfile)
|
||||
|
||||
Subscribe to project updates by watching the [bitnami/redis GitHub repo](https://github.com/bitnami/bitnami-docker-redis).
|
||||
|
||||
# Get this image
|
||||
|
||||
The recommended way to get the Bitnami Redis Docker Image is to pull the prebuilt image from the [Docker Hub Registry](https://hub.docker.com/r/bitnami/redis).
|
||||
|
||||
@@ -7,6 +7,7 @@ jobs:
|
||||
environment:
|
||||
RELEASE_SERIES_LIST: "4.0"
|
||||
LATEST_STABLE: "4.0"
|
||||
DISTRIBUTIONS_LIST: "debian-8,ol-7"
|
||||
IMAGE_NAME: redis
|
||||
CHART_NAME: redis
|
||||
CHART_REPO: https://github.com/kubernetes/charts
|
||||
|
||||
Reference in New Issue
Block a user