1

start-rpm-template 不适用于 SLES 11 SP3 。

原因:Init.d/functions 不可用

# Source function library.

. /etc/rc.d/init.d/functions

在 SLES 上,功能在这里:

/lib/lsb/init-functions

项目如何提供自己的 Archetype 模板?

4

1 回答 1

1

src/main/scala/com/typesafe/sbt/packager/linux/Keys

val linuxMakeStartScript = TaskKey[Option[File]]("makeStartScript", "Creates or discovers the start script used by this project")
val linuxStartScriptTemplate = TaskKey[URL]("linuxStartScriptTemplate", "The location of the template start script file we use for debian (upstart or init.d")
val linuxEtcDefaultTemplate = TaskKey[URL]("linuxEtcDefaultTemplate", "The location of the /etc/default/<pkg> template script.")
val linuxJavaAppStartScriptBuilder = SettingKey[JavaAppStartScriptBuilder]("linuxJavaAppStartScriptBuilder", "Responsible for loading the start scripts. Only used with archetype.java_server")
val linuxScriptReplacements = SettingKey[Seq[(String, String)]]("linuxScriptReplacements",
  """|Replacements of template parameters used in linux scripts.
       |  Default supported templates:
       |  execScript - name of the script in /usr/bin
       |  author - author of this project
       |  descr - short description
       |  chdir - execution path of the script
       |  retries - on fail, how often should a restart be tried
       |  retryTimeout - pause between retries
       |  appName - name of application
       |  appClasspath - application classpath
       |  appMainClass - main class to start
       |  daemonUser - daemon user
    """.stripMargin)

我会使用linuxMakeStartScriptorlinuxStartScriptTemplatelinuxScriptReplacements

于 2014-05-04T09:21:44.013 回答