mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-26 21:17:23 +00:00
Merge pull request #3991 from zmerlynn/hermetic_jenkins_build
Clean out dead docker containers and docker images every Jenkins build
This commit is contained in:
commit
acbadc8ade
@ -34,16 +34,15 @@ export PATH=$PATH:/usr/local/go/bin
|
|||||||
export KUBE_RELEASE_RUN_TESTS=n
|
export KUBE_RELEASE_RUN_TESTS=n
|
||||||
export KUBE_SKIP_CONFIRMATIONS=y
|
export KUBE_SKIP_CONFIRMATIONS=y
|
||||||
|
|
||||||
# Clean stuff out.
|
# Clean stuff out. Assume the worst - the last build may have left the
|
||||||
#
|
# tree in an odd state. There's a Jenkins git clean plugin, but we
|
||||||
# TODO: Look at git clean plugin again for hermeticism, but may not
|
# have the docker images to worry about as well, so be really pedantic
|
||||||
# play nicely with dockerized stuff and permissions. (We may just need
|
# about cleaning.
|
||||||
# to force the build/make-clean.sh at the end of the build regardless
|
|
||||||
# of status and be delicate with the exit status.) (Low priority
|
|
||||||
# unless there's a hermetic issue.)
|
|
||||||
rm -rf ~/.kube*
|
rm -rf ~/.kube*
|
||||||
./build/make-clean.sh
|
make clean
|
||||||
git clean -fdx
|
git clean -fdx
|
||||||
|
docker ps -aq | xargs -r docker rm
|
||||||
|
docker images -q | xargs -r docker rmi
|
||||||
|
|
||||||
# Build
|
# Build
|
||||||
go run ./hack/e2e.go -v --build
|
go run ./hack/e2e.go -v --build
|
||||||
|
Loading…
Reference in New Issue
Block a user