从官方目录启动 magnolia 的项目原型

Start magnolia's project archetype from official catalog

场景一

我正在按照 official documentation 中描述的步骤进行操作,因此

问题是,无论我尝试使用默认上下文根 (xyz-webapp),还是将其修改为 /,仍然 http://localhost:8080/ 给出 404 错误,但在文档之后我应该进入安装页面。我做错了什么?


我正在使用

找到这个旧的但 official screencast 正是我想要的。在第一个场景中,出现在问题中,我从 Eclipse 添加了 maven 原型模块。现在我跟着视频,所以我只使用 mvn 来设置项目:

  • mvn org.apache.maven.plugins:maven-archetype-plugin:2.4:generate -DarchetypeCatalog=https://nexus.magnolia-cms.com/content/groups/public/
  • cd 到基本目录
  • mvn 全新安装
  • cd 到 webapp 目录
  • mvn war:inplace
  • 删除xyz-webapp\src\main\webapp\WEB-INF\lib

现在将其导入 Eclipse 后,有一些问题需要解决

  • error unpacking magnolia-empty-webapp-5.6.war 我尝试 运行 maven 更新几次,不确定这是否解决了问题,但我不再明白了。
  • groupId 之类的警告在父级中定义,在模块中不需要它,因此将其删除。
  • 来自 jackrabit-*.xml 文件 "Referenced files contains errors" 的
  • xml 错误。我不知道如何解决这些,保持原样。
  • 文件无法验证为 XML 定义 "...\templateModule\src\main\resources\META-INF\magnolia\module.dtd (The system cannot find the file specified)" that is specified as describing the syntax of the file cannot be located. templateModule.xml /templateModule/src/main/resources/META-INF/magnolia line 2 XML Problem
    • 第 2 行:<!DOCTYPE module SYSTEM "module.dtd" >
  • 当 运行现在连接服务器时,我至少得到一个错误:
    • ERROR info.magnolia.init.MagnoliaServletContextListener : Oops, Magnolia could not be started info.magnolia.module.model.reader.ModuleDependencyException: The following exceptions were found while checking Magnolia modules dependencies (i.e. those in META-INF/magnolia/my-module.xml): Module Magnolia Admincentral (version 5.6.0) is dependent on imaging (version 3.4/*), which was not found.
    • 所以我在/templateModule/pom.xml
    • 中添加了依赖magnolia-imaging

现在它按预期启动了。