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

Workflow ignoring nodeSelector and tolerations when defined in WorkflowTemplate #12568

Closed
3 of 4 tasks
nice-pink opened this issue Jan 24, 2024 · 3 comments · Fixed by #12700
Closed
3 of 4 tasks

Workflow ignoring nodeSelector and tolerations when defined in WorkflowTemplate #12568

nice-pink opened this issue Jan 24, 2024 · 3 comments · Fixed by #12700
Assignees
Labels
area/templates/dag area/templates/steps P2 Important. All bugs with >=3 thumbs up that aren’t P0 or P1, plus: Any other bugs deemed important type/bug
Milestone

Comments

@nice-pink
Copy link
Contributor

nice-pink commented Jan 24, 2024

Pre-requisites

  • I have double-checked my configuration
  • I can confirm the issue exists when I tested with :latest
  • I have searched existing issues and could not find a match for this bug
  • I'd like to contribute the fix myself (see contributing guide)

What happened/what did you expect to happen?

I defined a WorkflowTemplate containing nodeSelector and tolerations. When I manually submit the WorkflowTemplate from the UI both fields are ignored and the workflow is running on any available node in the cluster.

Version

v3.5.4

Paste a small workflow that reproduces the issue. We must be able to run the workflow; don't enter a workflows that uses private images.

apiVersion: argoproj.io/v1alpha1
kind: WorkflowTemplate
metadata:
  name: benchmarks
spec:
  entrypoint: main
  serviceAccountName: workflow
  templates:
  - dag:
      tasks:
      - arguments:
          parameters:
          - name: msg
            value: 'hello'
        name: benchmark
        template: benchmark
    name: main
    nodeSelector:
      pool: workflows
    tolerations:
    - key: pool
      operator: Equal
      value: workflows
  - inputs:
      parameters:
      - name: msg
    name: benchmark
    script:
      command:
      - python
      image: python:latest
      source: |
        print("{{inputs.parameters.msg}}")

Logs from the workflow controller

kubectl logs -n argo deploy/workflow-controller | grep ${workflow}

Logs from in your workflow's wait container

kubectl logs -n argo -c wait -l workflows.argoproj.io/workflow=${workflow},workflow.argoproj.io/phase!=Succeeded
@tooptoop4
Copy link
Contributor

@nice-pink have u tried v3.4.11?

@nice-pink
Copy link
Contributor Author

No I haven't as we're already on v3.5.4.

@agilgur5 agilgur5 added area/workflow-templates P2 Important. All bugs with >=3 thumbs up that aren’t P0 or P1, plus: Any other bugs deemed important labels Jan 25, 2024
@shuangkun
Copy link
Member

It seems that we have not implemented the child template's inheritance of the parent template nodeSelector.Currently only workflow-level and node-level nodeSelector are supported.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/templates/dag area/templates/steps P2 Important. All bugs with >=3 thumbs up that aren’t P0 or P1, plus: Any other bugs deemed important type/bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants