@@ -31,6 +31,7 @@ import (
31
31
"github.com/devtron-labs/devtron/pkg/deployment/manifest/deployedAppMetrics"
32
32
"github.com/devtron-labs/devtron/pkg/deployment/manifest/deploymentTemplate/read"
33
33
"github.com/devtron-labs/devtron/pkg/dockerRegistry"
34
+ "github.com/devtron-labs/devtron/pkg/pipeline/constants"
34
35
util2 "github.com/devtron-labs/devtron/util"
35
36
"github.com/devtron-labs/devtron/util/argo"
36
37
errors2 "github.com/juju/errors"
@@ -784,6 +785,10 @@ func (impl AppListingServiceImpl) setIpAccessProvidedData(ctx context.Context, a
784
785
}
785
786
786
787
if ciPipeline != nil && ciPipeline .CiTemplate != nil && len (* ciPipeline .CiTemplate .DockerRegistryId ) > 0 {
788
+ if ! ciPipeline .IsExternal || ciPipeline .ParentCiPipeline != 0 && ciPipeline .PipelineType != string (constants .LINKED_CD ) {
789
+ appDetailContainer .IsExternalCi = false
790
+ }
791
+ // get dockerRegistryId starts
787
792
artifact , err := impl .ciArtifactRepository .Get (appDetailContainer .CiArtifactId )
788
793
if err != nil {
789
794
impl .Logger .Errorw ("error in fetching ci artifact" , "ciArtifactId" , appDetailContainer .CiArtifactId , "error" , err )
@@ -794,13 +799,12 @@ func (impl AppListingServiceImpl) setIpAccessProvidedData(ctx context.Context, a
794
799
impl .Logger .Errorw ("error in fetching docker registry id" , "ciPipelineId" , ciPipelineId , "error" , err )
795
800
return bean.AppDetailContainer {}, err
796
801
}
797
- if ! ciPipeline .IsExternal || ciPipeline .ParentCiPipeline != 0 {
798
- appDetailContainer .IsExternalCi = false
799
- }
802
+
800
803
if dockerRegistryId == nil {
801
804
impl .Logger .Errorw ("docker registry id not found" , "ciPipelineId" , ciPipelineId )
802
805
return appDetailContainer , nil
803
806
}
807
+ // get dockerRegistryId ends
804
808
appDetailContainer .DockerRegistryId = * dockerRegistryId
805
809
806
810
_ , span = otel .Tracer ("orchestrator" ).Start (ctx , "dockerRegistryIpsConfigService.IsImagePullSecretAccessProvided" )
0 commit comments