Skip to content

Commit 7188ffe

Browse files
authored
fix: docker-compose (#104)
The current `docker-compose.yml` fails to start today with an error: > service "atuin" depends on undefined service "postgresql": invalid compose project This patch modernizes the yml and fixes the link. Tested on docker compose v2.39.4.
1 parent b53829e commit 7188ffe

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/content/docs/self-hosting/docker.mdx

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,30 +25,29 @@ Create a `.env` file next to [`docker-compose.yml`](https://github.com/atuinsh/a
2525
```ini
2626
ATUIN_DB_NAME=atuin
2727
ATUIN_DB_USERNAME=atuin
28-
# Choose your own secure password
28+
# Choose your own secure password. Stick to [A-Za-z0-9.~_-]
2929
ATUIN_DB_PASSWORD=really-insecure
3030
```
3131

3232
Create a `docker-compose.yml`:
3333

3434
```yaml
35-
version: '3.5'
3635
services:
3736
atuin:
3837
restart: always
3938
image: ghcr.io/atuinsh/atuin:<LATEST TAGGED RELEASE>
4039
command: server start
4140
volumes:
4241
- "./config:/config"
43-
links:
44-
- postgresql:db
4542
ports:
4643
- 8888:8888
4744
environment:
4845
ATUIN_HOST: "0.0.0.0"
4946
ATUIN_OPEN_REGISTRATION: "true"
50-
ATUIN_DB_URI: postgres://$ATUIN_DB_USERNAME:$ATUIN_DB_PASSWORD@db/$ATUIN_DB_NAME
47+
ATUIN_DB_URI: postgres://${ATUIN_DB_USERNAME}:${ATUIN_DB_PASSWORD}@db/${ATUIN_DB_NAME}
5148
RUST_LOG: info,atuin_server=debug
49+
depends_on:
50+
- db
5251
db:
5352
image: postgres:14
5453
restart: unless-stopped

0 commit comments

Comments
 (0)