Skip to content

Commit 9e700d9

Browse files
committed
Merge remote-tracking branch 'origin/hotfix-v0.34.0-precut' into feat-file-variable-cm-mount
2 parents 4bbb9ff + 22cafd1 commit 9e700d9

2 files changed

Lines changed: 19 additions & 15 deletions

File tree

ci-runner/helper/DockerHelper.go

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -166,20 +166,18 @@ func (impl *DockerHelperImpl) StartDockerDaemonAndDockerLogin(commonWorkflowRequ
166166
util.PrintFileContent(DOCKERD_OUTPUT_FILE_PATH)
167167
return err
168168
}
169-
if commonWorkflowRequest.CiBuildConfig != nil && !commonWorkflowRequest.CiBuildConfig.CiBuildType.IsSkipBuildType() {
170-
ciContext := cicxt.BuildCiContext(context.Background(), commonWorkflowRequest.EnableSecretMasking)
171-
err = impl.DockerLogin(ciContext, &DockerCredentials{
172-
DockerUsername: commonWorkflowRequest.DockerUsername,
173-
DockerPassword: commonWorkflowRequest.DockerPassword,
174-
AwsRegion: commonWorkflowRequest.AwsRegion,
175-
AccessKey: commonWorkflowRequest.AccessKey,
176-
SecretKey: commonWorkflowRequest.SecretKey,
177-
DockerRegistryURL: commonWorkflowRequest.IntermediateDockerRegistryUrl,
178-
DockerRegistryType: commonWorkflowRequest.DockerRegistryType,
179-
})
180-
if err != nil {
181-
return err
182-
}
169+
ciContext := cicxt.BuildCiContext(context.Background(), commonWorkflowRequest.EnableSecretMasking)
170+
err = impl.DockerLogin(ciContext, &DockerCredentials{
171+
DockerUsername: commonWorkflowRequest.DockerUsername,
172+
DockerPassword: commonWorkflowRequest.DockerPassword,
173+
AwsRegion: commonWorkflowRequest.AwsRegion,
174+
AccessKey: commonWorkflowRequest.AccessKey,
175+
SecretKey: commonWorkflowRequest.SecretKey,
176+
DockerRegistryURL: commonWorkflowRequest.IntermediateDockerRegistryUrl,
177+
DockerRegistryType: commonWorkflowRequest.DockerRegistryType,
178+
})
179+
if err != nil {
180+
return err
183181
}
184182

185183
return nil

kubewatch/pkg/informer/cluster/systemExec/helper.go

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,13 @@ func (impl *InformerImpl) inferFailedReason(eventType string, pod *coreV1.Pod) (
220220
// were SIGKILL'd. The executor may have had to forcefully terminate the sidecar (kill -9),
221221
// resulting in a 137 exit code (which we had ignored earlier). If failMessages is empty, it
222222
// indicates that this is the case and we return Success instead of Failure.
223-
return v1alpha1.NodeSucceeded, ""
223+
224+
// Update diff from argo workflow here as we only have one main container.
225+
// Handling this for case of spot interruption where containers are in running state (no termination state found), in that case
226+
// it was marking it successful, doing this as it will be skipped at upper level, and delete event will handle it.
227+
// ticket - you can find debug logs/details here - https://github.com/devtron-labs/sprint-tasks/issues/2092
228+
impl.logger.Infow("Pod phase was Failed but no container had terminated state, marking it as failed now", "podName", pod.Name, "status", pod.Status)
229+
return v1alpha1.NodeFailed, ""
224230
}
225231

226232
func getFailedReasonFromPodConditions(conditions []coreV1.PodCondition) string {

0 commit comments

Comments
 (0)