Fix backend unable to open fail2ban database in dev compose
The backend container mounted fail2ban-dev-config as an anonymous named volume, while the fail2ban container used a bind-mount of the same local directory. The backend's /config was therefore always empty, causing sqlite3.OperationalError when ban_service attempted to open the path returned by 'get dbfile' (/config/fail2ban/fail2ban.sqlite3). Change the backend volume declaration from the named volume reference to the same bind-mount used by fail2ban: fail2ban-dev-config:/config:ro → ./fail2ban-dev-config:/config:ro Also removes the now-unused 'fail2ban-dev-config' named-volume entry. Affected endpoints (all returned HTTP 500, now return HTTP 200): GET /api/dashboard/bans GET /api/dashboard/accesses GET /api/dashboard/bans/by-country
This commit is contained in:
@@ -65,7 +65,7 @@ services:
|
|||||||
- ../fail2ban-master:/app/fail2ban-master:ro,z
|
- ../fail2ban-master:/app/fail2ban-master:ro,z
|
||||||
- bangui-dev-data:/data
|
- bangui-dev-data:/data
|
||||||
- fail2ban-dev-run:/var/run/fail2ban:ro
|
- fail2ban-dev-run:/var/run/fail2ban:ro
|
||||||
- fail2ban-dev-config:/config:ro
|
- ./fail2ban-dev-config:/config:ro
|
||||||
ports:
|
ports:
|
||||||
- "${BANGUI_BACKEND_PORT:-8000}:8000"
|
- "${BANGUI_BACKEND_PORT:-8000}:8000"
|
||||||
command:
|
command:
|
||||||
@@ -114,8 +114,6 @@ volumes:
|
|||||||
driver: local
|
driver: local
|
||||||
frontend-node-modules:
|
frontend-node-modules:
|
||||||
driver: local
|
driver: local
|
||||||
fail2ban-dev-config:
|
|
||||||
driver: local
|
|
||||||
fail2ban-dev-run:
|
fail2ban-dev-run:
|
||||||
driver: local
|
driver: local
|
||||||
|
|
||||||
|
|||||||
1034
Docs/Tasks.md
1034
Docs/Tasks.md
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user