I am using jenkins 2.141 but I have had this problem since at least jenkins 2.122
I can create and delete jobs using the java cli
For example
java -jar $HOME/bin/jenkins-cli.jar -user $LOGNAME -ssh -s
http://jenkins/hnd create-job foo < foo/config.xml
java -jar $HOME/bin/jenkins-cli.jar -user $LOGNAME -ssh -s
http://jenkins/hnd delete-job foo
But attempts to use
java -jar $HOME/bin/jenkins-cli.jar -user eb888198 -ssh -s
http://jenkins/hnd enable-job foo
Nov 15, 2018 12:45:22 PM org.apache.sshd.client.config.hosts.ConfigFileHostEntryResolver reloadHostConfigEntries
INFO: resolveEffectiveResolver($LOGNAME@jenkins:45259) loaded 1 entries from $HOME/.ssh/config
ERROR: object is not an instance of declaring class
I can do this successfully on other Jenkins instances but not this one, which implies some sort of configuration issue.
There aren't any error messages in the logs when I run the commands
--
Eric Boehm
Broadcom