docker exec -it db psql
\l #zeigt alle Datenbanken an, da müsstest du paperless sehen
\du+ #das zeigt alle vorhanden User an.
\c paperless # wechselt zur DB mit dem namen paperless
select * from auth_user; # Fragt die User bei Paperless ab. Da mit könntest du gucken, ob überhaupt Daten in der DB drin sind.
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
ALTER TABLE
SET
SET
SET
SET
SET
set_config
------------
(1 row)
SET
SET
SET
SET
DROP DATABASE
CREATE DATABASE
ALTER DATABASE
You are now connected to database "postgres" as user "paperless".
SET
SET
SET
SET
SET
set_config
------------
(1 row)
SET
SET
SET
SET
COMMENT
paperless@paperless:~$ docker exec -it db psql
psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL: role "root" does not exist
paperless@paperless:~$
Dann Ergänze es mitBei Deinem Befehl bekomme ich folgende Meldung
-U paperless
Database postgres, aber nicht paperless. Oder kam das irgendwo vorher?You are now connected to database "postgres" as user "paperless".
paperless@paperless:~$ docker exec -it db psql -U paperless
psql (16.1 (Debian 16.1-1.pgdg120+1))
Type "help" for help.
paperless=# \l
List of databases
Name | Owner | Encoding | Locale Provider | Collate | Ctype | ICU Locale | ICU Rules | Access privileges
-----------+-----------+----------+-----------------+------------+------------+------------+-----------+-------------------------
paperless | paperless | UTF8 | libc | en_US.utf8 | en_US.utf8 | | |
postgres | paperless | UTF8 | libc | en_US.utf8 | en_US.utf8 | | |
template0 | paperless | UTF8 | libc | en_US.utf8 | en_US.utf8 | | | =c/paperless +
| | | | | | | | paperless=CTc/paperless
template1 | paperless | UTF8 | libc | en_US.utf8 | en_US.utf8 | | | paperless=CTc/paperless+
| | | | | | | | =c/paperless
(4 rows)
paperless=# \du+
List of roles
Role name | Attributes | Description
-----------+------------------------------------------------------------+-------------
paperless | Superuser, Create role, Create DB, Replication, Bypass RLS |
paperless=# \c paperless
You are now connected to database "paperless" as user "paperless".
paperless=# select * from auth_user
paperless-#
paperless@paperless:~$ docker compose down
[+] Running 6/6
✔ Container webserver Removed 0.0s
✔ Container broker Removed 0.4s
✔ Container tika Removed 0.4s
✔ Container gotenberg Removed 10.3s
✔ Container db Removed 0.5s
✔ Network paperless_default Removed 0.3s
paperless@paperless:~$ docker compose pull
[+] Pulling 5/5
✔ broker Pulled 1.2s
✔ webserver Pulled 0.5s
✔ gotenberg Pulled 1.1s
✔ db Pulled 1.4s
✔ tika Pulled 0.5s
paperless@paperless:~$ docker compose up -d
[+] Running 6/6
✔ Network paperless_default Created 0.1s
✔ Container tika Started 0.2s
✔ Container gotenberg Started 0.1s
✔ Container db Started 0.1s
✔ Container broker Started 0.1s
✔ Container webserver Started 0.0s
paperless@paperless:~$
PostgreSQL Database directory appears to contain a database; Skipping initialization
2023-12-01 12:47:30.759 UTC [1] LOG: starting PostgreSQL 16.1 (Debian 16.1-1.pgdg120+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 12.2.0-14) 12.2.0, 64-bit
2023-12-01 12:47:30.759 UTC [1] LOG: listening on IPv4 address "0.0.0.0", port 5432
2023-12-01 12:47:30.759 UTC [1] LOG: listening on IPv6 address "::", port 5432
2023-12-01 12:47:30.766 UTC [1] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
2023-12-01 12:47:30.779 UTC [28] LOG: database system was shut down at 2023-12-01 12:47:02 UTC
2023-12-01 12:47:30.788 UTC [1] LOG: database system is ready to accept connections
2023-12-01 12:47:40.935 UTC [33] FATAL: password authentication failed for user "paperless"
2023-12-01 12:47:40.935 UTC [33] DETAIL: User "paperless" does not have a valid SCRAM secret.
Connection matched file "/var/lib/postgresql/data/pg_hba.conf" line 128: "host all all all scram-sha-256"
2023-12-01 12:47:42.445 UTC [35] FATAL: password authentication failed for user "paperless"
2023-12-01 12:47:42.445 UTC [35] DETAIL: User "paperless" does not have a valid SCRAM secret.
Connection matched file "/var/lib/postgresql/data/pg_hba.conf" line 128: "host all all all scram-sha-256"
2023-12-01 12:47:43.854 UTC [37] FATAL: password authentication failed for user "paperless"
2023-12-01 12:47:43.854 UTC [37] DETAIL: User "paperless" does not have a valid SCRAM secret.
Connection matched file "/var/lib/postgresql/data/pg_hba.conf" line 128: "host all all all scram-sha-256"
2023-12-01 12:47:45.498 UTC [39] FATAL: password authentication failed for user "paperless"
2023-12-01 12:47:45.498 UTC [39] DETAIL: User "paperless" does not have a valid SCRAM secret.
Connection matched file "/var/lib/postgresql/data/pg_hba.conf" line 128: "host all all all scram-sha-256"
2023-12-01 12:47:47.527 UTC [41] FATAL: password authentication failed for user "paperless"
2023-12-01 12:47:47.527 UTC [41] DETAIL: User "paperless" does not have a valid SCRAM secret.
Connection matched file "/var/lib/postgresql/data/pg_hba.conf" line 128: "host all all all scram-sha-256"
2023-12-01 12:47:50.317 UTC [43] FATAL: password authentication failed for user "paperless"
2023-12-01 12:47:50.317 UTC [43] DETAIL: User "paperless" does not have a valid SCRAM secret.
Connection matched file "/var/lib/postgresql/data/pg_hba.conf" line 128: "host all all all scram-sha-256"
2023-12-01 12:47:54.696 UTC [46] FATAL: password authentication failed for user "paperless"
2023-12-01 12:47:54.696 UTC [46] DETAIL: User "paperless" does not have a valid SCRAM secret.
Connection matched file "/var/lib/postgresql/data/pg_hba.conf" line 128: "host all all all scram-sha-256"
2023-12-01 12:48:02.252 UTC [48] FATAL: password authentication failed for user "paperless"
2023-12-01 12:48:02.252 UTC [48] DETAIL: User "paperless" does not have a valid SCRAM secret.
Connection matched file "/var/lib/postgresql/data/pg_hba.conf" line 128: "host all all all scram-sha-256"
2023-12-01 12:58:10.611 UTC [1] LOG: database system is ready to accept connections
docker exec -it db psql -U paperless
\password
# 2x das Passwort eingeben
\q
version: "3.4"
services:
broker:
image: docker.io/library/redis:7
container_name: broker
restart: unless-stopped
volumes:
- /data/paperless/redis/_data:/data
db:
image: docker.io/library/postgres:16
container_name: db
restart: unless-stopped
volumes:
- /data/paperless/postgresql/_data:/var/lib/postgresql/data
environment:
POSTGRES_DB: paperless
POSTGRES_USER: paperless
POSTGRES_PASSWORD: paperless
webserver:
image: ghcr.io/paperless-ngx/paperless-ngx:latest
container_name: webserver
restart: unless-stopped
depends_on:
- db
- broker
- gotenberg
- tika
ports:
- 8001:8000
healthcheck:
test: ["CMD", "curl", "-fs", "-S", "--max-time", "2", "http://localhost:8000"]
interval: 30s
timeout: 10s
retries: 5
volumes:
- /data/paperless/consume:/usr/src/paperless/consume
- /data/paperless/data:/usr/src/paperless/data
- /data/paperless/media:/usr/src/paperless/media
- /data/paperless/export:/usr/src/paperless/export
environment:
PAPERLESS_ADMIN_USER: paperless
PAPERLESS_ADMIN_PASSWORD: paperless
PAPERLESS_REDIS: redis://broker:6379
PAPERLESS_DBHOST: db
PAPERLESS_TIKA_ENABLED: true
PAPERLESS_TIKA_GOTENBERG_ENDPOINT: http://gotenberg:3000
PAPERLESS_TIKA_ENDPOINT: http://tika:9998
PAPERLESS_OCR_LANGUAGE: deu
PAPERLESS_TIME_ZONE: Europe/Berlin
USERMAP_UID: 1001
USERMAP_GID: 1001
gotenberg:
image: docker.io/gotenberg/gotenberg:latest
container_name: gotenberg
restart: unless-stopped
healthcheck:
test: ["CMD", "curl", "-fs", "-S", "--max-time", "2", "http://localhost:8000"]
interval: 30s
timeout: 10s
retries: 5
Wenn du das Forum hilfreich findest oder uns unterstützen möchtest, dann gib uns doch einfach einen Kaffee aus.
Als Dankeschön schalten wir deinen Account werbefrei.