Java 8 agent on k8s with Java 11 controller



Have you ever met a leader who successfully runs a dynamic pod (jdk8) with Jenkins, a higher version jdk11 or 17 deployed on k8s? Request Docker Agent’s Dockerfile, thank you

That is not expected to work and is not supported, based on the requirement that Jenkins agents and the Jenkins controller must run the same Java version. The Jenkins controller sends Java class files from the controller to the agent for execution. If the controller is running Java 11 then it will send Java 11 classes to the agent. A Java 8 agent cannot run Java 11 classes.


All agents must be running on the same JVM version as the controller due to how controllers and agents communicate. If you’re upgrading your Jenkins controller to run on Java 11, you also need to upgrade the JVM on your agents.