If you're interested please comment here and come join our "Contributors" community channel on our daily build server, where you can discuss questions with community members and the Mattermost core team. For technical advice or questions, please join our "Developers" community channel.
New contributors please see our Developer's Guide, specifically for machine setup and for developer workflow.
Notes: Jira ticket
Related to https://github.com/mattermost/platform/issues/643
Also request from @botherder: https://twitter.com/botherder/status/655394442313138176
Voting: https://mattermost.uservoice.com/forums/306457-general/suggestions/12468372-install-mattermost-in-a-subdirectory
Forum issue: https://forum.mattermost.org/t/how-do-i-set-the-base-url-for-apache-ssl-forwarding/573
To achieve this change, the client should reference the Site URL config.json setting instead of a relative link, when one is available. If no site URL is set, then return a slash or a blank value.
Notes:
1) For someone to host Mattermost in a subdirectory, it is assumed that Site URL is required to be set.
2) This change should not break existing deployments, including those who don't have Site URL set.
3) Preliminary work from [~akihikodaki] in 2016 can be found here: https://github.com/mattermost/mattermost-server/compare/master...akihikodaki:PLT-200
I can probably take this. I'll take a look later see if it looks like something I can tackle.
Awesome!! 馃憤
A discussion related to the ticket spurred up in the last 30 minutes, so it might be worth reviewing that before starting on this: https://pre-release.mattermost.com/core/pl/ry91wiu7r7rs8qwdkh68bstqty
@jasonblais I'll definitely take this.
This is a massive change that will touch a lot of things. If anyone wants to see the progress: https://github.com/moonmeister/platform/tree/PLT-200
I want to take a second to confirm the scope of this ticket and what I'm targeting given the discussion @jasonblais mentioned above.
platform
executable will continue bind to the port and address configured in ServiceSettings.ListenAddress
. We want to support reverse proxies that host MM in a subdirectory.
For things that require a static url reference (see below), siteURL
must be set (for now, this could be fixed in another PR as it's out of scope here).
siteURL
being set should not keep a user from accessing it from a different domain.siteURL
will effectively always contains a path, whether that path is /
or /chat
. Whatever the path is set to must be consistent across all domains.siteURL
; inasmuch as, it should not require siteURL
to be set when this feature is not in use. Given all old configs will not have this feature in use, it will not break their configurations. Thoughts? Anything I missed @hmhealey or @jwilander ?
Sounds about right to me
As an aside this is theoretically already possible using a finely tuned Reverse Proxy for any one who doesn't want to wait. See here
I'm struggling on this one in a addition to not having a ton of time. My understanding of JS and React is limiting. I think I have most of the Go/Server side done and some of the webapp side done. If anyone wants to/can help let me know.
@moonmeister Are there particular areas you're looking for help?
I have added some data parsing for the url and binding port/address on the go side but I need this data available in react. @hmhealey recommended using a redux store but I have 0 understanding of redux and limited React experience. So, I probably most need help in making that data available so that when building urls in JS/React I have the path data available. Thanks.
@moonmeister Would you be interested working on the Redux store? If so, I can ping a developer to help give you some direction.
If you'd prefer someone else to continue, an option would be to submit PRs with WIP
in the title so others know it is a work-in-progress, and I can take a look if someone in the community was interested continuing from them.
Yeah, I'm happy to try.
That's great! @moonmeister posted a question here: https://pre-release.mattermost.com/core/pl/yjd78b6jibbdipf3ciy6fubtcr
Hello all. is this still under development? I really need this feature. Let me know if I can help.
@robydev We'd love your help. If you're interested, let me know and I can prepare a summary of past discussion here to help you get started.
ok. how can I start looking at the code? fork, pull request or branch?
Great! There was some progress made by @moonmeister at https://github.com/moonmeister/platform/tree/PLT-200
There is also some discussion here that might be relevant: https://pre-release.mattermost.com/core/pl/74s6ns9reibozbnrngasxqeyry
Hi Jason,
I'm struggling with development. I can't get a maintainable development environment.
What IDE are you using? How are you debbuging the service? Where are the unittests?
Hey @rbdevr, have you taken a look at the developer machine setup guide yet? https://docs.mattermost.com/developer/dev-setup.html
This is now completed and scheduled for Mattermost v5.1
Awesome news Jason.
Please create a document explaining how to setup MM server to work with subdirectories.
Cant wait for next release! Great job!
Most helpful comment
This is now completed and scheduled for Mattermost v5.1