Skip to content

Instantly share code, notes, and snippets.

Created April 18, 2011 21:53
Show Gist options
  • Select an option

  • Save anonymous/926273 to your computer and use it in GitHub Desktop.

Select an option

Save anonymous/926273 to your computer and use it in GitHub Desktop.
apply plugin: 'groovy'
apply plugin: 'jetty'
apply plugin: 'eclipse'
apply from: 'http://resolver/gradle-scripts/repo-settings/internal-maven.gradle'
dependencies {
groovy 'org.codehaus.groovy:groovy:1.7.10'
compile 'org.springframework:spring-webmvc:3.0.5.RELEASE'
providedCompile 'javax.servlet:servlet-api:2.5'
compile 'javax.servlet:jstl:1.2'
}
task "create-dirs" << {
sourceSets.all*.groovy.srcDirs*.each { it.mkdirs() }
sourceSets.all*.resources.srcDirs*.each { it.mkdirs() }
webAppDir.mkdirs()
}
//-- weblogic deployment
configurations {
weblogic
}
dependencies {
weblogic 'weblogic:weblogic:9.2'
weblogic 'com.rsa.jsafe:jsafe:3.5'
}
task deployToWeblogic(dependsOn:'war') << {
createDeploymentInformation()
def war = "$libsDir/${project.name}.war"
ant.taskdef(name: 'wldeploy',
classname: 'weblogic.ant.taskdefs.management.WLDeploy',
classpath:configurations.weblogic.asPath)
ant.wldeploy(action:'deploy',
source:"$war",
name:"${project.name}",
adminurl:"t3://localhost:7010",
user:'weblogic',
password:'weblogic',
upload:"true",
targets:"carfax",
verbose:'true',
debug:'false')
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment