<p>I want to build a troube shooting pod, this is my Dockerbuild file:</p>
<pre><code>FROM alpine:3.11

MAINTAINER jiangxiaoqiang (jiangtingqiang@gmail.com)

ENV LANG=en_US.UTF-8 \
    LC_ALL=en_US.UTF-8 \
    TZ=Asia/Shanghai


RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime \
    &amp;&amp; echo $TZ &gt; /etc/timezone \
    &amp;&amp; apk add --no-cache curl jq \
    nmap \
    bind-tools \
    busybox-extras \
    bash


CMD [&quot;/bin/bash&quot;,&quot;-l&quot;]
</code></pre>
<p>but when I start it in kubernetes cluster, it shows: <code>Back-off restarting failed container</code>, and always restart all the time. so simple docker container ,why give me this tips? this is the descibe output:</p>
<pre><code>[root@k8smaster ~]# kubectl describe pod ts-7d754488b9-jqqh9
Name:         ts-7d754488b9-jqqh9
Namespace:    default
Priority:     0
Node:         k8sslave2/192.168.31.31
Start Time:   Wed, 02 Sep 2020 12:28:48 -0400
Labels:       k8s-app=ts
              pod-template-hash=7d754488b9
Annotations:  cni.projectcalico.org/podIP: 10.11.125.135/32
Status:       Running
IP:           10.11.125.135
IPs:
  IP:           10.11.125.135
Controlled By:  ReplicaSet/ts-7d754488b9
Containers:
  ts:
    Container ID:   docker://0c810ed8f8ec1cde6c0249edde59fc28a169d5730e87c423403f802cd12df6dd
    Image:          registry.cn-shanghai.aliyuncs.com/jiangxiaoqiang/dolphin/k8s-ts:v0.0.1
    Image ID:       docker-pullable://registry.cn-shanghai.aliyuncs.com/jiangxiaoqiang/dolphin/k8s-ts@sha256:68edaed45c1fadee71abbe7bdaad23f2400f352f1b6309142689a197367f3ae9
    Port:           &lt;none&gt;
    Host Port:      &lt;none&gt;
    State:          Waiting
      Reason:       CrashLoopBackOff
    Last State:     Terminated
      Reason:       Completed
      Exit Code:    0
      Started:      Wed, 02 Sep 2020 12:30:13 -0400
      Finished:     Wed, 02 Sep 2020 12:30:13 -0400
    Ready:          False
    Restart Count:  4
    Environment:    &lt;none&gt;
    Mounts:
      /var/run/secrets/kubernetes.io/serviceaccount from default-token-79w95 (ro)
Conditions:
  Type              Status
  Initialized       True 
  Ready             False 
  ContainersReady   False 
  PodScheduled      True 
Volumes:
  default-token-79w95:
    Type:        Secret (a volume populated by a Secret)
    SecretName:  default-token-79w95
    Optional:    false
QoS Class:       BestEffort
Node-Selectors:  &lt;none&gt;
Tolerations:     node.kubernetes.io/not-ready:NoExecute for 300s
                 node.kubernetes.io/unreachable:NoExecute for 300s
Events:
  Type     Reason     Age                  From                Message
  ----     ------     ----                 ----                -------
  Normal   Scheduled  &lt;unknown&gt;            default-scheduler   Successfully assigned default/ts-7d754488b9-jqqh9 to k8sslave2
  Normal   Created    96s (x4 over 2m17s)  kubelet, k8sslave2  Created container ts
  Normal   Started    95s (x4 over 2m16s)  kubelet, k8sslave2  Started container ts
  Warning  BackOff    69s (x7 over 2m15s)  kubelet, k8sslave2  Back-off restarting failed container
  Normal   Pulling    54s (x5 over 2m17s)  kubelet, k8sslave2  Pulling image &quot;registry.cn-shanghai.aliyuncs.com/jiangxiaoqiang/dolphin/k8s-ts:v0.0.1&quot;
  Normal   Pulled     54s (x5 over 2m17s)  kubelet, k8sslave2  Successfully pulled image &quot;registry.cn-shanghai.aliyuncs.com/jiangxiaoqiang/dolphin/k8s-ts:v0.0.1&quot;
</code></pre>

Dolphin
<p>The container is completed means it is  finished it's execution task. If you wish the container should run for specific time then pass eg .<code> sleep 3600</code> as argument or you can use <code>restartPolicy: Never</code> in your deployment file.</p>
<p>something like this</p>
<pre><code>spec:
  containers:
  - image: alpine
    command:
      - /bin/sh
      - &quot;-c&quot;
      - &quot;sleep 60m&quot;
    imagePullPolicy: Always
    restartPolicy: Never
    name: alpine
</code></pre>
