# Installing GitLab from source and configuring GitLab Mattermost

**URL:** <https://forum.mattermost.com/t/installing-gitlab-from-source-and-configuring-gitlab-mattermost/200>\
**Category:** Troubleshooting\
**Created:** [September 11, 2015, 9:15am UTC](https://forum.mattermost.com/t/installing-gitlab-from-source-and-configuring-gitlab-mattermost/200 "2015-09-11T09:15:32Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![alerque](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mattermost.com/alerque/32/93_2.png) [@alerque](https://forum.mattermost.com/u/alerque)\
**Post date:** [September 17, 2015, 5:57am UTC](https://forum.mattermost.com/t/installing-gitlab-from-source-and-configuring-gitlab-mattermost/200/4 "2015-09-17T05:57:58Z")

</div>

Hey @alexjironkin I’m not sure how much help this will be as my setup isn’t working either, but [my installation seems to have different issues](http://forum.mattermost.com/t/how-is-gitlab-sso-configured-in-gitlab-mattermost/147?u=alerque) than yours. Here is how I setup my Apache virtual host:

```
<VirtualHost *:443>
	ServerName mattermost.alerque.com
	DocumentRoot /usr/share/webapps/mattermost/web

	SSLEngine on
	SSLCertificateFile /etc/httpd/ssl.crt/alerque.com.crt
	SSLCertificateKeyFile /etc/httpd/ssl.key/alerque.com.key

	ProxyPreserveHost On

	RewriteEngine On
	RewriteCond %{DOCUMENT_ROOT}/%{REQUEST_FILENAME} !-f
	RewriteRule .* http://127.0.0.1:8065%{REQUEST_URI} [P,QSA]
	RequestHeader set X_Forwarded_Proto "https"

	<Location />
		Require all granted
		ProxyPassReverse https://mattermost.alerque.com/
	</Location>

	LogFormat "%{X-Forwarded-For}i %l %u %t \"%r\" %>s %b" common_forwarded
	ErrorLog /var/log/httpd/mattermost.alerque.com_error.log
	CustomLog /var/log/httpd/mattermost.alerque.com_forwarded.log common_forwarded
	CustomLog /var/log/httpd/mattermost.alerque.com_access.log combined env=!dontlog
	CustomLog /var/log/httpd/mattermost.alerque.com.log combined
</VirtualHost>

```

Note this is for Apache 2.4 and an SSL enabled virtual host. A separate config handles redirecting non SSL requests from port 80 to this virtual host. If you are not using SSL you would obviously drop the SSL\* config items and run this on `*:80` or your name based equivalent. Also it looks like you are trying to use a folder path rather than a dedicated subdomain so you will need to use different path specs for both the rewrite rule and the location block.

Again this may or may not actually be right as I have problems of my own, but I think I’m passed the error you are hitting because I at least get a functional site through the proxy.

---

_[View the full topic](https://forum.mattermost.com/t/installing-gitlab-from-source-and-configuring-gitlab-mattermost/200)._
