question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Gitlab repo authorization fails on self-hosted instances

See original GitHub issue

Recent releases of diagrams.net (not sure but at least in 14.9.7) self-hosted docker instance cannot authorize in GitLab 14.1.2 self-hosted instance as well). I thought this fails was due to some misconfiguration from my side… but…

https://github.com/jgraph/drawio/blob/609d031c9430ae737dc30fb11ac11709fb63a19d/src/main/webapp/js/diagramly/GitLabClient.js#L44

It is strange that .html has been missed ^^^ while it is explicitly emphasized in Guides (link1, jgraph/drawio#493 ), that gitlab.html is important!

Suggested fix:

---GitLabClient.prototype.redirectUri = window.location.protocol + '//' + window.location.host + '/gitlab'; 
+++GitLabClient.prototype.redirectUri = window.location.protocol + '//' + window.location.host + '/gitlab.html'; 

this workaround worked before GitLab authetication process upgraded since release 14.6.7 and [docker-drawio] corresponding upgrade](https://github.com/jgraph/docker-drawio/commit/d52488974a0f7740a17c66929ba4943ecc4ccb1a). Nowdays similar way doesn’t work…

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:40 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
tafkoscommented, Sep 15, 2021

This helped to finally fix the issue: https://stackoverflow.com/a/42377335/8655060

Just imported self-signed certificate of gitlab instance into java keystore inside self-hosted drawio container and restarted it!

Thanks everybody!

1reaction
lfvjimisolacommented, Sep 5, 2021

We have used the fix as in #2193.

As for servlet and serving the project we aren’t following. What do you mean by serving the project? Do we need to activate or configure something else?

We are running a self-hosted GitLab and DrawIO runs as a container inside an OpenShift cluster. We are setting thethe following environment variables:

  • DRAWIO_GITLAB_ID
  • DRAWIO_GITLAB_URL
  • DRAWIO_BASE_URL

but not

  • DRAWIO_GITLAB_SECRET
Read more comments on GitHub >

github_iconTop Results From Across the Web

GitLab authentication and authorization
GitLab integrates with a number of OmniAuth providers, and the following external authentication and authorization providers:.
Read more >
Connecting self-hosted GitLab instances - Bitrise Docs
Setting up an app that is in a self-hosted GitLab repository is very simple: Bitrise needs to be authorized as an application for...
Read more >
Connecting a self-hosted GitLab repository as your source
Go to Settings / Self Hosted GitLab · Enter the details for your self-hosted instance of GitLab · Click Configure Self Hosted GitLab....
Read more >
Gitlab (self hosted gitlab) pipeline fail when trying to fetch ...
So, per the above, host everything with https:// and proper user-name/password/api token/etc auth. Allowing "all of internet" inbound is a bad ...
Read more >
Getting started with the API - python-gitlab v3.12.0
Gitlab (private_token='JVNSESs8EwWRx5yDxM5q') # private token or personal token authentication (self-hosted GitLab instance) gl = gitlab.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found