Quantcast
Viewing all articles
Browse latest Browse all 14

Comment by Michael Mol on Jenkins Pipeline - Clean before checkout - git clean -fdx "failed to remove: Directory not empty"

I've had this happen when doing non-containerized Habitat package builds. In my case, the habitat studio aborted a build, but hadn't unmounted its bind mounts of, e g. /dev, /proc and friends. I discovered the hard way that a sledgehammer rm -rf was a quick way to trash the node. My solution was twofold: first, mount /var/lib/jenkins as tmpfs (so rebooting could cleanly fix the problem on a per-incident basis), and, later, switch to fully-containerized builds to ensure proper cleanup.

Viewing all articles
Browse latest Browse all 14

Trending Articles