Skip to content

Instantly share code, notes, and snippets.

View swordfly's full-sized avatar

weizhuyu swordfly

  • Shanghai, China
View GitHub Profile
//
// This is a Jenkinsfile that backs up (parts of) Jenkins.
//
// So why not use the SCM-sync plugin? I've found it's just not configurable
// enough, and if something goes wrong it's a lot more opaque than this technique
// which uses standard shell and git commands.
//
// By default this approach covers users, credentials, and job and plugin configs,
// but not full builds/workspaces. Obviously you want to send this stuff only to
// a private repository! If you want to change the files that are included to