From 4745ea30cce7c7ac7cef1a5c80d1d404f19e1ca0 Mon Sep 17 00:00:00 2001 From: mz-h <125813388+mz-h@users.noreply.github.com> Date: Thu, 5 Dec 2024 01:17:03 -0500 Subject: [PATCH] Fix Connection Error (#1524) --- pwd.yml | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/pwd.yml b/pwd.yml index 1baa1a2d..3eb24472 100644 --- a/pwd.yml +++ b/pwd.yml @@ -3,22 +3,30 @@ version: "3" services: backend: image: frappe/erpnext:v15.45.0 + networks: + - frappe_network deploy: restart_policy: condition: on-failure volumes: - sites:/home/frappe/frappe-bench/sites - logs:/home/frappe/frappe-bench/logs + environment: + DB_HOST: db + DB_PORT: "3306" + MYSQL_ROOT_PASSWORD: admin + MARIADB_ROOT_PASSWORD: admin configurator: image: frappe/erpnext:v15.45.0 + networks: + - frappe_network deploy: restart_policy: condition: none entrypoint: - bash - -c - # add redis_socketio for backward compatibility command: - > ls -1 apps > sites/apps.txt; @@ -40,6 +48,8 @@ services: create-site: image: frappe/erpnext:v15.45.0 + networks: + - frappe_network deploy: restart_policy: condition: none @@ -71,6 +81,8 @@ services: db: image: mariadb:10.6 + networks: + - frappe_network healthcheck: test: mysqladmin ping -h localhost --password=admin interval: 1s @@ -91,6 +103,8 @@ services: frontend: image: frappe/erpnext:v15.45.0 + networks: + - frappe_network depends_on: - websocket deploy: @@ -115,6 +129,8 @@ services: queue-long: image: frappe/erpnext:v15.45.0 + networks: + - frappe_network deploy: restart_policy: condition: on-failure @@ -129,6 +145,8 @@ services: queue-short: image: frappe/erpnext:v15.45.0 + networks: + - frappe_network deploy: restart_policy: condition: on-failure @@ -143,6 +161,8 @@ services: redis-queue: image: redis:6.2-alpine + networks: + - frappe_network deploy: restart_policy: condition: on-failure @@ -151,6 +171,8 @@ services: redis-cache: image: redis:6.2-alpine + networks: + - frappe_network deploy: restart_policy: condition: on-failure @@ -159,6 +181,8 @@ services: scheduler: image: frappe/erpnext:v15.45.0 + networks: + - frappe_network deploy: restart_policy: condition: on-failure @@ -171,6 +195,8 @@ services: websocket: image: frappe/erpnext:v15.45.0 + networks: + - frappe_network deploy: restart_policy: condition: on-failure @@ -187,3 +213,7 @@ volumes: redis-cache-data: sites: logs: + +networks: + frappe_network: + driver: bridge