Browse Source

Add 'python/docker-compose.yml'

天问 1 year ago
parent
commit
42d765d72b
1 changed files with 77 additions and 0 deletions
  1. 77 0
      python/docker-compose.yml

+ 77 - 0
python/docker-compose.yml

@@ -0,0 +1,77 @@
+version: "3"
+
+services:
+
+  nginx:
+    container_name: infisical-nginx
+    image: nginx
+    restart: always
+    ports:
+      - 80:80
+      - 443:443
+    volumes:
+      - ./nginx/default.conf:/etc/nginx/conf.d/default.conf:ro
+    depends_on:
+      - frontend
+      - backend
+    networks:
+      - infisical
+
+  backend:
+    container_name: infisical-backend
+    restart: unless-stopped
+    depends_on:
+      - mongo
+    image: infisical/backend
+    env_file: .env
+    environment:
+      - NODE_ENV=production
+    networks:
+      - infisical
+
+  frontend:
+    container_name: infisical-frontend
+    restart: unless-stopped
+    depends_on:
+      - backend
+    image: infisical/frontend
+    env_file: .env
+    environment:
+      # - NEXT_PUBLIC_POSTHOG_API_KEY=${POSTHOG_PROJECT_API_KEY}
+      - INFISICAL_TELEMETRY_ENABLED=${TELEMETRY_ENABLED}
+    networks:
+      - infisical
+
+  redis:
+    image: redis
+    container_name: infisical-dev-redis
+    environment:
+      - ALLOW_EMPTY_PASSWORD=yes
+    ports:
+      - 6379:6379
+    networks:
+      - infisical
+    volumes:
+      - redis_data:/data
+
+  mongo:
+    container_name: infisical-mongo
+    image: mongo
+    restart: always
+    env_file: .env
+    environment:
+      - MONGO_INITDB_ROOT_USERNAME=${MONGO_USERNAME}
+      - MONGO_INITDB_ROOT_PASSWORD=${MONGO_PASSWORD}
+    volumes:
+      - mongo-data:/data/db
+    networks:
+      - infisical
+
+volumes:
+  mongo-data:
+    driver: local
+  redis_data:
+    driver: local
+
+networks:
+  infisical: