-
-
Notifications
You must be signed in to change notification settings - Fork 163
GITLAB_{URI,HOST} lead to failure if scheme is provided, documentation doesn't match what code needs #592
Comments
Thanks @hartzell for reporting this issue! For a quick fix, I will change the documentation to fit what our code currently understands but I will consider that as a bug because it should be able to parse the URL (if it's a fully qualified url) provided and use the hostname. I think this issue came up after we made big changes to glab's flow in 6c4fe1c This issue is however open in case you'd want to submit a PR with a fix |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
I created a dirty fix in #667 by just checking if the hostname starts with I have a api token registred for the host I am trying to use (and it works if My idea of fixing that is that we just strip the protocol from the |
This issue has been automatically marked as stale because it has not had recent activity. We haven't had the time to address it yet, but we want to keep it open. This message is just a reminder for us to help triage issues. |
When trying to override host with full URLs, config key lookups would fail. This came down to the fact that we use `my.gitlab.com` as config key and when providing override as `https://my.gitlab.com/` it would fail to find this config key. Issue profclems#592
When trying to override host with full URLs, config key lookups would fail. This came down to the fact that we use `my.gitlab.com` as config key and when providing override as `https://my.gitlab.com/` it would fail to find this config key. Issue profclems#592
Description
We have a self-hosted GitLab instance.
The
glab
help string that says:If I set GITLAB_HOST to
https://gitlab.my.company.com
, it fails to connect to my GitLab:Walking into the code with Delve, I can see where the API endpoint is screwy:
If I set GITLAB_HOST (also tested GITLAB_URI) to just the hostname, then it works as expected
Possible Fix
Change the documentation string to describe what is actually acceptable, or change the code to handle the string that the documentation suggests.
Steps to Reproduce
see above.
Your Environment
CentOS 7, go 1.13.11 (sigh...)
Glab built locally from source
The text was updated successfully, but these errors were encountered: