简体   繁体   English

如何在 Azure 管道 Microsoft 托管代理上升级 java 版本?

[英]How to upgrade java version on an Azure pipeline Microsoft-hosted agent?

I am setting up an Azure DevOps pipeline and I am running a jar (in one of the pipeline tasks) that needs a higher version of java than the one installed on the Microsoft-hosted agent used by the pipeline.我正在设置一个 Azure DevOps 管道,我正在运行一个 jar(在其中一个管道任务中),它需要比安装在管道使用的 Microsoft 托管代理上的更高版本的 java。 How can I update the java version on the agent and ensure that this job (the one that requires a high java version) gets executed on this agent?如何更新代理上的 java 版本并确保此作业(需要高 java 版本的作业)在此代理上执行?

If you need a certain runtime or runtime version you need you can either use one of the provided "* Installer"-Tasks by microsoft or write some powershell that installs stuff for you but the main thing is that you set this up as part of the pipeline.如果您需要某个运行时或运行时版本,您可以使用微软提供的“*安装程序”-Tasks 之一,或者编写一些 powershell 来为您安装东西,但主要的是您将其设置为管道。

You need the task "Java Tool installer" as one of the first steps in your pipeline.您需要将任务“Java 工具安装程序”作为管道中的第一步。 Reference -> https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/tool/java-tool-installer?view=azure-devops参考 -> https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/tool/java-tool-installer?view=azure-devops

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

相关问题 如何使用Java命令行应用程序对https://tfspreview.com(MIcrosoft托管的TFS)进行身份验证? - How to authenticate to https://tfspreview.com (MIcrosoft-hosted TFS) using Java command line application? Azure 用于 Java 项目的 DevOps 管道,带有自托管代理 - Azure DevOps Pipeline for Java Project with self hosted agent 如何在 Azure 管道 Ubuntu 代理上安装 java 13 并在 Maven 构建期间使用它? - How to install java 13 on Azure-pipeline Ubuntu agent and use it during Maven build? 如何在不下载的情况下在 Azure Devops Agent 中使用特定版本的 Java? - How to you use a specific version of Java in Azure Devops Agent without downloading? 如何评估Java版本升级的风险? - How to assess the risk of a java version upgrade? 如何在Linux中升级当前项目的Java版本? - how to Upgrade Java version of current project in linux? 如何在 Azure DevOps 管道中安装 Java? - How to install Java in an Azure DevOps pipeline? Azure Devops 管道:访问 xml 文件中的代理 JAVA_HOME 变量 - Azure Devops Pipeline : Accessing agent JAVA_HOME variable in xml file 如何使用Java配置与Azure托管的MySQL的SSL连接? - How to configure SSL connection to MySQL hosted on Azure with Java? 得到差异。 Azure托管代理上的chrome驱动程序错误 - Getting diff. error for chrome driver on azure hosted agent
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM