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

[BUG] pod.name within retry does not match actual container #1646

Closed
c-dante opened this issue Oct 4, 2019 · 0 comments · Fixed by #1699
Closed

[BUG] pod.name within retry does not match actual container #1646

c-dante opened this issue Oct 4, 2019 · 0 comments · Fixed by #1699
Assignees
Labels

Comments

@c-dante
Copy link

c-dante commented Oct 4, 2019

BUG REPORT:

What happened:
Using {{pod.name}} inside a retry gave the retry's node for each retry instance, not the individual instance's pod name. It prints:

MY_KUBE_NAME=pod-name-b9gvx-1810249896
MY_ARGO_NAME=pod-name-b9gvx

What you expected to happen:
I expect to get the actual pod name in each instance, IE both print the pod in kubernetes.

How to reproduce it (as minimally and precisely as possible):

apiVersion: argoproj.io/v1alpha1
kind: Workflow
metadata:
  generateName: pod-name-
spec:
  entrypoint: pod-name
  templates:
  - name: pod-name
    retryStrategy:
        limit: 1
    container:
      image: docker/whalesay
      env:
        - name: MY_ARGO_NAME
          value: "{{pod.name}}"
        - name: MY_KUBE_NAME
          valueFrom:
            fieldRef:
              fieldPath: metadata.name
      command: ["/bin/sh"]
      args: ["-c", "env | grep MY_; exit 1"]

Anything else we need to know?:

Environment:

  • Argo version:
argo: v2.2.1
  BuildDate: 2018-10-11T16:26:28Z
  GitCommit: 3b52b26190163d1f72f3aef1a39f9f291378dafb
  GitTreeState: clean
  GitTag: v2.2.1
  GoVersion: go1.10.3
  Compiler: gc
  Platform: linux/amd64
  • Kubernetes version :
clientVersion:
  buildDate: "2019-09-18T14:51:13Z"
  compiler: gc
  gitCommit: 67d2fcf276fcd9cf743ad4be9a9ef5828adc082f
  gitTreeState: clean
  gitVersion: v1.15.4
  goVersion: go1.12.9
  major: "1"
  minor: "15"
  platform: linux/amd64
serverVersion:
  buildDate: "2019-06-19T20:48:40Z"
  compiler: gc
  gitCommit: f53039cc1e5295eed20969a4f10fb6ad99461e37
  gitTreeState: clean
  gitVersion: v1.12.8-gke.10
  goVersion: go1.10.8b4
  major: "1"
  minor: 12+
  platform: linux/amd64
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants