<p>When I tries create pod from docker images, I get create container error. Here is my pod.yml file</p>

<pre><code>apiVersion: v1
kind: Pod
metadata:
  name: client
spec:
  containers:
    - image: es-tutorial_web
      imagePullPolicy: Never
      name: es-web
      ports:
        - containerPort: 3000
    - image: es-tutorial_filebeat
      imagePullPolicy: Never
      name: es-filebeat
</code></pre>

<p>docker-compose.yml</p>

<pre><code>version: '3.7'
services:
  web:
    build:
      context: .
      dockerfile: ./Dockerfile
    container_name: test-app
    working_dir: /usr/src/app
    command: /bin/bash startup.sh
    volumes:
      - .:/usr/src/app
    ports:
      - "3000:3000"
    networks:
      - logs
  filebeat:
    build:
      context: .
      dockerfile: filebeat/Dockerfile
    container_name: test-filebeat
    volumes:
      - .:/usr/src/app
    depends_on:
      - web
    networks:
      - logs

networks:
  logs:
    driver: bridge
</code></pre>

<p>kubectl get pods</p>

<pre><code>client                               1/2     CreateContainerError   0          24m
</code></pre>

<p>kubectl describe client</p>

<pre><code>Name:         client
Namespace:    default
Priority:     0
Node:         minikube/10.0.2.15
Start Time:   Tue, 15 Oct 2019 15:29:02 +0700
Labels:       &lt;none&gt;
Annotations:  kubectl.kubernetes.io/last-applied-configuration:
                {"apiVersion":"v1","kind":"Pod","metadata":{"annotations":{},"name":"client","namespace":"default"},"spec":{"containers":[{"image":"es-tut...
Status:       Pending
IP:           172.17.0.8
Containers:
  es-web:
    Container ID:   
    Image:          es-tutorial_web
    Image ID:       
    Port:           3000/TCP
    Host Port:      0/TCP
    State:          Waiting
      Reason:       CreateContainerError
    Ready:          False
    Restart Count:  0
    Environment:    &lt;none&gt;
    Mounts:
      /var/run/secrets/kubernetes.io/serviceaccount from default-token-5ftqt (ro)
  es-filebeat:
    Container ID:   docker://4174e7eb5bf8abe7662698c96d7945a546503f3c5494cad2ae10d2a8d4f02762
    Image:          es-tutorial_filebeat
    Image ID:       docker://sha256:4e3d24ef67bb05b2306eb49eab9d8a3520aa499e7a30cf0856b8658807b49b57
    Port:           &lt;none&gt;
    Host Port:      &lt;none&gt;
    State:          Running
      Started:      Tue, 15 Oct 2019 15:29:03 +0700
    Ready:          True
    Restart Count:  0
    Environment:    &lt;none&gt;
    Mounts:
      /var/run/secrets/kubernetes.io/serviceaccount from default-token-5ftqt (ro)
Conditions:
  Type              Status
  Initialized       True 
  Ready             False 
  ContainersReady   False 
  PodScheduled      True 
Volumes:
  default-token-5ftqt:
    Type:        Secret (a volume populated by a Secret)
    SecretName:  default-token-5ftqt
    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  13m                   default-scheduler  Successfully assigned default/client to minikube
  Normal   Pulled     13m                   kubelet, minikube  Container image "es-tutorial_filebeat" already present on machine
  Normal   Created    13m                   kubelet, minikube  Created container es-filebeat
  Normal   Started    13m                   kubelet, minikube  Started container es-filebeat
  Warning  Failed     11m (x11 over 13m)    kubelet, minikube  Error: Error response from daemon: No command specified
  Normal   Pulled     3m26s (x50 over 13m)  kubelet, minikube  Container image "es-tutorial_web" already present on machine
</code></pre>

<p>Dockerfile</p>

<pre><code>...
RUN apt-get update &amp;&amp; apt-get install -y curl

RUN curl -sL "https://deb.nodesource.com/setup_12.x" | bash - &amp;&amp; apt-get install -y nodejs &amp;&amp; echo 'node' &gt; node
RUN mkdir -p /usr/src/app
COPY . /usr/src/app
WORKDIR /usr/src/app
RUN chmod +x startup.sh
RUN npm install -g nodemon
</code></pre>

<p>startup.sh</p>

<pre><code>if [ ! -d /usr/src/app/node_modules ]; then
  echo "Install dependencies..."
  cd /usr/src/app &amp;&amp; npm install --no-bin-links
fi
cd /usr/src/app &amp;&amp; nodemon -L bin/www
</code></pre>

<p>Where is my wrong? Please help me</p>

<p>I believe you're missing <a href="https://docs.docker.com/engine/reference/builder/#cmd" rel="nofollow noreferrer"><code>CMD</code></a> or <a href="https://docs.docker.com/engine/reference/builder/#entrypoint" rel="nofollow noreferrer"><code>ENTRYPOINT</code></a> in your <code>Dockerfile</code>. They're required to run the container.</p>

<p>It should be set to some default command which you plan to run when executing container.</p>

<p>If <code>startup.sh</code> is your script running the app, try the following:</p>

<pre><code>ENTRYPOINT /usr/src/app/startup.sh
</code></pre>

<p>Or modify your <code>Dockerfile</code> to:</p>

<pre><code># ...
WORKDIR /usr/src/app
RUN chmod +x startup.sh
RUN npm install -g nodemon
RUN test ! -d /usr/src/app/node_modules &amp;&amp; npm install --no-bin-links
ENTRYPOINT ["/usr/src/app/nodemon", "-L", "bin/www"]
</code></pre>
