title: Puppet Apply: Could not find class for
body: <p>It seems pretty simple thing, and it works on Vagrant, but I can't make it work on a EC2 server.</p>
  
  <p>When:</p>
  
  <pre><code> puppet apply manifests/init.pp
  </code></pre>
  
  <p>Error:</p>
  
  <pre><code> Could not find class base for s1.ec2.internal at /var/lib/jenkins/jobs/s1/workspace/manifests/init.pp:1 on node s1.ec2.internal
  </code></pre>
  
  <p>File <code>./manifests/init.pp:</code></p>
  
  <pre><code>include base
  </code></pre>
  
  <p>File <code>./manifests/base.pp:</code></p>
  
  <pre><code>class base {
  
    exec { "apt-get update":
      command =&gt; "/usr/bin/apt-get update",
      timeout =&gt; 0
    }
  
    package { ["vim", "git", "build-essential"]:
      ensure  =&gt; present,
      require =&gt; Exec["apt-get update"]
    }
  
  }
  </code></pre>
  
  <p>Puppet v2.7.23</p>