Skip to content

Docker container stuck in restart loop on first-time docker-compose up #454

@Logicnosh

Description

@Logicnosh

Describe the bug

When running docker-compose up for the first time using the default docker-compose.yml, the wallabag container enters a restart loop and never becomes healthy.

To Reproduce

Steps to reproduce the behavior:

  1. Clone the repo
  2. Run docker-compose up -d
  3. Check docker ps and logs: docker-compose logs -f wallabag

Logs Snippet

wallabag_1 | Migrating database...
wallabag_1 | Doctrine\DBAL\Exception\ConnectionException: An exception occurred in driver: SQLSTATE[HY000] [2002] Connection refused
wallabag_1 | Retrying in 5 seconds...

Expected behavior

The container should wait until the mysql container is ready or fail with a clearer error if dependencies aren't available.

Environment

  • OS: Ubuntu 22.04
  • Docker: 24.0.2
  • Docker Compose: 2.18.1
  • Branch: main
  • Wallabag Version: latest

Workaround

Manually restarting the container after 30 seconds works, but not ideal for CI/CD.


Let me know if you want a second one with a different issue (e.g., volume persistence or networking).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions