简体   繁体   English

在 Azure Devops 中发布到内部提要

[英]Publish to internal feed in Azure Devops

We are migrating to Azure devops environment and have a problem.我们正在迁移到 Azure devops 环境,遇到问题。 In our old environment, we used a Jenkins server to automate a release procedure ran a gradle maven deploy plugin script using following info: groupId example: "com.foo" artifactId example: "Hello" artifact: example: 'jar' feed url example: 'https://pkgs.dev.azure.com/......maven/v1' password:... , and the binaries then landed on a JFrog Artifactory server.在我们的旧环境中,我们使用 Jenkins 服务器来自动执行发布过程 gradle maven 使用以下信息部署插件脚本: groupId 示例:“com.foo” artifactId 示例:“Hello” artifact:示例:'jar' feed url 示例: 'https://pkgs.dev.azure.com/......maven/v1' password:... ,然后二进制文件登陆了 JFrog Artifactory 服务器。

Now in Azure devops, we can't figure out how to publish the artifacts to an Artifact feed using any of its standard tasks.现在在 Azure devops 中,我们无法弄清楚如何使用其任何标准任务将工件发布到工件提要。 I have been looking at the universal packges tasks, and on the Maven@3, but none of them seems to provide the correct parameters.我一直在查看通用 packges 任务和 Maven@3,但它们似乎都没有提供正确的参数。

More over, we are not sure of we should use the Release pipelines or "normal" pipelines.此外,我们不确定我们应该使用发布管道还是“正常”管道。 Can any Azure Devops whiz give some advice here?任何 Azure Devops 高手都可以在这里提供一些建议吗?

If you are building in Azure pipelines and publishing to Azure Articat feed then there are tasks to build and publish your maven module.如果您正在构建 Azure 管道并发布到 Azure Articat 提要,那么有一些任务可以构建和发布您的 maven 模块。

https://learn.microsoft.com/en-us/azure/devops/pipelines/artifacts/publish-maven-artifacts?view=azure-devops https://learn.microsoft.com/en-us/azure/devops/pipelines/artifacts/publish-maven-artifacts?view=azure-devops

You do not need to explicitly set the password as auth is all done inside devops.你不需要显式设置密码,因为 auth 都是在 devops 内部完成的。 You must set this up as set out in the guide .您必须按照指南中的说明进行设置。

The second part of the question.问题的第二部分。 Pipelines (written in YAML) and Classic Release Pipelines (UI Driven) both can build, test and deploy an application.管道(用 YAML 编写)和经典发布管道(UI 驱动)都可以构建、测试和部署应用程序。 The move seems to be towards Pipelines written in YAML with most new features being added to this system.此举似乎是针对 YAML 中编写的管道,其中添加了大多数新功能到该系统。

You want to take a local artifact and put it on the feed, but you cannot use local artifact and put it on the feed.您想要获取本地工件并将其放在提要上,但您不能使用本地工件并将其放在提要上。

If you use Maven, you can use mvn deploy --settings c:\user\user-settings.xml to put it on the Artifacts with the settings,xml & pom.xml config.如果你使用 Maven,你可以使用mvn deploy --settings c:\user\user-settings.xml将它放在 Artifacts 上,设置为 xml & pom.xml 配置。 You cannot ignore the settings.xml step since it match the password & account with the feed of Artifacts.您不能忽略 settings.xml 步骤,因为它会将密码和帐户与 Artifacts 的提要相匹配。

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

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