I guess responsibility of scm-sync-configuration depends on the point of view: Meaning, if purpose is to have backup stored in a safe place, which can be restored after total disaster (for example disk failure, stolen hardware, fire ...) then list of installed plugins is needed. My experienses are that if you try to restore a xml files that have configuration of plugins not currently installed, Jenkins gets quite confused.

If the purpose is just to have SCM repository where old changes in working jenkins configuration can be fetched if needed, this plugin works just fine. And I am not intended to start a debate of the purpose of the plugin. After all it is great tool for my purposes already. So, I am just suggesting widening the scope of the plugin since I think that it could be done quite easily - However, since my java programming skills are severely limited , I might be mistaken on that one

Since I do lack java programming skills, developing plugin is out of my scope. However I do have done a Jenkins restore successfully with method that is more simple that your way of getting plugin list... Now I'm just wondering whether I had more simple plugins than you have had... So what information is lost with method described below:

Prerequisite are:

  • Jenkins installation, which have configuration backed up with scm-sync-configuration.
  • List of installed plugins is created with help of jenkins-cli and stripped to more simple list and included to backup:
    java -jar jenkins-cli.jar -s http://yourjenkinsurl:8080/ list-plugins > plugins.txt

awk '{print $1}' plugins.txt > plugins_tripped.txt

Output is a simple list which have simple list of plugin names.

The actual restoring config has these steps:

  • have new HW-platform with working OS for your jenkins
  • install fresh jenkins on top of that
  • Install all plugins from jenkins update site, use the plugins-list from backup:
    cat plugins_tripped.txt | xargs java -jar jenkins-cli.jar -s http://yourjenkinsurl:8080/ install-plugin

Shut down jenkins, do svn checkout (or GIT pull) to a temporary folder and copy everything to jenkins home folder, start jenkins and you should have working jenkins again up and running.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira

--
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Reply via email to