当我的办公室网络限制在通过Vault构建时访问Adobe CRX packmgr时,我在构建项目时遇到了此问题。
The error message were as below:
[WARNING] Required proxy credentials not available for BASIC <any realm>@10.XX3.X0.XX:XXXX
[WARNING] Preemptive authentication requested but no default proxy credentials available
[ERROR] Request to http://localhost:4502/crx/packmgr/service.jsp failed, response=Forbidden
And the Build was failed.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 8.221 s
[INFO] Finished at: 2017-06-22T16:01:01+05:30
[INFO] Final Memory: 36M/459M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.day.jcr.vault:content-package-maven-plugin:0.0.24:install (install-package) on project XXXbas.ui.apps: Error while installing package. Check log for details. -> [Help 1]
答案 0 :(得分:3)
我通过在父pom.xml中添加一个简单配置解决了这个问题:
<useProxy>false</useProxy>
以下是代码:
<!-- Content Package Plugin -->
<plugin>
<groupId>com.day.jcr.vault</groupId>
<artifactId>content-package-maven-plugin</artifactId>
<version>0.0.24</version>
<configuration>
<targetURL>http://${aem.host}:${aem.port}/crx/packmgr/service.jsp</targetURL>
<failOnError>true</failOnError>
<failOnMissingEmbed>true</failOnMissingEmbed>
<useProxy>false</useProxy>
</configuration>
</plugin>
答案 1 :(得分:0)
对我来说,我创建了第二个 aem 实例,我将密码从 admin 更改为其他密码。因此,我还需要在我的根项目的 pom.xml 文件中更改密码。
<properties>
<aem.host>localhost</aem.host>
<aem.port>4502</aem.port>
<aem.publish.host>localhost</aem.publish.host>
<aem.publish.port>4503</aem.publish.port>
<sling.user>admin</sling.user>
<sling.password>admin</sling.password>
<vault.user>*add_your_password*</vault.user>
<vault.password>**ADD_YOUR_PASSWORD_HERE**</vault.password>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
</properties>
如您所见,ADD_YOUR_PASSWORD_HERE 是您应该使用给定实例密码更改密码的地方。
这对我有用。希望它也适用于您...