appstore-1panel/apps/redis/7.2.6/docker-compose.yml
github-action update-app-version e65d897d30 Update app version [skip ci]
2024-10-07 22:26:43 +00:00

27 lines
651 B
YAML

networks:
1panel-network:
external: true
services:
redis:
image: redis:7.2.6-alpine
container_name: ${CONTAINER_NAME}
labels:
createdBy: "Apps"
restart: always
networks:
- 1panel-network
ports:
- ${PANEL_APP_PORT_HTTP}:6379
command: >
sh -c '
if [ -z "${REDIS_ROOT_PASSWORD}" ]; then
redis-server /etc/redis/redis.conf
else
redis-server /etc/redis/redis.conf --requirepass ${REDIS_ROOT_PASSWORD}
fi'
volumes:
- ${REDIS_ROOT_PATH}/data:/data
- ${REDIS_ROOT_PATH}/config/redis.conf:/etc/redis/redis.conf
- ${REDIS_ROOT_PATH}/logs:/logs