【发布时间】:2018-09-28 13:52:48
【问题描述】:
我正在使用 VSTS 和 Maven 构建模板为 java api 配置构建管道。如何配置特定于环境的配置(即 Dev、QA、Staging... app.properties)。
谢谢 吉里什
【问题讨论】:
标签: maven azure-devops azure-pipelines azure-pipelines-release-pipeline azure-pipelines-build-task
我正在使用 VSTS 和 Maven 构建模板为 java api 配置构建管道。如何配置特定于环境的配置(即 Dev、QA、Staging... app.properties)。
谢谢 吉里什
【问题讨论】:
标签: maven azure-devops azure-pipelines azure-pipelines-release-pipeline azure-pipelines-build-task
您可以使用profiles 来构建和打包为特定环境配置的工件。详情请见Building For Different Environments with Maven 2。
创建构建定义后,我们将配置 Maven 任务以提供pom.xml 的路径,以便构建定义可以使用pom.xml,来编译源代码并创建一个包文件。
详情请参考Configuration of continuous build integration in VSTS。
另一个类似的帖子供您参考:Using Maven for multiple deployment environment (production/development)
【讨论】: