title: Run Jenkins in a Docker container fails with script.sh: docker: not found
body: <p>I tried to build a simple JS app in Jenkins Docker container locally and the build failed with:</p>
  
  <pre><code>script.sh: docker: not found (full stack trace is omitted for easier reading)
  </code></pre>
  
  <p>Here is <code>Jenkinsfile</code> of the app:</p>
  
  <pre><code>pipeline {
    agent { dockerfile true }
  
    stages {
      stage('Install') {
        steps {
          sh 'node -v '      
          sh 'yarn -v'
          sh 'ember -v'
  
        }
      }
    }
  }
  </code></pre>
  
  <p>Here is <code>Dockerfile</code> of the app:</p>
  
  <pre><code>FROM node:12
  
  RUN curl -o- -L https://yarnpkg.com/install.sh | bash
  RUN npm install -g ember-cli
  </code></pre>
  
  <p>What am I missing? Thank you.</p>