Skip to content

Commit

Permalink
fix: Set scheduling constraints to the agent pod by the workflow. Fixes
Browse files Browse the repository at this point in the history
#9704 (#9771)

Signed-off-by: yangxue.chen <chenyangxuehdu@126.com>

Signed-off-by: yangxue.chen <chenyangxuehdu@126.com>
Co-authored-by: yangxue.chen <chenyangxuehdu@126.com>
  • Loading branch information
chenyangxueHDU and yangxue.chen committed Oct 10, 2022
1 parent f767f39 commit dc48c8c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions workflow/controller/agent.go
Expand Up @@ -238,6 +238,8 @@ func (woc *wfOperationCtx) createAgentPod(ctx context.Context) (*apiv1.Pod, erro
},
}

addSchedulingConstraints(pod, woc.execWf.Spec.DeepCopy(), &wfv1.Template{})

if woc.controller.Config.InstanceID != "" {
pod.ObjectMeta.Labels[common.LabelKeyControllerInstanceID] = woc.controller.Config.InstanceID
}
Expand Down

0 comments on commit dc48c8c

Please sign in to comment.