Jenkins plugins directory backup and restore

If you don't want to back up the plugin binary files, you can use the Jenkins REST API to get the list of current plugins:

http://jenkins:8080/pluginManager/api/json?tree=plugins[shortName,version]&pretty=true.

(You can use tree=plugins[*] to see a more complete list of fields in the API.)

Save this data as part of your configuration backup and use the Jenkins API to restore the plugins when you're re-deploying.

There's additional documentation and how to update plugins on the pluginManager API page: http://jenkins:8080/pluginManager/api

Tags:

Jenkins