Kizaing / LotGDocker

Legend of the Green Dragon, Now dockerized!
16 stars 6 forks source link

Docker Error when browsing to localhost:4040 #4

Open DemiosVayl opened 11 months ago

DemiosVayl commented 11 months ago

I was able to connect to the database server, but couldn't connect to the specified database. Sorry it didn't work out.

This is following step 6 of the github instrutions.

Docker shows all are running image

Thank you (and sorry for resurrecting the dead)

kmasaryk commented 11 months ago

Got the same error. After taking a quick look at the lotgd-db container I noticed that it's not actually installing the lotgd db at all. Worse, the sql dump was taken from MariaDB 10.3 but the container is running MySQL 5.6 which isn't compatible with the dump.

Easy enough to fix:

  1. Create a new dir named sql: $ mkdir sql
  2. Copy the lotgd.sql file from the logd dir to sql/: $ cp logd/lotgd.sql sql/
  3. Update docker-compose.yaml to include the appropriate MariaDB image and also mount the new sql dir so that it automatically processes the dump file and builds the db:
  lotgd-db:
    image: mariadb:10.3
    environment:
      - MYSQL_ROOT_PASSWORD=lotgd
    volumes:
      - ./sql:/docker-entrypoint-initdb.d