如何在Jenkins中更改JAR构建路径?

编程入门 行业动态 更新时间:2024-10-15 14:13:28
本文介绍了如何在Jenkins中更改JAR构建路径?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我正在通过Jenkins构建一个Java项目. (在我在Jenkins中执行maven全新安装之后)在C:\ Windows \ System32 \ config \ systemprofile.m2 \ repository \ com \ other文件夹中创建JAR.

I am building a Java project via Jenkins. The JAR is being created (after I execute maven clean install in Jenkins) in C:\Windows\System32\config\systemprofile.m2\repository\com\other folders.

有什么办法可以改变这条路吗?我想通过SSH将JAR发送到VM.但是,由于这是系统目录,因此无法访问该文件夹.

Is there any way to change this path? I want to sent the JAR to a VM via SSH. However, I am not able to access this folder since this is system directory.

谢谢.

推荐答案

由于某种原因,您的Jenkins使用此目录作为本地Maven存储库.我将在Jenkins或settings.xml中定义一个不同的本地存储库.同样重要的是,要确保没有两个正在运行的内部版本同时使用同一本地存储库,因为不能同时使用本地存储库.

For some reason, your Jenkins uses this directory as local Maven repository. I would define a different local repository in Jenkins or in the settings.xml. It is also important that you make sure that no two running builds use the same local repository at the same time because local repositories cannot be used concurrently.

更多推荐

如何在Jenkins中更改JAR构建路径?

本文发布于:2023-11-24 12:44:37,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1625251.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:路径   如何在   Jenkins   JAR

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!