testcontainers / testcontainers-node

Testcontainers is a NodeJS library that supports tests, providing lightweight, throwaway instances of common databases, Selenium web browsers, or anything else that can run in a Docker container.
https://testcontainers.com
MIT License
1.94k stars 195 forks source link

Neo4j version 5+ requires a longer password #831

Closed EcksDy closed 2 months ago

EcksDy commented 2 months ago

Expected Behaviour When running a newer image(tag 5.23.0 in my case), the container should start with default settings.

Actual Behaviour

console.error
    Error: Log stream ended and message "Started." was not received
        at LineStream.<anonymous> (.../node_modules/testcontainers/src/wait-strategies/log-wait-strategy.ts:54:18)
        at LineStream.emit (node:events:517:28)
        at LineStream.emit (node:domain:489:12)
        at endReadableNT (node:internal/streams/readable:1368:12)
        at processTicksAndRejections (node:internal/process/task_queues:82:21)

Testcontainer Logs

  testcontainers [DEBUG] [f7d22df3c0d5] Waiting for log message "Started."... +0ms
  testcontainers [DEBUG] [f7d22df3c0d5] Fetching container logs... +1ms
  testcontainers [DEBUG] [f7d22df3c0d5] Demuxing stream... +2ms
  testcontainers [DEBUG] [f7d22df3c0d5] Demuxed stream +0ms
  testcontainers [DEBUG] [f7d22df3c0d5] Fetched container logs +0ms
  testcontainers:containers [f7d22df3c0d5] Invalid value for password. The minimum password length is 8 characters. +792ms
  testcontainers:containers [f7d22df3c0d5] If Neo4j fails to start, you can: +0ms
  testcontainers:containers [f7d22df3c0d5] 1) Use a stronger password. +0ms
  testcontainers:containers [f7d22df3c0d5] 2) Set configuration dbms.security.auth_minimum_password_length to override the minimum password length requirement. +0ms
  testcontainers:containers [f7d22df3c0d5] 3) Set environment variable NEO4J_dbms_security_auth__minimum__password__length to override the minimum password length requirement. +0ms
  testcontainers:containers [f7d22df3c0d5] org.neo4j.commandline.admin.security.exception.InvalidPasswordException: A password must be at least 8 characters. +1s
  testcontainers [ERROR] [f7d22df3c0d5] Log stream ended and message "Started." was not received +2s

Environment Information

Will open the PR to fix the default password.