docker-compose.yaml 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495
  1. version: '3'
  2. services:
  3. # API service
  4. api:
  5. image: langgenius/dify-api:0.6.10
  6. restart: always
  7. environment:
  8. # Startup mode, 'api' starts the API server.
  9. MODE: api
  10. # The log level for the application. Supported values are `DEBUG`, `INFO`, `WARNING`, `ERROR`, `CRITICAL`
  11. LOG_LEVEL: INFO
  12. # enable DEBUG mode to output more logs
  13. # DEBUG : true
  14. # A secret key that is used for securely signing the session cookie and encrypting sensitive information on the database. You can generate a strong key using `openssl rand -base64 42`.
  15. SECRET_KEY: sk-9f73s3ljTXVcMT3Blb3ljTqtsKiGHXVcMT3BlbkFJLK7U
  16. # The base URL of console application web frontend, refers to the Console base URL of WEB service if console domain is
  17. # different from api or web app domain.
  18. # example: http://cloud.dify.ai
  19. CONSOLE_WEB_URL: ''
  20. # Password for admin user initialization.
  21. # If left unset, admin user will not be prompted for a password when creating the initial admin account.
  22. INIT_PASSWORD: ''
  23. # The base URL of console application api server, refers to the Console base URL of WEB service if console domain is
  24. # different from api or web app domain.
  25. # example: http://cloud.dify.ai
  26. CONSOLE_API_URL: ''
  27. # The URL prefix for Service API endpoints, refers to the base URL of the current API service if api domain is
  28. # different from console domain.
  29. # example: http://api.dify.ai
  30. SERVICE_API_URL: ''
  31. # The URL prefix for Web APP frontend, refers to the Web App base URL of WEB service if web app domain is different from
  32. # console or api domain.
  33. # example: http://udify.app
  34. APP_WEB_URL: ''
  35. # File preview or download Url prefix.
  36. # used to display File preview or download Url to the front-end or as Multi-model inputs;
  37. # Url is signed and has expiration time.
  38. FILES_URL: ''
  39. # File Access Time specifies a time interval in seconds for the file to be accessed.
  40. # The default value is 300 seconds.
  41. FILES_ACCESS_TIMEOUT: 300
  42. # When enabled, migrations will be executed prior to application startup and the application will start after the migrations have completed.
  43. MIGRATION_ENABLED: 'true'
  44. # The configurations of postgres database connection.
  45. # It is consistent with the configuration in the 'db' service below.
  46. DB_USERNAME: postgres
  47. DB_PASSWORD: difyai123456
  48. DB_HOST: db
  49. DB_PORT: 5432
  50. DB_DATABASE: dify
  51. # The configurations of redis connection.
  52. # It is consistent with the configuration in the 'redis' service below.
  53. REDIS_HOST: redis
  54. REDIS_PORT: 6379
  55. REDIS_USERNAME: ''
  56. REDIS_PASSWORD: difyai123456
  57. REDIS_USE_SSL: 'false'
  58. # use redis db 0 for redis cache
  59. REDIS_DB: 0
  60. # The configurations of celery broker.
  61. # Use redis as the broker, and redis db 1 for celery broker.
  62. CELERY_BROKER_URL: redis://:difyai123456@redis:6379/1
  63. # Specifies the allowed origins for cross-origin requests to the Web API, e.g. https://dify.app or * for all origins.
  64. WEB_API_CORS_ALLOW_ORIGINS: '*'
  65. # Specifies the allowed origins for cross-origin requests to the console API, e.g. https://cloud.dify.ai or * for all origins.
  66. CONSOLE_CORS_ALLOW_ORIGINS: '*'
  67. # CSRF Cookie settings
  68. # Controls whether a cookie is sent with cross-site requests,
  69. # providing some protection against cross-site request forgery attacks
  70. #
  71. # Default: `SameSite=Lax, Secure=false, HttpOnly=true`
  72. # This default configuration supports same-origin requests using either HTTP or HTTPS,
  73. # but does not support cross-origin requests. It is suitable for local debugging purposes.
  74. #
  75. # If you want to enable cross-origin support,
  76. # you must use the HTTPS protocol and set the configuration to `SameSite=None, Secure=true, HttpOnly=true`.
  77. #
  78. # The type of storage to use for storing user files. Supported values are `local` and `s3` and `azure-blob` and `google-storage`, Default: `local`
  79. STORAGE_TYPE: local
  80. # The path to the local storage directory, the directory relative the root path of API service codes or absolute path. Default: `storage` or `/home/john/storage`.
  81. # only available when STORAGE_TYPE is `local`.
  82. STORAGE_LOCAL_PATH: storage
  83. # The S3 storage configurations, only available when STORAGE_TYPE is `s3`.
  84. S3_ENDPOINT: 'https://xxx.r2.cloudflarestorage.com'
  85. S3_BUCKET_NAME: 'difyai'
  86. S3_ACCESS_KEY: 'ak-difyai'
  87. S3_SECRET_KEY: 'sk-difyai'
  88. S3_REGION: 'us-east-1'
  89. # The Azure Blob storage configurations, only available when STORAGE_TYPE is `azure-blob`.
  90. AZURE_BLOB_ACCOUNT_NAME: 'difyai'
  91. AZURE_BLOB_ACCOUNT_KEY: 'difyai'
  92. AZURE_BLOB_CONTAINER_NAME: 'difyai-container'
  93. AZURE_BLOB_ACCOUNT_URL: 'https://<your_account_name>.blob.core.windows.net'
  94. # The Google storage configurations, only available when STORAGE_TYPE is `google-storage`.
  95. GOOGLE_STORAGE_BUCKET_NAME: 'yout-bucket-name'
  96. # if you want to use Application Default Credentials, you can leave GOOGLE_STORAGE_SERVICE_ACCOUNT_JSON_BASE64 empty.
  97. GOOGLE_STORAGE_SERVICE_ACCOUNT_JSON_BASE64: 'your-google-service-account-json-base64-string'
  98. # The type of vector store to use. Supported values are `weaviate`, `qdrant`, `milvus`, `relyt`.
  99. VECTOR_STORE: weaviate
  100. # The Weaviate endpoint URL. Only available when VECTOR_STORE is `weaviate`.
  101. WEAVIATE_ENDPOINT: http://weaviate:8080
  102. # The Weaviate API key.
  103. WEAVIATE_API_KEY: WVF5YThaHlkYwhGUSmCRgsX3tD5ngdN8pkih
  104. # The Qdrant endpoint URL. Only available when VECTOR_STORE is `qdrant`.
  105. QDRANT_URL: http://qdrant:6333
  106. # The Qdrant API key.
  107. QDRANT_API_KEY: difyai123456
  108. # The Qdrant client timeout setting.
  109. QDRANT_CLIENT_TIMEOUT: 20
  110. # The Qdrant client enable gRPC mode.
  111. QDRANT_GRPC_ENABLED: 'false'
  112. # The Qdrant server gRPC mode PORT.
  113. QDRANT_GRPC_PORT: 6334
  114. # Milvus configuration Only available when VECTOR_STORE is `milvus`.
  115. # The milvus host.
  116. MILVUS_HOST: 127.0.0.1
  117. # The milvus host.
  118. MILVUS_PORT: 19530
  119. # The milvus username.
  120. MILVUS_USER: root
  121. # The milvus password.
  122. MILVUS_PASSWORD: Milvus
  123. # The milvus tls switch.
  124. MILVUS_SECURE: 'false'
  125. # relyt configurations
  126. RELYT_HOST: db
  127. RELYT_PORT: 5432
  128. RELYT_USER: postgres
  129. RELYT_PASSWORD: difyai123456
  130. RELYT_DATABASE: postgres
  131. # pgvector configurations
  132. PGVECTOR_HOST: pgvector
  133. PGVECTOR_PORT: 5432
  134. PGVECTOR_USER: postgres
  135. PGVECTOR_PASSWORD: difyai123456
  136. PGVECTOR_DATABASE: dify
  137. # tidb vector configurations
  138. TIDB_VECTOR_HOST: tidb
  139. TIDB_VECTOR_PORT: 4000
  140. TIDB_VECTOR_USER: xxx.root
  141. TIDB_VECTOR_PASSWORD: xxxxxx
  142. TIDB_VECTOR_DATABASE: dify
  143. # Mail configuration, support: resend, smtp
  144. MAIL_TYPE: ''
  145. # default send from email address, if not specified
  146. MAIL_DEFAULT_SEND_FROM: 'YOUR EMAIL FROM (eg: no-reply <no-reply@dify.ai>)'
  147. SMTP_SERVER: ''
  148. SMTP_PORT: 465
  149. SMTP_USERNAME: ''
  150. SMTP_PASSWORD: ''
  151. SMTP_USE_TLS: 'true'
  152. SMTP_OPPORTUNISTIC_TLS: 'false'
  153. # the api-key for resend (https://resend.com)
  154. RESEND_API_KEY: ''
  155. RESEND_API_URL: https://api.resend.com
  156. # The DSN for Sentry error reporting. If not set, Sentry error reporting will be disabled.
  157. SENTRY_DSN: ''
  158. # The sample rate for Sentry events. Default: `1.0`
  159. SENTRY_TRACES_SAMPLE_RATE: 1.0
  160. # The sample rate for Sentry profiles. Default: `1.0`
  161. SENTRY_PROFILES_SAMPLE_RATE: 1.0
  162. # Notion import configuration, support public and internal
  163. NOTION_INTEGRATION_TYPE: public
  164. NOTION_CLIENT_SECRET: you-client-secret
  165. NOTION_CLIENT_ID: you-client-id
  166. NOTION_INTERNAL_SECRET: you-internal-secret
  167. # The sandbox service endpoint.
  168. CODE_EXECUTION_ENDPOINT: "http://sandbox:8194"
  169. CODE_EXECUTION_API_KEY: dify-sandbox
  170. CODE_MAX_NUMBER: 9223372036854775807
  171. CODE_MIN_NUMBER: -9223372036854775808
  172. CODE_MAX_STRING_LENGTH: 80000
  173. TEMPLATE_TRANSFORM_MAX_LENGTH: 80000
  174. CODE_MAX_STRING_ARRAY_LENGTH: 30
  175. CODE_MAX_OBJECT_ARRAY_LENGTH: 30
  176. CODE_MAX_NUMBER_ARRAY_LENGTH: 1000
  177. # SSRF Proxy server
  178. SSRF_PROXY_HTTP_URL: 'http://ssrf_proxy:3128'
  179. SSRF_PROXY_HTTPS_URL: 'http://ssrf_proxy:3128'
  180. # Indexing configuration
  181. INDEXING_MAX_SEGMENTATION_TOKENS_LENGTH: 1000
  182. depends_on:
  183. - db
  184. - redis
  185. volumes:
  186. # Mount the storage directory to the container, for storing user files.
  187. - ./volumes/app/storage:/app/api/storage
  188. # uncomment to expose dify-api port to host
  189. # ports:
  190. # - "5001:5001"
  191. networks:
  192. - ssrf_proxy_network
  193. - default
  194. # worker service
  195. # The Celery worker for processing the queue.
  196. worker:
  197. image: langgenius/dify-api:0.6.10
  198. restart: always
  199. environment:
  200. CONSOLE_WEB_URL: ''
  201. # Startup mode, 'worker' starts the Celery worker for processing the queue.
  202. MODE: worker
  203. # --- All the configurations below are the same as those in the 'api' service. ---
  204. # The log level for the application. Supported values are `DEBUG`, `INFO`, `WARNING`, `ERROR`, `CRITICAL`
  205. LOG_LEVEL: INFO
  206. # A secret key that is used for securely signing the session cookie and encrypting sensitive information on the database. You can generate a strong key using `openssl rand -base64 42`.
  207. # same as the API service
  208. SECRET_KEY: sk-9f73s3ljTXVcMT3Blb3ljTqtsKiGHXVcMT3BlbkFJLK7U
  209. # The configurations of postgres database connection.
  210. # It is consistent with the configuration in the 'db' service below.
  211. DB_USERNAME: postgres
  212. DB_PASSWORD: difyai123456
  213. DB_HOST: db
  214. DB_PORT: 5432
  215. DB_DATABASE: dify
  216. # The configurations of redis cache connection.
  217. REDIS_HOST: redis
  218. REDIS_PORT: 6379
  219. REDIS_USERNAME: ''
  220. REDIS_PASSWORD: difyai123456
  221. REDIS_DB: 0
  222. REDIS_USE_SSL: 'false'
  223. # The configurations of celery broker.
  224. CELERY_BROKER_URL: redis://:difyai123456@redis:6379/1
  225. # The type of storage to use for storing user files. Supported values are `local` and `s3` and `azure-blob` and `google-storage`, Default: `local`
  226. STORAGE_TYPE: local
  227. STORAGE_LOCAL_PATH: storage
  228. # The S3 storage configurations, only available when STORAGE_TYPE is `s3`.
  229. S3_ENDPOINT: 'https://xxx.r2.cloudflarestorage.com'
  230. S3_BUCKET_NAME: 'difyai'
  231. S3_ACCESS_KEY: 'ak-difyai'
  232. S3_SECRET_KEY: 'sk-difyai'
  233. S3_REGION: 'us-east-1'
  234. # The Azure Blob storage configurations, only available when STORAGE_TYPE is `azure-blob`.
  235. AZURE_BLOB_ACCOUNT_NAME: 'difyai'
  236. AZURE_BLOB_ACCOUNT_KEY: 'difyai'
  237. AZURE_BLOB_CONTAINER_NAME: 'difyai-container'
  238. AZURE_BLOB_ACCOUNT_URL: 'https://<your_account_name>.blob.core.windows.net'
  239. # The Google storage configurations, only available when STORAGE_TYPE is `google-storage`.
  240. GOOGLE_STORAGE_BUCKET_NAME: 'yout-bucket-name'
  241. # if you want to use Application Default Credentials, you can leave GOOGLE_STORAGE_SERVICE_ACCOUNT_JSON_BASE64 empty.
  242. GOOGLE_STORAGE_SERVICE_ACCOUNT_JSON_BASE64: 'your-google-service-account-json-base64-string'
  243. # The type of vector store to use. Supported values are `weaviate`, `qdrant`, `milvus`, `relyt`, `pgvector`.
  244. VECTOR_STORE: weaviate
  245. # The Weaviate endpoint URL. Only available when VECTOR_STORE is `weaviate`.
  246. WEAVIATE_ENDPOINT: http://weaviate:8080
  247. # The Weaviate API key.
  248. WEAVIATE_API_KEY: WVF5YThaHlkYwhGUSmCRgsX3tD5ngdN8pkih
  249. # The Qdrant endpoint URL. Only available when VECTOR_STORE is `qdrant`.
  250. QDRANT_URL: http://qdrant:6333
  251. # The Qdrant API key.
  252. QDRANT_API_KEY: difyai123456
  253. # The Qdrant client timeout setting.
  254. QDRANT_CLIENT_TIMEOUT: 20
  255. # The Qdrant client enable gRPC mode.
  256. QDRANT_GRPC_ENABLED: 'false'
  257. # The Qdrant server gRPC mode PORT.
  258. QDRANT_GRPC_PORT: 6334
  259. # Milvus configuration Only available when VECTOR_STORE is `milvus`.
  260. # The milvus host.
  261. MILVUS_HOST: 127.0.0.1
  262. # The milvus host.
  263. MILVUS_PORT: 19530
  264. # The milvus username.
  265. MILVUS_USER: root
  266. # The milvus password.
  267. MILVUS_PASSWORD: Milvus
  268. # The milvus tls switch.
  269. MILVUS_SECURE: 'false'
  270. # Mail configuration, support: resend
  271. MAIL_TYPE: ''
  272. # default send from email address, if not specified
  273. MAIL_DEFAULT_SEND_FROM: 'YOUR EMAIL FROM (eg: no-reply <no-reply@dify.ai>)'
  274. SMTP_SERVER: ''
  275. SMTP_PORT: 465
  276. SMTP_USERNAME: ''
  277. SMTP_PASSWORD: ''
  278. SMTP_USE_TLS: 'true'
  279. SMTP_OPPORTUNISTIC_TLS: 'false'
  280. # the api-key for resend (https://resend.com)
  281. RESEND_API_KEY: ''
  282. RESEND_API_URL: https://api.resend.com
  283. # relyt configurations
  284. RELYT_HOST: db
  285. RELYT_PORT: 5432
  286. RELYT_USER: postgres
  287. RELYT_PASSWORD: difyai123456
  288. RELYT_DATABASE: postgres
  289. # pgvector configurations
  290. PGVECTOR_HOST: pgvector
  291. PGVECTOR_PORT: 5432
  292. PGVECTOR_USER: postgres
  293. PGVECTOR_PASSWORD: difyai123456
  294. PGVECTOR_DATABASE: dify
  295. # tidb vector configurations
  296. TIDB_VECTOR_HOST: tidb
  297. TIDB_VECTOR_PORT: 4000
  298. TIDB_VECTOR_USER: xxx.root
  299. TIDB_VECTOR_PASSWORD: xxxxxx
  300. TIDB_VECTOR_DATABASE: dify
  301. # Notion import configuration, support public and internal
  302. NOTION_INTEGRATION_TYPE: public
  303. NOTION_CLIENT_SECRET: you-client-secret
  304. NOTION_CLIENT_ID: you-client-id
  305. NOTION_INTERNAL_SECRET: you-internal-secret
  306. # Indexing configuration
  307. INDEXING_MAX_SEGMENTATION_TOKENS_LENGTH: 1000
  308. depends_on:
  309. - db
  310. - redis
  311. volumes:
  312. # Mount the storage directory to the container, for storing user files.
  313. - ./volumes/app/storage:/app/api/storage
  314. networks:
  315. - ssrf_proxy_network
  316. - default
  317. # Frontend web application.
  318. web:
  319. image: langgenius/dify-web:0.6.10
  320. restart: always
  321. environment:
  322. # The base URL of console application api server, refers to the Console base URL of WEB service if console domain is
  323. # different from api or web app domain.
  324. # example: http://cloud.dify.ai
  325. CONSOLE_API_URL: ''
  326. # The URL for Web APP api server, refers to the Web App base URL of WEB service if web app domain is different from
  327. # console or api domain.
  328. # example: http://udify.app
  329. APP_API_URL: ''
  330. # The DSN for Sentry error reporting. If not set, Sentry error reporting will be disabled.
  331. SENTRY_DSN: ''
  332. # uncomment to expose dify-web port to host
  333. # ports:
  334. # - "3000:3000"
  335. # The postgres database.
  336. db:
  337. image: postgres:15-alpine
  338. restart: always
  339. environment:
  340. PGUSER: postgres
  341. # The password for the default postgres user.
  342. POSTGRES_PASSWORD: difyai123456
  343. # The name of the default postgres database.
  344. POSTGRES_DB: dify
  345. # postgres data directory
  346. PGDATA: /var/lib/postgresql/data/pgdata
  347. volumes:
  348. - ./volumes/db/data:/var/lib/postgresql/data
  349. # uncomment to expose db(postgresql) port to host
  350. # ports:
  351. # - "5432:5432"
  352. healthcheck:
  353. test: [ "CMD", "pg_isready" ]
  354. interval: 1s
  355. timeout: 3s
  356. retries: 30
  357. # The redis cache.
  358. redis:
  359. image: redis:6-alpine
  360. restart: always
  361. volumes:
  362. # Mount the redis data directory to the container.
  363. - ./volumes/redis/data:/data
  364. # Set the redis password when startup redis server.
  365. command: redis-server --requirepass difyai123456
  366. healthcheck:
  367. test: [ "CMD", "redis-cli", "ping" ]
  368. # uncomment to expose redis port to host
  369. # ports:
  370. # - "6379:6379"
  371. # The Weaviate vector store.
  372. weaviate:
  373. image: semitechnologies/weaviate:1.19.0
  374. restart: always
  375. volumes:
  376. # Mount the Weaviate data directory to the container.
  377. - ./volumes/weaviate:/var/lib/weaviate
  378. environment:
  379. # The Weaviate configurations
  380. # You can refer to the [Weaviate](https://weaviate.io/developers/weaviate/config-refs/env-vars) documentation for more information.
  381. QUERY_DEFAULTS_LIMIT: 25
  382. AUTHENTICATION_ANONYMOUS_ACCESS_ENABLED: 'false'
  383. PERSISTENCE_DATA_PATH: '/var/lib/weaviate'
  384. DEFAULT_VECTORIZER_MODULE: 'none'
  385. CLUSTER_HOSTNAME: 'node1'
  386. AUTHENTICATION_APIKEY_ENABLED: 'true'
  387. AUTHENTICATION_APIKEY_ALLOWED_KEYS: 'WVF5YThaHlkYwhGUSmCRgsX3tD5ngdN8pkih'
  388. AUTHENTICATION_APIKEY_USERS: 'hello@dify.ai'
  389. AUTHORIZATION_ADMINLIST_ENABLED: 'true'
  390. AUTHORIZATION_ADMINLIST_USERS: 'hello@dify.ai'
  391. # uncomment to expose weaviate port to host
  392. # ports:
  393. # - "8080:8080"
  394. # The DifySandbox
  395. sandbox:
  396. image: langgenius/dify-sandbox:0.2.1
  397. restart: always
  398. environment:
  399. # The DifySandbox configurations
  400. # Make sure you are changing this key for your deployment with a strong key.
  401. # You can generate a strong key using `openssl rand -base64 42`.
  402. API_KEY: dify-sandbox
  403. GIN_MODE: 'release'
  404. WORKER_TIMEOUT: 15
  405. ENABLE_NETWORK: 'true'
  406. HTTP_PROXY: 'http://ssrf_proxy:3128'
  407. HTTPS_PROXY: 'http://ssrf_proxy:3128'
  408. SANDBOX_PORT: 8194
  409. volumes:
  410. - ./volumes/sandbox/dependencies:/dependencies
  411. networks:
  412. - ssrf_proxy_network
  413. # ssrf_proxy server
  414. # for more information, please refer to
  415. # https://docs.dify.ai/getting-started/install-self-hosted/install-faq#id-16.-why-is-ssrf_proxy-needed
  416. ssrf_proxy:
  417. image: ubuntu/squid:latest
  418. restart: always
  419. volumes:
  420. # pls clearly modify the squid.conf file to fit your network environment.
  421. - ./volumes/ssrf_proxy/squid.conf:/etc/squid/squid.conf
  422. networks:
  423. - ssrf_proxy_network
  424. - default
  425. # Qdrant vector store.
  426. # uncomment to use qdrant as vector store.
  427. # (if uncommented, you need to comment out the weaviate service above,
  428. # and set VECTOR_STORE to qdrant in the api & worker service.)
  429. # qdrant:
  430. # image: langgenius/qdrant:v1.7.3
  431. # restart: always
  432. # volumes:
  433. # - ./volumes/qdrant:/qdrant/storage
  434. # environment:
  435. # QDRANT_API_KEY: 'difyai123456'
  436. # # uncomment to expose qdrant port to host
  437. # # ports:
  438. # # - "6333:6333"
  439. # # - "6334:6334"
  440. # The pgvector vector database.
  441. # Uncomment to use qdrant as vector store.
  442. # pgvector:
  443. # image: pgvector/pgvector:pg16
  444. # restart: always
  445. # environment:
  446. # PGUSER: postgres
  447. # # The password for the default postgres user.
  448. # POSTGRES_PASSWORD: difyai123456
  449. # # The name of the default postgres database.
  450. # POSTGRES_DB: dify
  451. # # postgres data directory
  452. # PGDATA: /var/lib/postgresql/data/pgdata
  453. # volumes:
  454. # - ./volumes/pgvector/data:/var/lib/postgresql/data
  455. # # uncomment to expose db(postgresql) port to host
  456. # # ports:
  457. # # - "5433:5432"
  458. # healthcheck:
  459. # test: [ "CMD", "pg_isready" ]
  460. # interval: 1s
  461. # timeout: 3s
  462. # retries: 30
  463. # The nginx reverse proxy.
  464. # used for reverse proxying the API service and Web service.
  465. nginx:
  466. image: nginx:latest
  467. restart: always
  468. volumes:
  469. - ./nginx/nginx.conf:/etc/nginx/nginx.conf
  470. - ./nginx/proxy.conf:/etc/nginx/proxy.conf
  471. - ./nginx/conf.d:/etc/nginx/conf.d
  472. #- ./nginx/ssl:/etc/ssl
  473. depends_on:
  474. - api
  475. - web
  476. ports:
  477. - "80:80"
  478. #- "443:443"
  479. networks:
  480. # create a network between sandbox, api and ssrf_proxy, and can not access outside.
  481. ssrf_proxy_network:
  482. driver: bridge
  483. internal: true