Skip to content

Completed Pods are coloured red #34

@johscheuer

Description

@johscheuer

Hi,

when I create a CronJob with the following spec:

apiVersion: batch/v1beta1
kind: CronJob
metadata:
  name: sleepy
spec:
  schedule: "*/2 * * * *"
  jobTemplate:
    spec:
      template:
        spec:
          containers:
          - name: resting
            image: busybox
            command: ["/bin/sleep"]
            args: ["3"]
          restartPolicy: Never

and when I use kubectl tree after a Job was created and has successful completed the Reason PodCompleted will be coloured red. I assume (without looking in the code) that the Reason is always coloured red if the Pod is not ready? For me red means normally some kind of a failure what about changing the colour of the Reason PodCompleted to green (or something similar)?

 kubectl tree cronjob sleepy
NAMESPACE  NAME                    READY  REASON        AGE
default    CronJob/sleepy          -                    62s
default    └─Job/me-sleep          -                    9s
default      └─Pod/me-sleep-qkhxm  False  PodCompleted  9s

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions