Install/Set App locations to a subdirectory
-
-
For Cloudron, we had looked into this when we started many years ago. It's unlikely to support subdirectory based installations. This causes various problems because cookies, local storage, indexdb etc as they are stored on the domain level and one has to be careful to not leak stuff across apps. This might work if you are in total control of the apps and limiting yourself to specific apps, but in a general level path based installations are not a good idea (for Cloudron). Maybe we have to look into new content protection for apps and things have changed now.
-
@girish WordPress is designed to be installed in a subdirectory as an option, so no issue there. I'd be surprised if forum software hadn't also considered this as an option.
Given the apps would remain in their respective separate containers, I can't see what issue there would be for leaking anything.
Each app could still be on it's own subdomain, but the mod_proxy rule would be translating that for the public navigation and search engine indexing.
From a business point of view for SEO, you're diluting the effectiveness of marketing efforts for every public subdomain, so the business decisions is made based on the decider knowing or caring about that extra cost in time and money, or missed opportunity from not understanding how search engine rankings work.
Successes with subdomains might still happen despite these headwinds, but could have had tailwinds had they just chosen the path more valued by ranking algos.
-
@marcusquinn the leak happens on the browser side and not the backend side. For example, a plugin in /blog1 can now read the contents/cookies/session/localstorage of /blog2 . If a bad plugin is installed in blog1, then it compromises blog2 .
But yeah, I agree that WP might benefit here. It's not a trivial feature to implement though.
-
@girish That's just all websites, if you have a compromised plugin, you have a compromised plugin, but in this case, that would only be some small footprint access to front-end data, not the separated app admins.
They aren't exactly separate websites if running on the same domain, though, just using multiple instances of admin software to create different parts of the website.
I assume this can still be done manually by adding the above to the .htacccess file on one app to then alias a subdirectory to the subdomain URL of another app, since they are both on public URLs?
-
@marcusquinn said in Install/Set App locations to a subdirectory:
I assume this can still be done manually by adding the above to the .htacccess file on one app to then alias a subdirectory to the subdomain URL of another app, since they are both on public URLs?
yes, correct, this should work.
-
Hang on, I thought there was an option somewhere in cloudron where you could toggle the location of the installation. For example, you could, as I think OP wants, opt between:
blog.example.com
vs
example.com.blog
example.com/blog -
@LoudLemur I think @marcusquinn wants
example.com/blog
. But no, there is no option to choose a subpath implementation. This has not been implemented yet at Cloudron level. -
@girish said in Install/Set App locations to a subdirectory:
Woops! yes, that is what I meant to write. Thanks!