首页 > 系统相关 >windows作为jenkins slave使用问题

windows作为jenkins slave使用问题

时间:2024-01-16 10:22:22浏览次数:32  
标签:slave cygdrive windows agent will path jenkins

 

1、windows agent 添加

1.1 ssh方式添加管理agent

安装cygwin 环境

参考 https://github.com/jenkinsci/ssh-agents-plugin/blob/main/doc/CYGWIN.md

下载安装程序

安装openssh,注意要选择版本,否则策略是跳过,倒三角图标处选择版本

下一步

 

安装cygrunsrv

 

 配置ssh

启动cygssh进程

 

Check that your firewall allow TCP port 22

Java must be available from your SSH client: for example, add a symbolic link, e.g :  cd /usr/local/bin && ln -s /cygdrive/c/Program\\ Files\\(x86\\)/Java/jre1.8.0\_211/bin/java.exe java

When you use SSH launcher to launch an agent on Cygwin-enabled Windows, you should still specify Windows style path as the remote FS root (such as c:\jenkins). This is because the agent JVM that eventually gets launched doesn't receive the Cygwin path translation. If you specify Unix style path (such as /cygdrive/c/jenkins), then Jenkins will end up trying to create both c:\jenkins (when it copies over agent.jar via SFTP) and c:\cygdrive\c\jenkins (when agent JVM actually starts and copy more files.)

If you run Jenkins on behalf of other users, you'll discover that some of your users will not understand when and where the path translation happens, and will inevitably write build scripts that break. You can explain to them what's going on, or you can surrender and use mklink to create a symlink or junction point that maps c:\cygdrive\c\jenkins to c:\jenkins. This will make those broken scripts work happily.

 

jenkins  master配置

注意路径要是windows格式反斜杠

 

账户密码就是windows的原有账户密码

 

 

 

 

 

 

 

2、Git出现“filename too long”错误处理

GIt使用了旧版本的Windows API,导致它限制文件名不能超过260个字符。所以Git的Windows客户端默认是禁用长名称支持的。我们开启长名称支持即可。

打开PowerShell或者Cmd,在命令行窗口中运行:

git config --system core.longpaths true

标签:slave,cygdrive,windows,agent,will,path,jenkins
From: https://www.cnblogs.com/fanggege/p/17967049

相关文章

  • 一、windows安装opencv,并使用pycharm开发
    OpenCV入门毕设需要用到人脸识别,利用寒假学习下opencv的基本操作,希望可以有所收获安装python环境官网,下载安装exe文件,运行后选择添加path,安装成功结果如下:安装pycharm下载地址安装opencv命令行下运行:pipinstallopencv-python成功安装结果如下:无任何报错即为安装成功......
  • windows下直接把文件夹打包成war包
    windows下直接把文件夹打包成war包在windows中把一个文件夹打成war包一般开发打war包时都是用MyEclipse或IntelliJIDEA等直接导出war文件,这里介绍一种如何把一个文件夹打成war包的方式,如下例如要打包的文件在D:\testWar打开cmd命令行窗口,进入文件所在目录D:\testWar然......
  • SecureCRT & SecureFX 9.5 for macOS, Linux, Windows
    SecureCRT&SecureFX9.5formacOS,Linux,Windows-跨平台的多协议终端仿真和文件传输请访问原文链接:SecureCRT&SecureFX9.5formacOS,Linux,Windows,查看最新版。原创作品,转载请保留出处。作者主页:sysin.orgSecureCRT客户端运行于Windows、Mac和Linux,将坚如磐......
  • Acunetix v24.1 (Linux, Windows) - 漏洞扫描 (Web 应用程序安全测试)
    Acunetixv24.1(Linux,Windows)-漏洞扫描(Web应用程序安全测试)Acunetix|WebApplicationSecurityScanner请访问原文链接:https://sysin.org/blog/acunetix/,查看最新版。原创作品,转载请保留出处。作者主页:sysin.org重要提示AcunetixPremium现在使用日历化版本命......
  • Windows OhmGraphite 配置
    WindowsOhmGraphite配置由于windows_exporter无法监控温度相关的指标,那么就需要使用OhmGraphite进行监控该指标。下载访问https://github.com/nickbabcock/OhmGraphite/releases/地址进行下载最新的版本,下载后解压到你自己放的目录修改配置编辑OhmGraphite.exe.config文......
  • windows_exporter 安装
    windows_exporter安装背景如果想使用Prometheus监控Windows主机相关参数,那么就需要在Windows系统的主机上进行安装指标收集器。windows_exporter是Prometheus官方所提供的指标收集器。下载https://github.com/prometheus-community/windows_exporter/releases访问此地址......
  • WindowsServer 2019安装域服务
    WindowsServer2019安装域服务导航目录WindowsServer2019安装域服务导航一、重命名主控服务器固定IP地址重命名域控服务器二、登录并创建服务三、检验安装域服务一、重命名主控服务器固定IP地址右击电脑右下角网络的标志,点击打开“网络和internet”设置,在屏幕中间的......
  • windows映射网络驱动器,如何更换用户名?
    由于我的两台电脑用户名一样,所以直接不用做任何修改,用自己这台电脑的默认用户名就行。但是我为了安全,我想新建一个专门用来远程访问的普通用户,可是我发现无论如何都连不上,今天终于解决了,记录一下。首先,本地电脑在windows凭据管理器中删除windows凭据,然后在注册表中搜索远程IP,把......
  • hackthebox outdated windows medium
    CONNECTbetweenwindowsandlinuxBloodhoundCollectionGrabthelatestcopyofSharpHound.exefromtheBloodhoundrepo,uploadittoOutdated,workingoutofC:\programdataiwrhttp://10.10.14.5:8888/SharpHound.exe-outfiles.exe.\s.exe-Call2022-0......
  • Windows实现多用户同时远程连接
    效果以下的步骤Win10和Win11是一样的,只需要在被控端设置,连接的电脑无需设置。添加用户设置-》家庭与其他用户-》将其他人添加到这台电脑-》我没有这个人的登录信息也可以使用Win键+R然后输入Lusrmgr.msc或者controluserpasswords2来添加新用户,这里就不赘述了。给用户添......