Title: Auto-cloning a Gitlab repo fails with "unable to update url base from redirection" · Issue #144 · coder/backstage-plugins · GitHub
Open Graph Title: Auto-cloning a Gitlab repo fails with "unable to update url base from redirection" · Issue #144 · coder/backstage-plugins
X Title: Auto-cloning a Gitlab repo fails with "unable to update url base from redirection" · Issue #144 · coder/backstage-plugins
Description: Background My organisation is exploring Coder with the Backstage plugin and Gitlab.com (Gitlab SaaS, i.e. not self-hosted). In Backstage, before creating anything, the plugin shows: No workspaces found for repo https://gitlab.com/myorg/m...
Open Graph Description: Background My organisation is exploring Coder with the Backstage plugin and Gitlab.com (Gitlab SaaS, i.e. not self-hosted). In Backstage, before creating anything, the plugin shows: No workspaces f...
X Description: Background My organisation is exploring Coder with the Backstage plugin and Gitlab.com (Gitlab SaaS, i.e. not self-hosted). In Backstage, before creating anything, the plugin shows: No workspaces f...
Opengraph URL: https://github.com/coder/backstage-plugins/issues/144
X: @github
Domain: patch-diff.githubusercontent.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Auto-cloning a Gitlab repo fails with \"unable to update url base from redirection\"","articleBody":"### Background\n\nMy organisation is exploring Coder with the Backstage plugin and Gitlab.com (Gitlab SaaS, i.e. not self-hosted).\n\nIn Backstage, before creating anything, the plugin shows:\n\n\u003e No workspaces found for repo\n\u003e https://gitlab.com/myorg/myrepo/-/blob/main/?ref_type=heads\n\nWe see #117 and the fact a change was made, and also that a merge was made to the git clone module in PR [210](https://github.com/coder/modules/pull/210#issue-2217313475), but we are yet to be able to make it work.\n\n\n### Challenge\n\nWith a template that auto-clones, for example using the `git_clone` module:\n\n```hcl\ndata \"coder_parameter\" \"repo_url\" {\n name = \"repo_url\"\n display_name = \"Git repository\"\n}\n\nmodule \"git_clone\" {\n source = \"registry.coder.com/modules/git-clone/coder\"\n version = \"1.0.18\"\n agent_id = coder_agent.main.id\n url = data.coder_parameter.repo_url.value\n}\n```\n\nWe see the clone fail after redirection:\n\n```\nCloning https://gitlab.com/myorg/myrepo/-/blob/main/ to /home/coder/main...\nCloning into '/home/coder/main'...\n\nfatal: unable to update url base from redirection:\n asked for: https://gitlab.com/myorg/myrepo/-/blob/main/info/refs?service=git-upload-pack\n redirect: https://gitlab.com/groups/myorg/-/saml/sso?redirect=%2Fmyorg%2Fmyrepo%2F-%2Fblob%2Fmain%2Finfo%2Frefs%3Fservice%3Dgit-upload-pack\u0026token=\u003ctoken\u003e\n```\n\nWe enforce single sign-on, which may explain the saml/sso redirection.\n\n### Alternatives\n\nIf we do not \"auto-clone\", and instead try and clone from the Workspace template directly (providing \"Git repository\" in the GUI), providing \"https://gitlab.com/myorg/myrepo\", then it works.\n\nThe downside is that the Backstage plugin won't \"match\" the Workspace as being related to the Backstage entity (presumably because we omitted the `-/blob/main/?ref_type=heads` suffix).\n\nHas anyone been able to make this work with Gitlab yet please? \n","author":{"url":"https://github.com/paulm-jones","@type":"Person","name":"paulm-jones"},"datePublished":"2024-10-22T14:45:00.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":1},"url":"https://github.com/144/backstage-plugins/issues/144"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:8e128534-2f2d-2b14-f45d-045f9dc05b8b |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | AF26:B84F5:224ECC8:2C0211D:697D806F |
| html-safe-nonce | db8eb349b51ab1124305f345c618f1c2723fa40a4b494badd07c6f8a099e95a4 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBRjI2OkI4NEY1OjIyNEVDQzg6MkMwMjExRDo2OTdEODA2RiIsInZpc2l0b3JfaWQiOiI5MTgzMjgzNjc3MTcyMTcwODYzIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 02d7a35a17281d5503b6424cc1438ed1514a9a3d68f43198d48fd7306bb44d72 |
| hovercard-subject-tag | issue:2605675759 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/coder/backstage-plugins/144/issue_layout |
| twitter:image | https://opengraph.githubassets.com/5bd10c7598b85adec1ea39afd433960703db81865da2a51b3af42dd44032d15e/coder/backstage-plugins/issues/144 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/5bd10c7598b85adec1ea39afd433960703db81865da2a51b3af42dd44032d15e/coder/backstage-plugins/issues/144 |
| og:image:alt | Background My organisation is exploring Coder with the Backstage plugin and Gitlab.com (Gitlab SaaS, i.e. not self-hosted). In Backstage, before creating anything, the plugin shows: No workspaces f... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | paulm-jones |
| hostname | github.com |
| expected-hostname | github.com |
| None | 60279d4097367e16897439d16d6bbe4180663db828c666eeed2656988ffe59f6 |
| turbo-cache-control | no-preview |
| go-import | github.com/coder/backstage-plugins git https://github.com/coder/backstage-plugins.git |
| octolytics-dimension-user_id | 95932066 |
| octolytics-dimension-user_login | coder |
| octolytics-dimension-repository_id | 754910353 |
| octolytics-dimension-repository_nwo | coder/backstage-plugins |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 754910353 |
| octolytics-dimension-repository_network_root_nwo | coder/backstage-plugins |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 7c85641c598ad130c74f7bcc27f58575cac69551 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width