Mattermost Peer-to-Peer Forum

Cannot "Log in with GitLab"


#1

Please include with your troubleshooting request:

Summary

I want to log into mattermost..com on a GItLab Omnibus install. I can’t log in with gitlab

Steps to reproduce

Install. Navigate to mattermost..com. Click “Log in with Gitlab”

You are taken to gitlab..com and there you see this error:

An error has occurred

The redirect URI included is not valid.

#2

Hi @SSD! Thank you for reaching out.

To troubleshoot this further, can you help with the following additional details:

  1. Your Mattermost server version and Gitlab version?
  2. The url that you are using?
  3. The device you are using (mobile, webapp, etc.)?
  4. Are you seeing any errors in logs?
  5. Would you have a screenshot to share?

Let me know any questions!


#3

Yes.

  1. Gitlab Omnibus 10.7.3. (Mattermost is included)

  2. gitlab..com and mattermost..com

  3. web interface

  4. I had logging disabled so not yet.

  5. No I don’t have a screenshot but if you need one I can provide it. Do you need one? Is the error message I explained above not useful?


#4

Hi @SSD,

if you go to GitLab page in the Mattermost System Console or look at the GitLabSettings section of /var/opt/gitlab/mattermost/config.json, do the endpoints use the correct URL for the GitLab instance? Similarly, if you go to the Applications > GitLab Mattermost section in the admin area in GitLab, does the redirect URI there use the correct address for the Mattermost instance?

I believe you may be hitting this issue.


#5

Hello,
We are a little stumped. We have tried setting up SSO using Gitlab into our mattermost implementation. no matter what we do we get the same error: when clicking on sign in with gitlab: At first before it was validated it would take us to a page on mattermost that asked to authenticate and once you do it takes you to a:

We currently use google to log into Gitlab if that helps.
We have extensively tried to research this issue with no results. If anyone can help that would be great!


#6

Our platform :
image


#7

Our mattermost:
image


#8

Hi @stavros,

Here is a response from a community member:

The error page indicates that the SSO endpoint returned unexpected HTTP status code, i.e., not 200. To debug this further you might want look at the SSO provider’s log files.


#9

I’d add that that usually means the endpoints that Mattermost uses to connect to GitLab are incorrect. If you’re using GitLab Omnibus, they’d be configured automatically, but if you configured those settings yourself, you may want to double check those values.