mirror of
https://github.com/bitnami/containers.git
synced 2026-03-20 23:10:53 +08:00
[bitnami/redis-sentinel] Release 7.0.15-debian-11-r2 (#55156)
Signed-off-by: Bitnami Containers <bitnami-bot@vmware.com>
This commit is contained in:
@@ -7,10 +7,10 @@ ARG TARGETARCH
|
|||||||
|
|
||||||
LABEL com.vmware.cp.artifact.flavor="sha256:1e1b4657a77f0d47e9220f0c37b9bf7802581b93214fff7d1bd2364c8bf22e8e" \
|
LABEL com.vmware.cp.artifact.flavor="sha256:1e1b4657a77f0d47e9220f0c37b9bf7802581b93214fff7d1bd2364c8bf22e8e" \
|
||||||
org.opencontainers.image.base.name="docker.io/bitnami/minideb:bullseye" \
|
org.opencontainers.image.base.name="docker.io/bitnami/minideb:bullseye" \
|
||||||
org.opencontainers.image.created="2024-01-11T15:49:44Z" \
|
org.opencontainers.image.created="2024-01-20T03:23:19Z" \
|
||||||
org.opencontainers.image.description="Application packaged by VMware, Inc" \
|
org.opencontainers.image.description="Application packaged by VMware, Inc" \
|
||||||
org.opencontainers.image.licenses="Apache-2.0" \
|
org.opencontainers.image.licenses="Apache-2.0" \
|
||||||
org.opencontainers.image.ref.name="7.0.15-debian-11-r1" \
|
org.opencontainers.image.ref.name="7.0.15-debian-11-r2" \
|
||||||
org.opencontainers.image.title="redis-sentinel" \
|
org.opencontainers.image.title="redis-sentinel" \
|
||||||
org.opencontainers.image.vendor="VMware, Inc." \
|
org.opencontainers.image.vendor="VMware, Inc." \
|
||||||
org.opencontainers.image.version="7.0.15"
|
org.opencontainers.image.version="7.0.15"
|
||||||
@@ -42,6 +42,7 @@ RUN apt-get autoremove --purge -y curl && \
|
|||||||
apt-get update && apt-get upgrade -y && \
|
apt-get update && apt-get upgrade -y && \
|
||||||
apt-get clean && rm -rf /var/lib/apt/lists /var/cache/apt/archives
|
apt-get clean && rm -rf /var/lib/apt/lists /var/cache/apt/archives
|
||||||
RUN chmod g+rwX /opt/bitnami
|
RUN chmod g+rwX /opt/bitnami
|
||||||
|
RUN find / -perm /6000 -type f -exec chmod a-s {} \; || true
|
||||||
|
|
||||||
COPY rootfs /
|
COPY rootfs /
|
||||||
RUN /opt/bitnami/scripts/redis-sentinel/postunpack.sh
|
RUN /opt/bitnami/scripts/redis-sentinel/postunpack.sh
|
||||||
|
|||||||
@@ -1,22 +0,0 @@
|
|||||||
# Copyright VMware, Inc.
|
|
||||||
# SPDX-License-Identifier: APACHE-2.0
|
|
||||||
|
|
||||||
version: '2'
|
|
||||||
|
|
||||||
services:
|
|
||||||
redis-sentinel:
|
|
||||||
image: docker.io/bitnami/redis-sentinel:7.0
|
|
||||||
volumes:
|
|
||||||
- redis-sentinel_data:/bitnami
|
|
||||||
redis:
|
|
||||||
image: docker.io/bitnami/redis:7.0
|
|
||||||
environment:
|
|
||||||
# ALLOW_EMPTY_PASSWORD is recommended only for development.
|
|
||||||
- ALLOW_EMPTY_PASSWORD=yes
|
|
||||||
volumes:
|
|
||||||
- redis_data:/bitnami
|
|
||||||
volumes:
|
|
||||||
redis-sentinel_data:
|
|
||||||
driver: local
|
|
||||||
redis_data:
|
|
||||||
driver: local
|
|
||||||
@@ -13,13 +13,6 @@ Disclaimer: Redis is a registered trademark of Redis Ltd. Any rights therein are
|
|||||||
docker run --name redis-sentinel -e REDIS_MASTER_HOST=redis bitnami/redis-sentinel:latest
|
docker run --name redis-sentinel -e REDIS_MASTER_HOST=redis bitnami/redis-sentinel:latest
|
||||||
```
|
```
|
||||||
|
|
||||||
### Docker Compose
|
|
||||||
|
|
||||||
```console
|
|
||||||
curl -sSL https://raw.githubusercontent.com/bitnami/containers/main/bitnami/redis-sentinel/docker-compose.yml > docker-compose.yml
|
|
||||||
docker-compose up -d
|
|
||||||
```
|
|
||||||
|
|
||||||
**Warning**: This quick setup is only intended for development environments. You are encouraged to change the insecure default credentials and check out the available configuration options in the [Environment Variables](#environment-variables) section for a more secure deployment.
|
**Warning**: This quick setup is only intended for development environments. You are encouraged to change the insecure default credentials and check out the available configuration options in the [Environment Variables](#environment-variables) section for a more secure deployment.
|
||||||
|
|
||||||
## Why use Bitnami Images?
|
## Why use Bitnami Images?
|
||||||
@@ -105,93 +98,6 @@ docker run -it --rm \
|
|||||||
bitnami/redis-sentinel:latest
|
bitnami/redis-sentinel:latest
|
||||||
```
|
```
|
||||||
|
|
||||||
### Using a Docker Compose file
|
|
||||||
|
|
||||||
When not specified, Docker Compose automatically sets up a new network and attaches all deployed services to that network. However, we will explicitly define a new `bridge` network named `app-tier`. In this example we assume that you want to connect to the Redis(R) server from your own custom application image which is identified in the following snippet by the service name `myapp`.
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
version: '2'
|
|
||||||
|
|
||||||
networks:
|
|
||||||
app-tier:
|
|
||||||
driver: bridge
|
|
||||||
|
|
||||||
services:
|
|
||||||
redis:
|
|
||||||
image: 'bitnami/redis:latest'
|
|
||||||
environment:
|
|
||||||
- ALLOW_EMPTY_PASSWORD=yes
|
|
||||||
networks:
|
|
||||||
- app-tier
|
|
||||||
redis-sentinel:
|
|
||||||
image: 'bitnami/redis-sentinel:latest'
|
|
||||||
environment:
|
|
||||||
- REDIS_MASTER_HOST=redis
|
|
||||||
ports:
|
|
||||||
- '26379:26379'
|
|
||||||
networks:
|
|
||||||
- app-tier
|
|
||||||
```
|
|
||||||
|
|
||||||
Launch the containers using:
|
|
||||||
|
|
||||||
```console
|
|
||||||
docker-compose up -d
|
|
||||||
```
|
|
||||||
|
|
||||||
#### Using Master-Slave setups
|
|
||||||
|
|
||||||
When using Sentinel in Master-Slave setup, if you want to set the passwords for Master and Slave nodes, consider having the **same** `REDIS_PASSWORD` and `REDIS_MASTER_PASSWORD` for them.
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
version: '2'
|
|
||||||
|
|
||||||
networks:
|
|
||||||
app-tier:
|
|
||||||
driver: bridge
|
|
||||||
|
|
||||||
services:
|
|
||||||
redis:
|
|
||||||
image: 'bitnami/redis:latest'
|
|
||||||
environment:
|
|
||||||
- REDIS_REPLICATION_MODE=master
|
|
||||||
- REDIS_PASSWORD=str0ng_passw0rd
|
|
||||||
networks:
|
|
||||||
- app-tier
|
|
||||||
ports:
|
|
||||||
- '6379'
|
|
||||||
redis-slave:
|
|
||||||
image: 'bitnami/redis:latest'
|
|
||||||
environment:
|
|
||||||
- REDIS_REPLICATION_MODE=slave
|
|
||||||
- REDIS_MASTER_HOST=redis
|
|
||||||
- REDIS_MASTER_PASSWORD=str0ng_passw0rd
|
|
||||||
- REDIS_PASSWORD=str0ng_passw0rd
|
|
||||||
ports:
|
|
||||||
- '6379'
|
|
||||||
depends_on:
|
|
||||||
- redis
|
|
||||||
networks:
|
|
||||||
- app-tier
|
|
||||||
redis-sentinel:
|
|
||||||
image: 'bitnami/redis-sentinel:latest'
|
|
||||||
environment:
|
|
||||||
- REDIS_MASTER_PASSWORD=str0ng_passw0rd
|
|
||||||
depends_on:
|
|
||||||
- redis
|
|
||||||
- redis-slave
|
|
||||||
ports:
|
|
||||||
- '26379-26381:26379'
|
|
||||||
networks:
|
|
||||||
- app-tier
|
|
||||||
```
|
|
||||||
|
|
||||||
Launch the containers using:
|
|
||||||
|
|
||||||
```console
|
|
||||||
docker-compose up --scale redis-sentinel=3 -d
|
|
||||||
```
|
|
||||||
|
|
||||||
## Configuration
|
## Configuration
|
||||||
|
|
||||||
### Environment variables
|
### Environment variables
|
||||||
@@ -257,24 +163,6 @@ When enabling TLS, conventional standard traffic is disabled by default. However
|
|||||||
bitnami/redis-sentinel:latest
|
bitnami/redis-sentinel:latest
|
||||||
```
|
```
|
||||||
|
|
||||||
2. Modifying the `docker-compose.yml` file present in this repository:
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
redis-sentinel:
|
|
||||||
...
|
|
||||||
environment:
|
|
||||||
...
|
|
||||||
- REDIS_SENTINEL_TLS_ENABLED=yes
|
|
||||||
- REDIS_SENTINEL_TLS_CERT_FILE=/opt/bitnami/redis/certs/redis.crt
|
|
||||||
- REDIS_SENTINEL_TLS_KEY_FILE=/opt/bitnami/redis/certs/redis.key
|
|
||||||
- REDIS_SENTINEL_TLS_CA_FILE=/opt/bitnami/redis/certs/redisCA.crt
|
|
||||||
...
|
|
||||||
volumes:
|
|
||||||
- /path/to/certs:/opt/bitnami/redis/certs
|
|
||||||
...
|
|
||||||
...
|
|
||||||
```
|
|
||||||
|
|
||||||
Alternatively, you may also provide with this configuration in your [custom](https://github.com/bitnami/containers/blob/main/bitnami/redis-sentinel#configuration-file) configuration file.
|
Alternatively, you may also provide with this configuration in your [custom](https://github.com/bitnami/containers/blob/main/bitnami/redis-sentinel#configuration-file) configuration file.
|
||||||
|
|
||||||
### Configuration file
|
### Configuration file
|
||||||
@@ -292,17 +180,6 @@ docker run --name redis-sentinel \
|
|||||||
bitnami/redis-sentinel:latest
|
bitnami/redis-sentinel:latest
|
||||||
```
|
```
|
||||||
|
|
||||||
You can also modify the [`docker-compose.yml`](https://github.com/bitnami/containers/blob/main/bitnami/redis-sentinel/docker-compose.yml) file present in this repository:
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
services:
|
|
||||||
redis-sentinel:
|
|
||||||
...
|
|
||||||
volumes:
|
|
||||||
- /path/to/redis-persistence:/bitnami
|
|
||||||
...
|
|
||||||
```
|
|
||||||
|
|
||||||
#### Step 2: Edit the configuration
|
#### Step 2: Edit the configuration
|
||||||
|
|
||||||
Edit the configuration on your host using your favorite editor.
|
Edit the configuration on your host using your favorite editor.
|
||||||
@@ -319,12 +196,6 @@ After changing the configuration, restart your Redis(R) container for changes to
|
|||||||
docker restart redis
|
docker restart redis
|
||||||
```
|
```
|
||||||
|
|
||||||
or using Docker Compose:
|
|
||||||
|
|
||||||
```console
|
|
||||||
docker-compose restart redis
|
|
||||||
```
|
|
||||||
|
|
||||||
Refer to the [Redis(R) configuration](http://redis.io/topics/config) manual for the complete list of configuration options.
|
Refer to the [Redis(R) configuration](http://redis.io/topics/config) manual for the complete list of configuration options.
|
||||||
|
|
||||||
## Logging
|
## Logging
|
||||||
@@ -335,12 +206,6 @@ The Bitnami Redis(R) Sentinel Docker Image sends the container logs to the `stdo
|
|||||||
docker logs redis
|
docker logs redis
|
||||||
```
|
```
|
||||||
|
|
||||||
or using Docker Compose:
|
|
||||||
|
|
||||||
```console
|
|
||||||
docker-compose logs redis
|
|
||||||
```
|
|
||||||
|
|
||||||
You can configure the containers [logging driver](https://docs.docker.com/engine/admin/logging/overview/) using the `--log-driver` option if you wish to consume the container logs differently. In the default configuration docker uses the `json-file` driver.
|
You can configure the containers [logging driver](https://docs.docker.com/engine/admin/logging/overview/) using the `--log-driver` option if you wish to consume the container logs differently. In the default configuration docker uses the `json-file` driver.
|
||||||
|
|
||||||
## Maintenance
|
## Maintenance
|
||||||
@@ -355,9 +220,6 @@ Bitnami provides up-to-date versions of Redis(R) Sentinel, including security pa
|
|||||||
docker pull bitnami/redis-sentinel:latest
|
docker pull bitnami/redis-sentinel:latest
|
||||||
```
|
```
|
||||||
|
|
||||||
or if you're using Docker Compose, update the value of the image property to
|
|
||||||
`bitnami/redis-sentinel:latest`.
|
|
||||||
|
|
||||||
#### Step 2: Stop and backup the currently running container
|
#### Step 2: Stop and backup the currently running container
|
||||||
|
|
||||||
Stop the currently running container using the command
|
Stop the currently running container using the command
|
||||||
@@ -366,12 +228,6 @@ Stop the currently running container using the command
|
|||||||
docker stop redis
|
docker stop redis
|
||||||
```
|
```
|
||||||
|
|
||||||
or using Docker Compose:
|
|
||||||
|
|
||||||
```console
|
|
||||||
docker-compose stop redis
|
|
||||||
```
|
|
||||||
|
|
||||||
Next, take a snapshot of the persistent volume `/path/to/redis-persistence` using:
|
Next, take a snapshot of the persistent volume `/path/to/redis-persistence` using:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
@@ -384,12 +240,6 @@ rsync -a /path/to/redis-persistence /path/to/redis-persistence.bkp.$(date +%Y%m%
|
|||||||
docker rm -v redis
|
docker rm -v redis
|
||||||
```
|
```
|
||||||
|
|
||||||
or using Docker Compose:
|
|
||||||
|
|
||||||
```console
|
|
||||||
docker-compose rm -v redis
|
|
||||||
```
|
|
||||||
|
|
||||||
#### Step 4: Run the new image
|
#### Step 4: Run the new image
|
||||||
|
|
||||||
Re-create your container from the new image.
|
Re-create your container from the new image.
|
||||||
@@ -398,14 +248,12 @@ Re-create your container from the new image.
|
|||||||
docker run --name redis bitnami/redis-sentinel:latest
|
docker run --name redis bitnami/redis-sentinel:latest
|
||||||
```
|
```
|
||||||
|
|
||||||
or using Docker Compose:
|
|
||||||
|
|
||||||
```console
|
|
||||||
docker-compose up redis
|
|
||||||
```
|
|
||||||
|
|
||||||
## Notable Changes
|
## Notable Changes
|
||||||
|
|
||||||
|
### Starting January 16, 2024
|
||||||
|
|
||||||
|
* The `docker-compose.yaml` file has been removed, as it was solely intended for internal testing purposes.
|
||||||
|
|
||||||
### 4.0.14-debian-9-r201, 4.0.14-ol-7-r222, 5.0.5-debian-9-r169, 5.0.5-ol-7-r175
|
### 4.0.14-debian-9-r201, 4.0.14-ol-7-r222, 5.0.5-debian-9-r169, 5.0.5-ol-7-r175
|
||||||
|
|
||||||
* Decrease the size of the container. The configuration logic is now based on Bash scripts in the `rootfs/` folder.
|
* Decrease the size of the container. The configuration logic is now based on Bash scripts in the `rootfs/` folder.
|
||||||
|
|||||||
Reference in New Issue
Block a user