Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Dont Merge] cherry pick #3613 to release 3.1.0 (IfNotPresent) #3728

Open
wants to merge 1 commit into
base: release-3.1.0
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions pkg/microservice/aslan/core/common/service/kube/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -774,7 +774,7 @@ spec:
containers:
- name: agent
image: {{.HubAgentImage}}
imagePullPolicy: Always
imagePullPolicy: IfNotPresent
env:
- name: AGENT_NODE_NAME
valueFrom:
Expand Down Expand Up @@ -938,7 +938,7 @@ spec:
containers:
- name: agent
image: {{.HubAgentImage}}
imagePullPolicy: Always
imagePullPolicy: IfNotPresent
env:
- name: AGENT_NODE_NAME
valueFrom:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ echo $result > %s
ImagePullSecrets: ImagePullSecrets,
Containers: []corev1.Container{
{
ImagePullPolicy: corev1.PullAlways,
ImagePullPolicy: corev1.PullIfNotPresent,
Name: GetJobContainerName(jobTask.Name),
Image: jobTaskSpec.Plugin.Image,
Args: jobTaskSpec.Plugin.Args,
Expand Down Expand Up @@ -481,7 +481,7 @@ func buildJob(jobType, jobImage, jobName, clusterID, currentNamespace string, re
},
Containers: []corev1.Container{
{
ImagePullPolicy: corev1.PullAlways,
ImagePullPolicy: corev1.PullIfNotPresent,
Name: GetJobContainerName(strings.ReplaceAll(jobTask.Name, "_", "-")),
Image: jobImage,
Command: []string{"/bin/sh", "-c"},
Expand Down Expand Up @@ -556,7 +556,7 @@ func BuildCleanJob(jobName, clusterID, workflowName string, taskID int64) (*batc
RestartPolicy: corev1.RestartPolicyNever,
Containers: []corev1.Container{
{
ImagePullPolicy: corev1.PullAlways,
ImagePullPolicy: corev1.PullIfNotPresent,
Name: jobName,
Image: image,
WorkingDir: workspace,
Expand Down
2 changes: 1 addition & 1 deletion pkg/microservice/aslan/core/environment/service/debug.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ func genDebugContainer(imageName string) *corev1.EphemeralContainer {
Name: ZadigDebugContainerName,
Image: imageName,
Command: []string{"tail", "-f", "/dev/null"},
ImagePullPolicy: corev1.PullAlways,
ImagePullPolicy: corev1.PullIfNotPresent,
TerminationMessagePolicy: corev1.TerminationMessageFallbackToLogsOnError,
},
}
Expand Down
8 changes: 4 additions & 4 deletions pkg/microservice/aslan/core/environment/service/ide.go
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ func patchDeployment(ctx context.Context, kclient client.Client, selector labels
corev1.Container{
Name: types.IDEContainerNameDev,
Image: devImage,
ImagePullPolicy: corev1.PullAlways,
ImagePullPolicy: corev1.PullIfNotPresent,
Command: []string{"/bin/sh", "-c", "tail -f /dev/null"},
WorkingDir: types.DevmodeWorkDir,
Resources: corev1.ResourceRequirements{
Expand All @@ -225,7 +225,7 @@ func patchDeployment(ctx context.Context, kclient client.Client, selector labels
corev1.Container{
Name: types.IDEContainerNameSidecar,
Image: types.IDESidecarImage,
ImagePullPolicy: corev1.PullAlways,
ImagePullPolicy: corev1.PullIfNotPresent,
Command: []string{"/bin/sh", "-c", "tail -f /dev/null"},
WorkingDir: types.DevmodeWorkDir,
Resources: corev1.ResourceRequirements{
Expand Down Expand Up @@ -318,7 +318,7 @@ func patchStatefulSet(ctx context.Context, kclient client.Client, selector label
corev1.Container{
Name: types.IDEContainerNameDev,
Image: devImage,
ImagePullPolicy: corev1.PullAlways,
ImagePullPolicy: corev1.PullIfNotPresent,
Command: []string{"/bin/sh", "-c", "tail -f /dev/null"},
WorkingDir: types.DevmodeWorkDir,
Resources: corev1.ResourceRequirements{
Expand All @@ -337,7 +337,7 @@ func patchStatefulSet(ctx context.Context, kclient client.Client, selector label
corev1.Container{
Name: types.IDEContainerNameSidecar,
Image: types.IDESidecarImage,
ImagePullPolicy: corev1.PullAlways,
ImagePullPolicy: corev1.PullIfNotPresent,
Command: []string{"/bin/sh", "-c", "tail -f /dev/null"},
WorkingDir: types.DevmodeWorkDir,
Resources: corev1.ResourceRequirements{
Expand Down
Loading