-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Relative DB URLs #1319
Relative DB URLs #1319
Conversation
Deployed to https://test-deployment-pr-1319.herokuapp.com/ |
For me, one of the main objectives of removing the config.json is to have a multi-tenant system (one hosted app for all projects). Do we have an idea yet how to route to different DBs in the long run? And if we remove the url, we not also move the name to the config document in couchdb and immediately delete the whole json file? |
Regarding the multi tenant system: Regarding the full deletion of the |
# Conflicts: # src/app/core/webdav/cloud-file-service.service.spec.ts
# Conflicts: # build/Dockerfile # build/default.conf # src/app/app.module.ts # src/app/core/config/config-fix.ts # src/app/core/ui/ui-config.ts # src/main.ts
# Conflicts: # build/default.conf # src/app/core/language/language-select/language-select.component.html # src/app/core/translation/language-selector/language-select.component.ts
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wow, I really like how this cleans up some long standing loose ends 😃
Just a bunch of clean code ideas in my comments but this looks pretty good overall.
Functionally I noticed one thing:
When I switch to "local" session and then do a hard reload (Ctrl+F5) the app gets the queryParam "session=mock" in the URL and switches back to "mock" session. Looking at the code I see that queryParam takes precedence over localStorage by design.
My intuitive expectation was that I will remain in the previous (-> local) mode. What should we have as the expected behaviour here?
} | ||
if ($demo = "truetrue") { | ||
# This first part is required because Heroku does some internal redirects which break the rewrite otherwise | ||
# This does not work in localhost as it enforces HTTPS |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we have to rewrite to https here or could we just leave it at whatever was used before?
It would make more sense to have a separate block that rewrites any mode to use https (easier to understand if separated - and applying to all modes). But I don't know whether that's doable in nginx, e.g. multiple rewrite blocks applying.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Normally it definitely works the way you are asking for the problem is that it does not work with Heroku. Somehow in there a internal redirect is happening before this one which leads to a wrong URL in this rewrite (in particular loosing the https
and adding a wrong port). This workaround is not needed for our own servers. There we could just use:
rewrite ^ $uri?demo=true&session=mock permanent;
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks awesome! 😍
🎉 This PR is included in version 3.9.0-master.1 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
🎉 This PR is included in version 3.9.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
solves #841
On default the app will now be in demo_mode with a in-memory DB. Do change this
DEMO="false"
needs to be passed to the Docker image on start.Visible/Frontend Changes
--
Architectural/Backend Changes
database_url
in theconfig.json
file unnecessarydatabase_name
with defaultapp