fix URL bug in ContainerRegistryService
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
6fae2e4115
commit
00c7d562ad
|
@ -76,7 +76,8 @@ class ContainerRegistryService:
|
|||
# For some reason a 403 is returned if the project doesn't exist
|
||||
return
|
||||
resp.raise_for_status()
|
||||
repositories = [repo['name'] for repo in resp.json()]
|
||||
# Each repo name has the format project/image
|
||||
repositories = [repo['name'].split('/')[1] for repo in resp.json()]
|
||||
for repo in repositories:
|
||||
resp = self._http_delete(f'/projects/{username}/repositories/{repo}')
|
||||
resp.raise_for_status()
|
||||
|
|
|
@ -56,7 +56,8 @@ class MockHarborServer(MockHTTPServerBase):
|
|||
}]}, status=403)
|
||||
projects = self.projects[project_name]
|
||||
return web.json_response([
|
||||
{'id': i, 'name': name} for i, name in enumerate(projects)
|
||||
{'id': i, 'name': project_name + '/' + name}
|
||||
for i, name in enumerate(projects)
|
||||
])
|
||||
|
||||
async def users_get_handler(self, request):
|
||||
|
|
Loading…
Reference in New Issue