Skip to content

Commit

Permalink
hotfix(Jenkinsfile) collect azcopy log in the job when deployment fails
Browse files Browse the repository at this point in the history
  • Loading branch information
dduportal authored Sep 14, 2024
1 parent 936d4fd commit 3e087e0
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,16 @@ pipeline {
}
}
}
post {
failure {
// Only collect azcopy log when the deployment fails, because it is an heavy one
sh '''
# Retrieve azcopy logs to archive them
cat /home/jenkins/.azcopy/*.log > azcopy.log
'''
archiveArtifacts 'azcopy.log'
}
}
}
}
}

0 comments on commit 3e087e0

Please sign in to comment.