Question about dashboard issue with permission
Last active 14 days ago
16 replies
3 views
- KI
Hi I was wondering if someone could shed some light, Currently i have SWAG configured with crowdsec working and added the dashboard which loads correctly, but when i try to check on the dashboard i see permission issue opening db: '/metabase-data/crowdsec.db': Permission denied
This is what i have currently in the docker compose not sure what i missed?` crowdsec:
containername: crowdsec image: crowdsecurity/crowdsec:latest restart: unless-stopped dependson:
- swag
networks:
- openprojectfrontend environment: - COLLECTIONS=crowdsecurity/nginx - GID=1000 volumes: - /swag/log/nginx:/var/log/nginx:ro - ./crowdsec/acquis.yaml:/etc/crowdsec/acquis.yaml - ./crowdsec/crowdsec-db:/var/lib/crowdsec/data:rw - ./crowdsec/crowdsec-config:/etc/crowdsec:rw - /etc/timezone:/etc/timezone:ro - /etc/localtime:/etc/localtime:ro securityopt:
- no-new-privileges=truedashboard:
containername: crowdsec-dashboard build: ./crowdsec/dashboard restart: unless-stopped dependson:
- crowdsec
networks:
- openprojectfrontend ports: - 1111:3000 environment: - MBDB_FILE=/data/metabase.db
- MGID=1000
volumes:
- ./crowdsec:/metabase-data/` - KI
bump?
- II
You need to mount
./crowdsec/crowdsec-db:/metabase-data/
As the folder you mounted doesn't have the DB within it? Also try pulling the latest docker image as we made a few changes over this month
- KI
thank you so much for the reply, so i added that line to my dashboard but im getting this error when i try to docker compose up
- KI
ERROR: Duplicate mount points: [/swag/crowdsec:/metabase-data:rw, /swag/crowdsec/crowdsec-db:/metabase-data:rw]
- KI
dashboard: container_name: crowdsec-dashboard build: ./crowdsec/dashboard restart: unless-stopped depends_on: - crowdsec networks: - openproject_frontend ports: - 1111:3000 environment: - MB_DB_FILE=/data/metabase.db - MGID=1000 volumes: - ./crowdsec:/metabase-data/ - ./crowdsec/crowdsec-db:/metabase-data/
- II
You don't need the old mount you can get rid of it
- KI
`crowdsec:
containername: crowdsec image: crowdsecurity/crowdsec:latest restart: unless-stopped dependson:
- swag
networks:
- openprojectfrontend environment: - COLLECTIONS=crowdsecurity/nginx - GID=1000 volumes: - /swag/log/nginx:/var/log/nginx:ro - ./crowdsec/acquis.yaml:/etc/crowdsec/acquis.yaml - ./crowdsec/crowdsec-db:/var/lib/crowdsec/data:rw - ./crowdsec/crowdsec-config:/etc/crowdsec:rw - /etc/timezone:/etc/timezone:ro - /etc/localtime:/etc/localtime:ro securityopt:
- no-new-privileges=truedashboard:
containername: crowdsec-dashboard build: ./crowdsec/dashboard restart: unless-stopped dependson:
- crowdsec
networks:
- openprojectfrontend ports: - 1111:3000 environment: - MBDB_FILE=/data/metabase.db
- MGID=1000
volumes:
- ./crowdsec/crowdsec-db:/metabase-data/` - KI
would it be something like this?
- KI
i re ran docker compose up but im getting this
- KI
hi @iiamloz hope all is well, so i was checking the logs and keep seeing this issue [SQLITE_CANTOPEN] Unable to open the database file (unable to open database file) i went in the docker i thought it was a permission issue so i tried giving it full permission and no luck either
- II
Even though your on latest what is your latest image hash?
- KI
hi @iiamloz thanks for the reply, for the crowdsec i have this sha256:f1ec950dce3f5bf21fd6f816eb5ac8bebf51e7c7258c4a59cf8fafa62b74bbe9
- KI
and for the dashboard i have this sha256:bfda9bb68f2c1c44cd351303787f3a6c45fcf1281a8bdc96c75886efcf1abea2
- KI
o wait it seems checking the hash it was not updated to the newest one just updated it and it works flawless thank you so much
- II
Great! That's why I was asking as there was an issue 2 versions ago but glad it sorted <:alpacas:934162810852757515>
Last active 14 days ago
16 replies
3 views