简体   繁体   English

Java Maven存储库settings.xml

[英]Java Maven repository settings.xml

I successfully added a private repository to my pom.xml with credentials in settings.xml and locally the build works fine (with a cleared cache - just to be sure). 我使用settings.xml凭据成功地将私有存储库添加到pom.xml ,并且本地构建正常(使用已清除的缓存-可以肯定)。

But how would I pass the settings.xml entries to cctrlapp APP_NAME/dev push ? 但是,如何将settings.xml条目传递给cctrlapp APP_NAME/dev push

The build fails due to failing authentication against the private repository (Bitbucket in this case): the downloads contain a 401 resonse HTML "Please log in". 由于针对私有存储库(在这种情况下为Bitbucket)的身份验证失败,因此构建失败:下载内容包含401共振HTML“请登录”。

I investigated for the system.properties as well as the log 我调查了system.properties和日志

-----> executing /srv/tmp/buildpack-cache/.maven/bin/mvn -B 
-Duser.home=/srv/tmp/builddir 
-Dmaven.repo.local=/srv/tmp/buildpack-cache/.m2/repository 
-s /srv/tmp/buildpack-cache/.m2/settings.xml 
-DskipTests=true clean install

which does not seem an option for overriding. 这似乎不是覆盖的选择。

Thank you very much in advance. 提前非常感谢您。

We provide the public key specific to your app in the application details. 我们在应用程序详细信息中提供了特定于您应用程序的公钥。 By adding this to Bitbucket (or any repository service supporting access via SSH) and specifying SSH when accessing the private repository the platform will be able to authenticate using the private key. 通过将其添加到Bitbucket(或支持通过SSH访问的任何存储库服务)并在访问私有存储库时指定SSH,平台将能够使用私有密钥进行身份验证。

$ cctrlapp APP_NAME details # will show the public key

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM