在Heroku上部署Play Scala应用程序

时间:2012-03-28 21:00:15

标签: java scala heroku

我有一个用Play和Scala编写的示例应用程序与Amazon DynamoDB交谈,我正在尝试将其部署到Heroku上。 Heroku只有部署Play应用程序或Scala应用程序的说明,但不能同时部署两者。我试图合并两者的说明,但是很短。我看到了这个错误,

  [info] Compiling 1 Scala source to /tmp/build_1q6humfwtqitn/.sbt_home/.sbt/plugins/target/scala-2.9.1/sbt-0.11.2/classes...
   [info] Loading project definition from /tmp/build_1q6humfwtqitn/project
   [warn]   module not found: com.typesafe.startscript#xsbt-start-script-plugin;0.3.0
   [warn] ==== typesafe-ivy-releases: tried
   [warn]   http://repo.typesafe.com/typesafe/ivy-releases/com.typesafe.startscript/xsbt-start-script-plugin/scala_2.9.1/sbt_0.11.2/0.3.0/ivys/ivy.xml
   [warn] ==== local: tried
   [warn]   /tmp/build_1q6humfwtqitn/.sbt_home/.ivy2/local/com.typesafe.startscript/xsbt-start-script-plugin/scala_2.9.1/sbt_0.11.2/0.3.0/ivys/ivy.xml
   [warn] ==== typesafe-ivy-releases: tried
   [warn]   http://repo.typesafe.com/typesafe/ivy-releases/com.typesafe.startscript/xsbt-start-script-plugin/scala_2.9.1/sbt_0.11.2/0.3.0/ivys/ivy.xml
   [warn] ==== heroku-sbt-typesafe: tried
   [warn] ==== heroku-central: tried
   [warn]   http://s3pository.heroku.com/maven-central/com/typesafe/startscript/xsbt-start-script-plugin_2.9.1_0.11.2/0.3.0/xsbt-start-script-plugin-0.3.0.pom
   [warn] ==== heroku-scala-tools-releases: tried
   [warn]   http://s3pository.heroku.com/maven-scala-tools-releases/com/typesafe/startscript/xsbt-start-script-plugin_2.9.1_0.11.2/0.3.0/xsbt-start-script-plugin-0.3.0.pom
   [warn] ==== heroku-scala-tools-snapshots: tried
   [warn]   http://s3pository.heroku.com/maven-scala-tools-snapshots/com/typesafe/startscript/xsbt-start-script-plugin_2.9.1_0.11.2/0.3.0/xsbt-start-script-plugin-0.3.0.pom
   [warn] ==== heroku-sbt-typesafe: tried
   [warn] ==== heroku-central: tried
   [warn]   http://s3pository.heroku.com/maven-central/com/typesafe/startscript/xsbt-start-script-plugin_2.9.1_0.11.2/0.3.0/xsbt-start-script-plugin-0.3.0.pom
   [warn] ==== heroku-scala-tools-releases: tried
   [warn]   http://s3pository.heroku.com/maven-scala-tools-releases/com/typesafe/startscript/xsbt-start-script-plugin_2.9.1_0.11.2/0.3.0/xsbt-start-script-plugin-0.3.0.pom
   [warn] ==== heroku-scala-tools-snapshots: tried
   [warn]   http://s3pository.heroku.com/maven-scala-tools-snapshots/com/typesafe/startscript/xsbt-start-script-plugin_2.9.1_0.11.2/0.3.0/xsbt-start-script-plugin-0.3.0.pom
   [warn]   ::::::::::::::::::::::::::::::::::::::::::::::
   [warn]   ::          UNRESOLVED DEPENDENCIES         ::
   [warn]   ::::::::::::::::::::::::::::::::::::::::::::::
   [warn]   :: com.typesafe.startscript#xsbt-start-script-plugin;0.3.0: not found
   [warn]   ::::::::::::::::::::::::::::::::::::::::::::::
   [warn] 
   [warn]   Note: Some unresolved dependencies have extra attributes.  Check that these dependencies exist with the requested attributes.
   [warn]       com.typesafe.startscript:xsbt-start-script-plugin:0.3.0 (sbtVersion=0.11.2, scalaVersion=2.9.1)
   [warn] 
   [error] {file:/tmp/build_1q6humfwtqitn/project/}default-646eae/*:update: sbt.ResolveException: unresolved dependency: com.typesafe.startscript#xsbt-start-script-plugin;0.3.0: not found
   Project loading failed: (r)etry, (q)uit, (l)ast, or (i)gnore?  !     Failed to build app with SBT 0.11.0
   ! Heroku push rejected, failed to compile Scala app

另外,我是Java,Play和Scala的新手,但我熟悉在Heroku上部署Rails应用程序。

1 个答案:

答案 0 :(得分:2)

com.typesafe.startscript:xsbt-start-script-plugin:0.3.0的版本更改为0.5.0(您已指定此依赖项的位置)或编辑build.properties文件以设置sbt.version=0.11.0