简体   繁体   English

如何将Jenkins作业从Windows本地计算机迁移到Linux服务器?

[英]How to migrate Jenkins job from windows local machine to Linux server?

我在本地计算机(Windows)中安装了Jenkins,并使用Jenkins创建了一个新作业,它的工作原理非常完美...现在,我在一个专用的Linux Server中安装了Jenkins ...如何从Windows(本地计算机)迁移作业到Linux服务器上新安装的Jenkins?

The safest solution is to use the Job Import plugin . 最安全的解决方案是使用Job Import插件

Install this plugin on the Linux server, and next import the job from the Windows Jenkins URL :) 在Linux服务器上安装此插件,然后从Windows Jenkins URL导入作业:)

You can also check in your Job's configs with some smart .gitignore (or whatever your choice of SCM is) and use the %JENKINS_HOME% as a checked in and versioned directory in the SCM of your choice. 您还可以使用一些智能.gitignore(或任何您选择的SCM)检入Job的配置,并将%JENKINS_HOME%用作所选SCM中的签入目录和版本控制目录。

Job config's are OS independent, though the job itself might have OS specific scripts (if you use a shell script instead of a mvn pom file / ant build.xml). 作业配置是与操作系统无关的,尽管作业本身可能具有特定于操作系统的脚本(如果您使用Shell脚本而不是mvn pom文件/ ant build.xml)。

Then you can just check out your checked in job repo to the new linux host's $jenkins_home directory and start up jenkins. 然后,您只需将签入的作业仓库签出到新的Linux主机的$ jenkins_home目录中,然后启动jenkins。 all your jobs should be found and added to your linux jenkins (with out the need for a plugin). 您应该找到所有工作并将其添加到您的linux jenkins中(无需插件)。

Generally speaking... the less plugins, the more stable your Jenkins install will be. 一般来说,插件越少,您的Jenkins安装就越稳定。

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

相关问题 将文件夹从服务器(Linux)复制到python中的本地计算机(windows) - Copy folder from server(Linux) to local machine(windows) in python 将Linux服务器迁移到Windows - Migrate Linux server to Windows 从Linux服务器到Windows服务器的Jenkins部署 - Jenkins deployment from linux server to windows server 如何通过本地网络从Windows机器向Linux机器发送文件? - How to send file over local network from a windows machine to a linux machine? 如何从本地计算机[windows 7]运行和恢复远程计算机[linux]中的Eclipse - How to run and restore Eclipse which in remote machine [linux] from a local machine [windows 7] 从 Linux 服务器到 Windows 机器的 RSYSLOG - RSYSLOG from Linux server to Windows machine 在Linux上的Jenkins中测试失败,并且在Windows本地计算机上的Jenkins中运行良好? - Tests are got failed in Jenkins on Linux and works good at Jenkins on windows local machine? 无法从Jenkins Windows框中添加Linux从机 - Unable to add Linux slave machine from Jenkins windows box 如何将远程Windows上的文件复制到Linux计算机上的本地Linux? - How to copy files on remote Windows to local Linux on a Linux machine? 如何在无头远程 Linux 服务器上运行应用程序并查看本地 Windows 机器上的 UI - How to run an application on headless remote Linux server and see the UI on my local Windows machine
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM