Skip to content

Commit

Permalink
setting cipipelineId to parent ci-pipelines id for linked ci's (#4215)
Browse files Browse the repository at this point in the history
  • Loading branch information
gireesh-naidu authored Nov 6, 2023
1 parent 87fad1d commit b691cca
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pkg/dockerRegistry/DockerRegistryIpsConfigService.go
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,11 @@ func (impl DockerRegistryIpsConfigServiceImpl) getDockerRegistryIdForCiPipeline(

if ciPipeline.IsDockerConfigOverridden {
//set dockerRegistryId value with the DockerRegistryId of the overridden dockerRegistry
ciTemplateOverride, err := impl.ciTemplateOverrideRepository.FindByCiPipelineId(ciPipelineId)
ciPipId := ciPipelineId
if ciPipeline.ParentCiPipeline != 0 {
ciPipId = ciPipeline.ParentCiPipeline
}
ciTemplateOverride, err := impl.ciTemplateOverrideRepository.FindByCiPipelineId(ciPipId)
if err != nil {
impl.logger.Errorw("error in getting ciTemplateOverride by ciPipelineId", "ciPipelineId", ciPipelineId, "error", err)
return nil, err
Expand Down

0 comments on commit b691cca

Please sign in to comment.