Commit 8d4499a
committed
fix(satellite): resolve Docker volume permission issues preventing credential persistence
Fixes #547
Problem:
- Satellite container failed to persist credentials due to volume permission mismatch
- Docker created volumes with root:root ownership by default
- Satellite runs as deploystack user (uid=1001, gid=1001) and couldn't write
- Registration succeeded but credentials not saved (silent failure)
- Container entered restart loop on subsequent starts
Solution:
1. Dockerfile: Create /app/persistent_data directory with correct ownership before USER switch
2. Backend Client: Add ensureDirectoryExists() method with fail-fast permission checks
3. Server: Call directory initialization during startup to catch permission issues early
4. Error Handling: Enhanced savePersistedData() with detailed permission error messages
5. Documentation: Updated docker run commands to include --user 1001:1001 flag
Impact:
- Fresh deployments now work automatically
- Existing broken volumes fail fast with clear error messages and fix commands
- Satellite credentials persist correctly across container restarts
- No more silent failures
Files Modified:
- services/satellite/Dockerfile
- services/satellite/src/services/backend-client.ts
- services/satellite/src/server.ts
- documentation/self-hosted/docker-compose.mdx
- documentation/self-hosted/quick-start.mdx1 parent d7e92db commit 8d4499a
File tree
3 files changed
+111
-6
lines changed- services/satellite
- src
- services
3 files changed
+111
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
20 | 26 | | |
21 | 27 | | |
22 | 28 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
212 | 212 | | |
213 | 213 | | |
214 | 214 | | |
215 | | - | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
216 | 228 | | |
217 | 229 | | |
218 | 230 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
105 | 105 | | |
106 | 106 | | |
107 | 107 | | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
108 | 169 | | |
109 | 170 | | |
110 | 171 | | |
| |||
500 | 561 | | |
501 | 562 | | |
502 | 563 | | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
503 | 567 | | |
504 | 568 | | |
505 | | - | |
| 569 | + | |
506 | 570 | | |
507 | 571 | | |
508 | 572 | | |
509 | 573 | | |
510 | 574 | | |
511 | | - | |
512 | | - | |
| 575 | + | |
| 576 | + | |
513 | 577 | | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
| 589 | + | |
| 590 | + | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
| 597 | + | |
| 598 | + | |
514 | 599 | | |
515 | 600 | | |
516 | 601 | | |
517 | | - | |
| 602 | + | |
| 603 | + | |
518 | 604 | | |
| 605 | + | |
519 | 606 | | |
520 | 607 | | |
521 | 608 | | |
| |||
0 commit comments