Closed emichaf closed 5 years ago
Maybe -(hyphen) is evaluated as minus. I think we have to escape. https://github.com/Knetic/govaluate/blob/master/README.md#escaping-characters https://github.com/argoproj/argo/pull/1240
does this when
refer to the argo workflow
template or the argo-events gateway
template? If the prior, please raise this as an issue in the https://github.com/argoproj/argo repo
Tried Both:
1)
- - name: build-and-push-docker-image-to-registry
template: build-and-push-docker-image-to-registry
when: "{{workflow.parameters.gerritevent}} == change\\-merged"
arguments:
artifacts:
- name: source
from: "{{steps.gerrit-checkout.outputs.artifacts.source}}"
2)
- - name: build-and-push-docker-image-to-registry
template: build-and-push-docker-image-to-registry
when: "{{workflow.parameters.gerritevent}} == [change-merged]"
arguments:
artifacts:
- name: source
from: "{{steps.gerrit-checkout.outputs.artifacts.source}}"
It did not work, the workflow execution do not continues to my exit handler, it's hangs!
This looks like Argo workflow issue. Can you raise it in https://github.com/argoproj/argo/issues?
Trying the conditional "when" based on global var {{workflow.parameters.gerritevent}}, but the steps with "when" is never executed and the work flow doesn't excecute the onExit: exit-handler either!