mirror of
https://github.com/goharbor/harbor.git
synced 2025-01-16 04:31:22 +01:00
Before fetching the repository check if the project has container
registry enabled. closes #14328 #13353 Signed-off-by: Vadim Bauer <vb@container-registry.com>
This commit is contained in:
parent
b74c4b0cfe
commit
e714a8eacc
@ -116,6 +116,11 @@ func (a *adapter) FetchArtifacts(filters []*model.Filter) ([]*model.Resource, er
|
|||||||
}
|
}
|
||||||
|
|
||||||
for _, project := range projects {
|
for _, project := range projects {
|
||||||
|
if !project.RegistryEnabled {
|
||||||
|
log.Debugf("Skipping project %s: Registry is not enabled", project.Name)
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
repositories, err := a.clientGitlabAPI.getRepositories(project.ID)
|
repositories, err := a.clientGitlabAPI.getRepositories(project.ID)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
|
Loading…
Reference in New Issue
Block a user