linuxserver / docker-bookstack

A Docker container for the BookStack documentation wiki
GNU General Public License v3.0
747 stars 108 forks source link

MFA not working due to Time sync not being included in template #143

Closed cj2tech closed 1 year ago

cj2tech commented 1 year ago

linuxserver.io

When you first set up the docker template it will work fine except the time will be off due to the application container not having correct time. Some things are broken because of this like MFA.

Expected Behavior

MFA to function normally and time be synced in the container

Current Behavior

Due to the current templet there is no way for the application to get the correct time

Steps to Reproduce

  1. Set up docker-compose
  2. login
  3. goto edit profile
  4. tried to enable and setup TOTP MFA

Environment

OS: Linux CPU architecture: x86_64 How docker service was installed: used docker compose template from https://hub.docker.com/r/linuxserver/bookstack. Setup as a stack in Portainer

Command used to create docker container (run/create/compose/screenshot)

Compse ## Docker logs

n/a -

github-actions[bot] commented 1 year ago

Thanks for opening your first issue here! Be sure to follow the bug or feature issue templates!

cj2tech commented 1 year ago

since the container wasn't configured correctly and the template is missing a TZ for the base application. I was able to add -v /etc/localtime:/etc/localtime:ro so the container used my systems time rather than relying on the container. It looks like you guys have a -e TZ set for the database but not the main app. IDK if that would also resolve the issue or not. But really there shouldn't be any issue adding the time based off the system either.

This issue is resolved I just wanted to note it down and make other people aware and provide them a fix

github-actions[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

drizuid commented 1 year ago

thanks for opening this issue, it looks like we somehow missed putting our normal TZ recommendation in the compose sample. We will get the readme addressed asap.

as a side note, for future reference, Command used to create docker container (run/create/compose/screenshot) the answer to this for you is portainer, not compose. when we say compose, we mean docker compose, when portainer says compose, they mean portainershitshow.