Commit 78ca8a4
committed
backend/docker-compose: add pg dependency, optional persistence
This change adds a dependency to the (nebraska) "server" service on the
"postgres" service in docker-compose.test.yaml.
Motivation of the change is to prevent a race condition where the
"server" container starts faster than "postgres", fails to connect to
the database, and shuts down.
Additionally, an optional persistent storage for postgres is added.
DB contents can be persisted across docker-compose runs to aid manual,
interactive testing. Usage instructions have been added to the YAML
files as comments. The local directory used for persiting postgres data
has been added to .gitignore to prevent accidental commits.
Signed-off-by: Thilo Fromm <[email protected]>1 parent 0fc8c4b commit 78ca8a4
File tree
3 files changed
+28
-3
lines changed- backend
3 files changed
+28
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
1 | 13 | | |
2 | 14 | | |
3 | 15 | | |
| |||
21 | 33 | | |
22 | 34 | | |
23 | 35 | | |
24 | | - | |
25 | | - | |
| 36 | + | |
| 37 | + | |
26 | 38 | | |
27 | | - | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
28 | 42 | | |
| 43 | + | |
| 44 | + | |
29 | 45 | | |
30 | 46 | | |
31 | 47 | | |
0 commit comments