removed jwt interface
This commit is contained in:
58
build.sbt
Normal file
58
build.sbt
Normal file
@@ -0,0 +1,58 @@
|
||||
name := "jpacrepo"
|
||||
|
||||
organization := "com.oggio88"
|
||||
|
||||
version := "2.0"
|
||||
|
||||
resolvers += Resolver.mavenLocal
|
||||
scalaVersion := "2.12.2"
|
||||
|
||||
libraryDependencies += "org.tukaani" % "xz" % "1.6"
|
||||
libraryDependencies += "org.apache.commons" % "commons-compress" % "1.14"
|
||||
libraryDependencies += "org.projectlombok" % "lombok" % "1.16.18" % "provided"
|
||||
//libraryDependencies += "javax" % "javaee-api" % "7.0" % "provided"
|
||||
libraryDependencies += "javax" % "javaee-api" % "7.0"
|
||||
|
||||
libraryDependencies += "junit" % "junit" % "4.12" % "test"
|
||||
libraryDependencies += "com.novocode" % "junit-interface" % "0.11" % "test"
|
||||
libraryDependencies += "com.thoughtworks.xstream" % "xstream" % "1.4.10"
|
||||
libraryDependencies += "commons-io" % "commons-io" % "2.5" % "test"
|
||||
|
||||
//libraryDependencies += "org.jboss.resteasy" % "resteasy-jaxrs" % "3.1.3.Final" % "test"
|
||||
//libraryDependencies += "org.jboss.resteasy" % "resteasy-client" % "3.1.3.Final"
|
||||
//libraryDependencies += "org.jboss.resteasy" % "resteasy-jackson-provider" % "3.1.3.Final" % "test"
|
||||
//libraryDependencies += "com.fasterxml.jackson.core" % "jackson-core" % "2.9.0.pr4"
|
||||
|
||||
//libraryDependencies += "org.jboss.resteasy" % "resteasy-jaxb-provider" % "3.1.3.Final" % "test"
|
||||
//libraryDependencies += "org.jboss.spec.javax.servlet" % "jboss-servlet-api_3.1_spec" % "1.0.0.Final" % "provided"
|
||||
//libraryDependencies += "org.jboss.spec.javax.ws.rs" % "jboss-jaxrs-api_2.0_spec" % "1.0.0.Final"
|
||||
|
||||
libraryDependencies += "org.jboss.resteasy" % "resteasy-jaxrs" % "3.0.11.Final"
|
||||
libraryDependencies += "org.jboss.resteasy" % "resteasy-client" % "3.0.11.Final"
|
||||
libraryDependencies += "org.jboss.resteasy" % "resteasy-jackson-provider" % "3.0.11.Final"
|
||||
libraryDependencies += "org.jboss.resteasy" % "resteasy-jaxb-provider" % "3.0.11.Final"
|
||||
|
||||
enablePlugins(WarPlugin)
|
||||
|
||||
val wildflyUsername = SettingKey[String]("wildfly-username", "The account username to use to connect to wildfly with jboss-cli.sh")
|
||||
val wildflyPassword = SettingKey[String]("wildfly-password", "The account password to use to connect to wildfly with jboss-cli.sh")
|
||||
val wildflyURL = SettingKey[String]("wildfly-url", "The username to use to connect to wildfly with jboss-cli.sh")
|
||||
|
||||
wildflyUsername := "admin"
|
||||
wildflyPassword := "123456"
|
||||
wildflyURL := "localhost:9990"
|
||||
|
||||
val deploy2Wildfly = TaskKey[Unit]("deploy2Wildfly", "Deploy to a wildfly server instance", KeyRanks.ATask)
|
||||
|
||||
deploy2Wildfly <<= (packagedArtifact in(Compile, Keys.`package`), wildflyURL, wildflyUsername, wildflyPassword) map
|
||||
{
|
||||
case ((art: Artifact, warFile: File), url: String, username: String, password: String) =>
|
||||
//val warFile = (artifactPath in Keys.`package` in Compile).value//(artifactPath in `package`).value.absolutePath //(packageBin in Compile).value //(artifactPath in (Compile, package)).value
|
||||
val cmd = s"/opt/wildfly/bin/jboss-cli.sh --controller='${url}' --connect --user='${username}' --password='${password}' --command=\'deploy ${warFile.absolutePath} --force\'"
|
||||
println(cmd)
|
||||
sys.process.stringToProcess(cmd).! match
|
||||
{
|
||||
case 0 => "OK"
|
||||
case _ => throw new RuntimeException("Error occurred during deploy")
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user