title: Trouble building executable jar file with Gradle and Spring-boot
body: <p>I am having trouble executing the built jar file:</p>
  
  <p>Running the following command <code>java -jar /build/libs/***.jar</code> gives me a bunch of <code>NoClassDefFoundError</code> errors.</p>
  
  <p>But when I run <code>gradle bootrun</code> it works fine...</p>
  
  <p>I have followed instructions here: <a href="http://docs.spring.io/spring-boot/docs/current/reference/html/build-tool-plugins-gradle-plugin.html" rel="nofollow">http://docs.spring.io/spring-boot/docs/current/reference/html/build-tool-plugins-gradle-plugin.html</a></p>
  
  <p>My build.gradle looks like this:</p>
  
  <pre><code>apply plugin: 'spring-boot'
  
  sourceCompatibility = 1.5
  version = '1.0'
  
  buildscript {
      repositories {
          jcenter()
      }
  
      dependencies {
          classpath("org.springframework.boot:spring-boot-gradle-plugin:1.2.6.RELEASE")
      }
  }
  
  springBoot {
      mainClass = "org.gradle.App"
  }
  
  dependencies {
      compile files('lib/selenium-server-standalone-2.47.1.jar')
  }
  </code></pre>
  
  <p>Thank you.</p>