add image removal to container-clean
This commit is contained in:
parent
6ce35caa5f
commit
0ab86f3063
10
Makefile
10
Makefile
|
@ -242,7 +242,15 @@ clean: # @HELP removes built binaries and temporary files
|
||||||
clean: container-clean bin-clean
|
clean: container-clean bin-clean
|
||||||
|
|
||||||
container-clean:
|
container-clean:
|
||||||
rm -rf .container-* .dockerfile-*
|
@rm -rf .container-* .dockerfile-*; \
|
||||||
|
for bin in $(BINS); do \
|
||||||
|
docker image exists "$(REGISTRY)/$$bin:$(VERSION)" && \
|
||||||
|
docker image rm "$(REGISTRY)/$$bin:$(VERSION)"; \
|
||||||
|
for platform in $(ALL_PLATFORMS); do \
|
||||||
|
docker image exists "$(REGISTRY)/$$bin:$(VERSION)__$$(echo $$platform | sed 's#/#_#g')" && \
|
||||||
|
docker image rm "$(REGISTRY)/$$bin:$(VERSION)__$$(echo $$platform | sed 's#/#_#g')"; \
|
||||||
|
done \
|
||||||
|
done; true
|
||||||
|
|
||||||
bin-clean:
|
bin-clean:
|
||||||
rm -rf .go bin
|
rm -rf .go bin
|
||||||
|
|
Loading…
Reference in New Issue
Block a user