新建节点,需要填java路径,有java版本的错误
[08/10/18 17:03:05] [SSH] Starting sftp client. [08/10/18 17:03:05] [SSH] 正在拷贝最新版本的 slave.jar... [08/10/18 17:03:05] [SSH] Copied 771,547 bytes. Expanded the channel window size to 4MB [08/10/18 17:03:05] [SSH] Starting slave process: cd "/home/lzsj/workspace/xlz" && /usr/bin/java -jar slave.jar Exception in thread "main" java.lang.UnsupportedClassVersionError: hudson/remoting/Launcher : Unsupported major.minor version 52.0 at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:808) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:442) at java.net.URLClassLoader.access$100(URLClassLoader.java:64) at java.net.URLClassLoader$1.run(URLClassLoader.java:354) at java.net.URLClassLoader$1.run(URLClassLoader.java:348) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:347) at java.lang.ClassLoader.loadClass(ClassLoader.java:430) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:323) at java.lang.ClassLoader.loadClass(ClassLoader.java:363) at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:482) Slave JVM has terminated. Exit code=1 [08/10/18 17:03:05] Launch failed - cleaning up connection [08/10/18 17:03:05] [SSH] 连接关闭。
maven构建需要java环境,jenkins其实就是将编译运行部署的动作整合在一起代替人工按步骤操作,所以它需要知道各个工具和依赖的路径,个人理解,我也是花了三个小时才调通,理清了操作步骤理解起来能容易一些。