Skip to content

Commit b676f44

Browse files
authored
Merge pull request #583 from MerginMaps/581-have-troubleshoot-section-for-permissions-related-errors
581 have troubleshoot section for permissions related errors
2 parents 0eef979 + b81e109 commit b676f44

File tree

2 files changed

+47
-8
lines changed

2 files changed

+47
-8
lines changed

src/server/install/index.md

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -150,14 +150,15 @@ $ docker exec merginmaps-server flask server check
150150
Output will be similar to the next snippet. The utility will try to provide some background information if some needed environment variable is missing or wrongly set (ex: `MERGIN_BASE_URL`)
151151

152152
```shell
153-
# Server health check
154-
155-
Mergin Maps edition: Enterprise Edition
156-
Mergin Maps version: 2025.2.0
157-
Error: No base URL set. Please set MERGIN_BASE_URL environment variable
158-
Error: No contact email set. Please set CONTACT_EMAIL environment variable
159-
Database initialized properly
160-
Celery running properly
153+
# Server health check
154+
155+
Mergin Maps edition: Enterprise Edition
156+
Mergin Maps version: 2025.2.0
157+
Error: No base URL set. Please set MERGIN_BASE_URL environment variable
158+
Error: No contact email set. Please set CONTACT_EMAIL environment variable
159+
Database initialized properly
160+
Permissions granted for /data folder
161+
Celery running properly
161162
```
162163

163164
To test email configuration:

src/server/troubleshoot/index.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,44 @@ Logs should contain information about sending emails with task `mergin.celery.se
5353
[2024-12-09 10:37:16,265: INFO/ForkPoolWorker-2] Task mergin.celery.send_email_async[3e50df69-90c1-49be-b31c-78f1fb417500] succeeded in 0.11469305199989321s: None
5454
```
5555

56+
## Permissions
57+
58+
You can check for `PermissionError` related errors using a built-in command line provided by <MainPlatformName />.
59+
Just log to the main `server` container and run the following:
60+
61+
```shell
62+
docker exec merginmaps-server flask server permissions
63+
```
64+
65+
The command line also accepts a specific path provided by the user (defaults to `/data`):
66+
67+
```shell
68+
docker exec merginmaps-server flask server permissions --path /my/path
69+
```
70+
71+
If you have `PermissionError` related errors, please redo the following steps on your <MainPlatformName /> installation:
72+
73+
<MigrationType type="CE" />
74+
```shell
75+
export MERGIN_DIR=/path/to/your/projects
76+
sudo mkdir -p $MERGIN_DIR
77+
sudo find $MERGIN_DIR -type f -exec sudo chmod 640 {} \;
78+
sudo find $MERGIN_DIR -type d -exec sudo chmod 750 {} \;
79+
sudo find $MERGIN_DIR -type d -exec sudo chmod g+s {} \;
80+
sudo chown -R 901:999 $MERGIN_DIR
81+
```
82+
83+
For <EnterprisePlatformNameLink /> a complementary step needs to be made for the `overviews` mounted folder that enables [Webmaps](https://merginmaps.com/docs/manage/dashboard-maps/) on the platform.
84+
<MigrationType type="EE" />
85+
```shell
86+
export MERGIN_DIR=/path/to/your/overviews
87+
sudo mkdir -p $MERGIN_DIR
88+
sudo find $MERGIN_DIR -type f -exec sudo chmod 640 {} \;
89+
sudo find $MERGIN_DIR -type d -exec sudo chmod 750 {} \;
90+
sudo find $MERGIN_DIR -type d -exec sudo chmod g+s {} \;
91+
sudo chown -R 901:999 $MERGIN_DIR
92+
```
93+
5694
## Celery settings
5795

5896
Celery plays an important role on <MainPlatformName /> hence the need to quickly diagnose its functionality.

0 commit comments

Comments
 (0)