Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Docker fresh install failing with Postrgesql DB

Abierto
#482 3 comentarios 0 reacciones 0 asignados Ver en GitHub

@j0k3r ya está trabajando en esto.

Desde el 26/10/2026.

  • #486 de @j0k3r — abierto

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
57/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
docker, php, postgresql, symfony
Área
database, devops

Línea de trabajo

Start by reading the Docker image startup and database configuration scripts, then check how they create or configure the PostgreSQL database and schema for PostgreSQL 16. The logs show migrations fail when creating migration_versions because access to schema public is denied. Done means a fresh PostgreSQL 16 install completes migrations successfully; the issue does not name specific files or tests.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Environment
  • Version: 2.6.14
  • Installation: docker
  • PHP version: 8.1
  • OS: docker image
  • Database: Postgresql 16
  • Configuration:
Relevant environment variables

Passwords and domain are fake

POSTGRES_PASSWORD=myPostgresPassword 
SYMFONY__ENV__DATABASE_PASSWORD=myDBPassword
SYMFONY__ENV__SECRET=mySecret
SYMFONY__ENV__MAILER_HOST=mail.domain.com
[email protected]
[email protected]
SYMFONY__ENV__MAILER_PASSWORD=myMailPassword

docker-compose.yml
---
networks:
  web:
    external: true
services:
  wallabag:
    image: wallabag/wallabag:latest
    restart: unless-stopped
    environment:
    - SYMFONY__ENV__DATABASE_DRIVER=pdo_pgsql
    - SYMFONY__ENV__DATABASE_DRIVER_CLASS=Wallabag\CoreBundle\Doctrine\DBAL\Driver\CustomPostgreSQLDriver
    - SYMFONY__ENV__DATABASE_HOST=db
    - SYMFONY__ENV__DATABASE_PORT=5432
    - SYMFONY__ENV__DATABASE_NAME=wallabag
    - SYMFONY__ENV__DATABASE_USER=wallabag
    - SYMFONY__ENV__FOSUSER_REGISTRATION=false
    - SYMFONY__ENV__LOCALE=fr
    - SYMFONY__ENV__DOMAIN_NAME=https://bag.domain.com
    - POSTGRES_USER=postgres
    env_file:
    - ".env"
    volumes:
    - "/srv/domain.com/bag/images:/var/www/wallabag/web/assets/images"
    - "/srv/domain.com/bag//data:/var/www/wallabag/data"
    labels:
      traefik.enable: 'true'
      traefik.http.routers.bag.rule: Host(`bag.domain.com`)
      traefik.http.middlewares.bag-headers.headers.frameDeny: 'true'
      traefik.http.routers.bag.middlewares: bag-headers@docker
    networks:
    - default
    - web
  db:
    image: postgres:16-alpine
    restart: unless-stopped
    environment:
    - POSTGRES_DB=workaround
    - POSTGRES_USER=postgres
    env_file:
    - ".env"
    volumes:
    - "/srv/domain.com/bag/db:/var/lib/postgresql/data"
    networks:
    - default
  redis:
    image: redis:alpine
    restart: unless-stopped

### What steps will reproduce the bug?
  • Launch wallabag with docker compose up -d
  • You get the following error in the logs
wallabag-1  | Starting wallabag ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Waiting for database ...
wallabag-1  | Configuring the Postgres database ...
wallabag-1  | 
wallabag-1  | wallabag installer
wallabag-1  | ==================
wallabag-1  | 
wallabag-1  | Step 1 of 4: Checking system requirements.
wallabag-1  | ------------------------------------------
wallabag-1  | 
wallabag-1  |  ------------------------ -------- ---------------- 
wallabag-1  |   Checked                  Status   Recommendation  
wallabag-1  |  ------------------------ -------- ---------------- 
wallabag-1  |   PDO Driver (pdo_pgsql)   OK!                      
wallabag-1  |   Database connection      OK!                      
wallabag-1  |   Database version         OK!                      
wallabag-1  |   curl_exec                OK!                      
wallabag-1  |   curl_multi_init          OK!                      
wallabag-1  |  ------------------------ -------- ---------------- 
wallabag-1  | 
wallabag-1  |  [OK] Success! Your system can run wallabag properly.                           
wallabag-1  | 
wallabag-1  | Step 2 of 4: Setting up database.
wallabag-1  | ---------------------------------
wallabag-1  | 
wallabag-1  |  Creating schema...
wallabag-1  | 
wallabag-1  | In InstallCommand.php line 364:
wallabag-1  |                                                                                
wallabag-1  |   The command "doctrine:migrations:migrate" generates some errors:             
wallabag-1  |                                                                                
wallabag-1  |   14:55:08 CRITICAL  [console] Error thrown while running command "doctrine:m  
wallabag-1  |   igrations:migrate --no-interaction=1 --no-debug=1 --env=prod". Message: "An  
wallabag-1  |    exception occurred while executing a query: SQLSTATE[42501]: Insufficient   
wallabag-1  |   privilege: 7 ERROR:  permission denied for schema public                     
wallabag-1  |   LINE 1: CREATE TABLE migration_versions (version VARCHAR(192) NOT NU...      
wallabag-1  |                        ^" ["exception" => Doctrine\DBAL\Exception\DriverExcep  
wallabag-1  |   tion { …},"command" => "doctrine:migrations:migrate --no-interaction=1 --no  
wallabag-1  |   -debug=1 --env=prod","message" => """  An exception occurred while executin  
wallabag-1  |   g a query: SQLSTATE[42501]: Insufficient privilege: 7 ERROR:  permission de  
wallabag-1  |   nied for schema public\n  LINE 1: CREATE TABLE migration_versions (version   
wallabag-1  |   VARCHAR(192) NOT NU...\n                       ^  """]                       
wallabag-1  |                                                                                
wallabag-1  |   In ExceptionConverter.php line 87:                                           
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |     An exception occurred while executing a query: SQLSTATE[42501]: Insuffici  
wallabag-1  |   en                                                                           
wallabag-1  |     t privilege: 7 ERROR:  permission denied for schema public                 
wallabag-1  |                                                                                
wallabag-1  |     LINE 1: CREATE TABLE migration_versions (version VARCHAR(192) NOT NU...    
wallabag-1  |                                                                                
wallabag-1  |                          ^                                                     
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |   In Exception.php line 24:                                                    
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |     SQLSTATE[42501]: Insufficient privilege: 7 ERROR:  permission denied for   
wallabag-1  |   sc                                                                           
wallabag-1  |     hema public                                                                
wallabag-1  |                                                                                
wallabag-1  |     LINE 1: CREATE TABLE migration_versions (version VARCHAR(192) NOT NU...    
wallabag-1  |                                                                                
wallabag-1  |                          ^                                                     
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |   In Connection.php line 33:                                                   
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |     SQLSTATE[42501]: Insufficient privilege: 7 ERROR:  permission denied for   
wallabag-1  |   sc                                                                           
wallabag-1  |     hema public                                                                
wallabag-1  |                                                                                
wallabag-1  |     LINE 1: CREATE TABLE migration_versions (version VARCHAR(192) NOT NU...    
wallabag-1  |                                                                                
wallabag-1  |                          ^                                                     
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |                                                                                
wallabag-1  |   doctrine:migrations:migrate [--write-sql [WRITE-SQL]] [--dry-run] [--query-  
wallabag-1  |   time] [--allow-no-migration] [--all-or-nothing [ALL-OR-NOTHING]] [--configu  
wallabag-1  |   ration CONFIGURATION] [--em EM] [--conn CONN] [-h|--help] [-q|--quiet] [-v|  
wallabag-1  |   vv|vvv|--verbose] [-V|--version] [--ansi] [--no-ansi] [-n|--no-interaction]  
wallabag-1  |    [-e|--env ENV] [--no-debug] [--] <command> [<version>]                      
wallabag-1  |                                                                                
wallabag-1  | 
wallabag-1  | doctrine:migrations:migrate [--write-sql [WRITE-SQL]] [--dry-run] [--query-time] [--allow-no-migration] [--all-or-nothing [ALL-OR-NOTHING]] [--configuration CONFIGURATION] [--em EM] [--conn CONN] [-h|--help] [-q|--quiet] [-v|vv|vvv|--verbose] [-V|--version] [--ansi] [--no-ansi] [-n|--no-interaction] [-e|--env ENV] [--no-debug] [--] <command> [<version>]

After some search on internet, my guess is that this is linked to the new behavior starting with Postgresql 15 as explained in the Stackoverflow answer

My knowledge is not sufficient to be able to fix it. Any hint would be welcome to try and test a workaround.

Additional info:

  • running docker compose exec wallabag /var/www/wallabag/bin/console doctrine:migrations:migrate --env=prod --no-interaction raises the same error
Lenguaje dominante
Shell
Estrellas
775
Forks
171
Merge medio
38 min
PR fusionados (30 d)
1

Preparar el entorno

  • Incluye un Dockerfile o un archivo de Docker Compose
  • Sin plantilla de pull request
  • Sin guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de wallabag/docker

Todos los issues de wallabag/docker

Issues similares

Más issues de Shell/Bash

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.