From 95756a61e18c88ea179e2bcc5e358bdac6964105 Mon Sep 17 00:00:00 2001 From: timqiu <9145422+cocoonwind@user.noreply.gitee.com> Date: Sat, 29 Mar 2025 07:24:25 +0800 Subject: [PATCH] Update for devbox depends on for redis --- devbox/cli/devbox | 15 +----- devbox/cli/docker-compose.yaml | 84 ++++++++++++++++++++++++++-------- 2 files changed, 67 insertions(+), 32 deletions(-) diff --git a/devbox/cli/devbox b/devbox/cli/devbox index 9fcc05b..0318349 100755 --- a/devbox/cli/devbox +++ b/devbox/cli/devbox @@ -1197,7 +1197,7 @@ docker exec -i "$DEVBOX_NAME" bash < /dev/null fi else diff --git a/devbox/cli/docker-compose.yaml b/devbox/cli/docker-compose.yaml index 272421e..c7123c5 100644 --- a/devbox/cli/docker-compose.yaml +++ b/devbox/cli/docker-compose.yaml @@ -78,18 +78,11 @@ services: start_period: 30s volumes: - ${WORKING_HOME}/freeleaps2-redis-data:/var/lib/redis - devsvc: container_name: devsvc image: freeleaps/devsvc:${DEVSVC_IMAGE_TAG:-latest-linux-arm64} restart: always - depends_on: - mongodb: - condition: service_healthy - rabbitmq: - condition: service_healthy - gitea: - condition: service_healthy + environment: - APP_NAME=devsvc - SERVICE_API_ACCESS_HOST=localhost @@ -119,6 +112,15 @@ services: target: /app/log/devsvc networks: - devbox_freeleaps2-network + depends_on: + mongodb: + condition: service_healthy + rabbitmq: + condition: service_healthy + gitea: + condition: service_healthy + redis: + condition: service_healthy central_storage: container_name: central_storage @@ -150,6 +152,15 @@ services: - type: bind source: ${WORKING_HOME}/logs/central_storage target: /app/log/central_storage + depends_on: + mongodb: + condition: service_healthy + rabbitmq: + condition: service_healthy + gitea: + condition: service_healthy + redis: + condition: service_healthy authentication: container_name: authentication @@ -183,6 +194,15 @@ services: - type: bind source: ${WORKING_HOME}/logs/authentication target: /app/log/authentication + depends_on: + mongodb: + condition: service_healthy + rabbitmq: + condition: service_healthy + gitea: + condition: service_healthy + redis: + condition: service_healthy content: container_name: content @@ -213,15 +233,21 @@ services: - type: bind source: ${WORKING_HOME}/logs/content target: /app/log/content - + depends_on: + mongodb: + condition: service_healthy + rabbitmq: + condition: service_healthy + gitea: + condition: service_healthy + redis: + condition: service_healthy notification: container_name: notification image: freeleaps/notification:${NOTIFICATION_IMAGE_TAG:-latest-linux-arm64} platform: linux/${ARCH:-arm64} restart: always - depends_on: - rabbitmq: - condition: service_healthy + environment: - APP_NAME=notification - SERVICE_API_ACCESS_HOST=localhost @@ -251,6 +277,15 @@ services: - type: bind source: ${WORKING_HOME}/logs/notification target: /app/log/notification + depends_on: + mongodb: + condition: service_healthy + rabbitmq: + condition: service_healthy + gitea: + condition: service_healthy + redis: + condition: service_healthy payment: container_name: payment image: freeleaps/payment:latest-linux-arm64 @@ -284,19 +319,21 @@ services: - type: bind source: /var/lib/docker/app/payment/log target: /app/log/payment + depends_on: + mongodb: + condition: service_healthy + rabbitmq: + condition: service_healthy + gitea: + condition: service_healthy + redis: + condition: service_healthy chat: container_name: chat build: context: ${WORKING_HOME}/freeleaps/apps dockerfile: ${WORKING_HOME}/freeleaps/apps/chat/Dockerfile restart: always - depends_on: - mongodb: - condition: service_healthy - rabbitmq: - condition: service_healthy - redis: - condition: service_healthy ports: - 8012:8012 environment: @@ -335,6 +372,15 @@ services: target: /app/log/freeleaps-chat networks: - devbox_freeleaps2-network + depends_on: + mongodb: + condition: service_healthy + rabbitmq: + condition: service_healthy + gitea: + condition: service_healthy + redis: + condition: service_healthy volumes: freeleaps2-mongodb-data: freeleaps2-gitea-data: