From 1c56c8138293c4c2ee0bf69a8701fd334c972f6e Mon Sep 17 00:00:00 2001 From: M_Viper Date: Mon, 12 Feb 2024 21:26:10 +0000 Subject: [PATCH] Dateien nach "install-redis-on-docker" hochladen --- install-redis-on-docker/docker-compose.yml | 29 ++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 install-redis-on-docker/docker-compose.yml diff --git a/install-redis-on-docker/docker-compose.yml b/install-redis-on-docker/docker-compose.yml new file mode 100644 index 0000000..3b529c7 --- /dev/null +++ b/install-redis-on-docker/docker-compose.yml @@ -0,0 +1,29 @@ +# Specify the version of the Docker Compose file format. +# This determines the available features and syntax. +version: "3" + +# Define the services (containers) that will be created and run. +services: + # Service name: 'redis' + redis: + # The Docker image to use for this service. + image: redis:latest + + # Assign a custom name to the running container. + container_name: M_Viper-redis + + # Map ports between the host and the container. + # Host port is on the left (6379) and container port is on the right (6379). + ports: + - "6379:6379" + + # Mount volumes to persist data and share it between the host and container. + # The host directory (redis_data) is mounted to the container directory (/data). + volumes: + - redis_data:/data + +# Define the volumes that will be created and mounted. +volumes: + redis_data: + # Use the local storage driver. + driver: local