feat: read only mode
- Added env variable to specify to run Mongoku in read only mode or not
- Read only is handled by a middleware that will return 401 on update / insert / delete routes
- bumped most dependencies' versions and fixed breaking changes
Notes :
- I think Dark mode is kind of broken (buttons don't change to white and hover doesn't go to white either)
- There could be a better a way to make UI clearer when mongoku is running in read only mode, editing is quite unclear (but doesn't work as intended)
wasn't it better to just implement read-only and not upgrade dependencies? (to limit breaking changes and small UI regressions)
Well I couldn't start Mongoku even with the Docker image (tried pinning node base img version to 12, 14 & 16). So I thought it may be good thing to upgrade everything since it's been 2 years and many things are deprecated.
I could've done a first PR with the bump and then started working on the read only mode after. I wanted to move fast, sry about that.
I pushed a little update in the readme to document the new flag, I hope it's ok :)
Thanks @Pierrci !
Can we merge this? If we want to work on other issues, it's good to have deps updated :)
@n1t0 ok for you?