fix exclusion of job config.xml in folders
This commit is contained in:
parent
c0d450a2c6
commit
b87c238a32
|
|
@ -41,11 +41,12 @@ trap '_trap' SIGQUIT SIGINT SIGTERM
|
|||
# config.xml in child directories is state that should. For example-
|
||||
# branches/myorg/branches/myrepo/branches/master/config.xml should be retained while
|
||||
# branches/myorg/config.xml should not
|
||||
ret=0
|
||||
tar --zstd -C "${JENKINS_HOME}" -cf "${BACKUP_TMP_DIR}/${BACKUP_NUMBER}.tar.zstd" \
|
||||
--exclude jobs/*/workspace* \
|
||||
--no-wildcards-match-slash --anchored \
|
||||
--exclude 'jobs/*/workspace*' \
|
||||
--no-wildcards-match-slash \
|
||||
--ignore-failed-read \
|
||||
--exclude jobs/*/config.xml -c jobs || ret=$?
|
||||
--exclude 'jobs/*/config.xml' -c jobs || ret=$?
|
||||
|
||||
if [[ "$ret" -eq 0 ]]; then
|
||||
_log "INFO" "[backup] backup ${BACKUP_NUMBER} was completed without warnings"
|
||||
|
|
|
|||
Loading…
Reference in New Issue