Skip to content

Commit

Permalink
feat: Support gitlab onprem instance
Browse files Browse the repository at this point in the history
  • Loading branch information
jopemachine authored and kyujin-cho committed Aug 1, 2024
1 parent 229f764 commit 8994110
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/ai/backend/manager/container_registry/gitlab.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,15 @@

class GitLabRegistry_v2(BaseContainerRegistry):
async def fetch_repositories(self, sess: aiohttp.ClientSession) -> AsyncIterator[str]:
name, access_token, gitlab_project = (
name, access_token, gitlab_url, gitlab_project = (
self.registry_info["username"],
self.registry_info["password"],
self.registry_info["gitlab_url"],
self.registry_info["gitlab_project"],
)

encoded_project_id = urllib.parse.quote(f"{name}/{gitlab_project}", safe="")
repo_list_url = (
f"https://gitlab.com/api/v4/projects/{encoded_project_id}/registry/repositories"
)
repo_list_url = f"{gitlab_url}/api/v4/projects/{encoded_project_id}/registry/repositories"

headers = {
"Accept": "application/json",
Expand Down

0 comments on commit 8994110

Please sign in to comment.