Reputation: 316
I'm looking to configure Jenkins JDK installations programmatically, either through the CLI or by writing XML files.
I know I can amend the config.xml file (main one) to include JDK installations but I'd prefer to have it configured in a separate file. (e.g hudson.tasks.Ant.xml)
How to achieve this?
Upvotes: 4
Views: 445
Reputation: 11159
I've managed to do it :) Just call this: jenkins.model.Jenkins.getInstance().getJDKs().add(new hudson.model.JDK("id", "path"))
Upvotes: 5