Support serving Mattermost from subpaths

Description

Transformed into an epic from: https://mattermost.atlassian.net/browse/MM-1000

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

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.

QA Test Steps

None

Status

Mana

None

Assignee

Unassigned

QA Assignee

Lindy Isherwood

Reporter

Christopher Speller

Fix versions

None

Mattermost Team

ABC

Sprint

None

Labels

None

QA Testing Areas

None

GitHub Issue

None

Components

None

Epic Name

Subpath
Configure