Can anyone share their bookstack docker-compose app with me?

I am trying to host it and the sample docker-compose file herehttps://github.com/linuxserver/docker-bookstack/pkgs/container/bookstack#usage

does not work for me. Getting error when db migration is applied.

https://preview.redd.it/dtt6t2cf7fvb1.png?width=1279&format=png&auto=webp&s=3cad128718963d29032ee796f33057cc52b76f74

I am testing this on my windows machine locally but intend to host in a linux machine.

docker-compose file. https://pastebin.com/AVLrG4Ea

  • Protoype@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    Might sound silly, but instead of doing https://localhost:6875, try 127.0.0.1:6875 or you internal network ip (for testing until you get a domain) e.g. 192.168.0.1as might be a name resolving thing.

    Also have you got TLS/HTTPS setup?

    • shahisunil@alien.topOPB
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      I did try 127.0.0.1 i was able to reach the login page but got some error as well. So i doubt thats the problem. The screenshot i have above shows that there is issue with database migration. I think thats the problem.

  • selfguest@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    Have you tried debugging the issue by running the MySQL container alone (i.e. comment out the “bookstack:” section of the docker-compose file)?

    Does the container start and run? Are you able to connect to port 3306 of the container from the host, using whatever userid and password you specified?

    • shahisunil@alien.topOPB
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      I tried this. I was able to connect to the db. I was able to resolve this now after reading comment from u/ssddanbrown.

    • revereddesecration@alien.topB
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      Fun fact: don’t comment out anything, just find the name of the database service, let’s say it’s db, then run docker compose up db to launch it on its own.

    • shahisunil@alien.topOPB
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      Yes I tried that. Access to the url was not the issue though.

      Anyway thanks for the comment. I was able to resolve the issue with help from u/ssddanbrown

  • ssddanbrown@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    This is common on windows. Something funk goes on at the filesystem level in this configuration which causes issues with migrations. There’s a relevant thread here. Some folks in there have solved it via alternative volume options, or alternative database docker images. Should not be something you experience on Linux though.

    • shahisunil@alien.topOPB
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      Oh my god. I wasted hours for nothing. This was indeed the issue. I ran it docker volume it worked fine in windows. Then tried in Ubuntu server by mapping to host directory and it is running now.

      Thank you very much.

      • ssddanbrown@alien.topB
        link
        fedilink
        English
        arrow-up
        1
        ·
        1 year ago

        Happy to help! Just as an extra warning, don’t auto-upgrade BookStack containers via something like watchtower. Most of the annoying issues I’ve had reported from docker users of BookStack seems to be due to auto-upgrade failing, which can often be hard to track down since errors may not show right away, or the user many not realise an update was attempted.

        • shahisunil@alien.topOPB
          link
          fedilink
          English
          arrow-up
          1
          ·
          1 year ago

          Thanks will keep that in mind. Also thanks for all your work on this. Really looking forward to use this.

  • gleepwurp1974@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    Yeah, looks like your bookstack app is unable to connect to its database container.

    Have you tried letting run a bit? Sometimes the bookstack container will try to connect to the DB container before it has had sufficient time to initialize properly… It the config is set up properly, it should eventually connect to it.

    Like another user mentioned, sometimes “localhost” definition is missing in Windows, so try using the local loopback IP (127.0.0.1) instead of “localhost”, to take out DNS/Naming issues from the equation. (APP_URL env variable)

    Aside from those points I mentionned, my docker-compose matches yours (no APP_KEY though env variable though).

    Good luck!