mirror of https://github.com/goharbor/harbor.git
build: add cleanbaseimage target in Makefile (#13777)
Add cleanbaseimage target in Makefile, and append it to the dependencies of the cleanall target. Closes #13602 Signed-off-by: He Weiwei <hweiwei@vmware.com>
This commit is contained in:
parent
bc2a161f13
commit
164acad24f
10
Makefile
10
Makefile
|
@ -44,6 +44,8 @@
|
||||||
# clean: remove binary, Harbor images, specific version docker-compose \
|
# clean: remove binary, Harbor images, specific version docker-compose \
|
||||||
# file, specific version tag and online/offline install package
|
# file, specific version tag and online/offline install package
|
||||||
# cleanbinary: remove core and jobservice binary
|
# cleanbinary: remove core and jobservice binary
|
||||||
|
# cleanbaseimage:
|
||||||
|
# remove the base images of Harbor images
|
||||||
# cleanimage: remove Harbor images
|
# cleanimage: remove Harbor images
|
||||||
# cleandockercomposefile:
|
# cleandockercomposefile:
|
||||||
# remove specific version docker-compose
|
# remove specific version docker-compose
|
||||||
|
@ -566,6 +568,11 @@ cleanbinary:
|
||||||
if [ -f $(MIGRATEPATCHBINARYPATH)/$(MIGRATEPATCHBINARYNAME) ] ; then rm $(MIGRATEPATCHBINARYPATH)/$(MIGRATEPATCHBINARYNAME) ; fi
|
if [ -f $(MIGRATEPATCHBINARYPATH)/$(MIGRATEPATCHBINARYNAME) ] ; then rm $(MIGRATEPATCHBINARYPATH)/$(MIGRATEPATCHBINARYNAME) ; fi
|
||||||
rm -rf make/photon/*/binary/
|
rm -rf make/photon/*/binary/
|
||||||
|
|
||||||
|
cleanbaseimage:
|
||||||
|
@echo "cleaning base image for photon..."
|
||||||
|
@for name in chartserver trivy-adapter core db jobservice log nginx notary-server notary-signer portal prepare redis registry registryctl; do \
|
||||||
|
$(DOCKERRMIMAGE) -f $(BASEIMAGENAMESPACE)/harbor-$$name-base:$(BASEIMAGETAG) ; \
|
||||||
|
done
|
||||||
|
|
||||||
cleanimage:
|
cleanimage:
|
||||||
@echo "cleaning image for photon..."
|
@echo "cleaning image for photon..."
|
||||||
|
@ -598,12 +605,13 @@ cleanconfig:
|
||||||
rm -f $(BUILDPATH)/src/portal/proxy.config.json
|
rm -f $(BUILDPATH)/src/portal/proxy.config.json
|
||||||
|
|
||||||
.PHONY: cleanall
|
.PHONY: cleanall
|
||||||
cleanall: cleanbinary cleanimage cleandockercomposefile cleanconfig cleanpackage
|
cleanall: cleanbinary cleanimage cleanbaseimage cleandockercomposefile cleanconfig cleanpackage
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
@echo " make cleanall: remove binary, Harbor images, specific version docker-compose"
|
@echo " make cleanall: remove binary, Harbor images, specific version docker-compose"
|
||||||
@echo " file, specific version tag, online and offline install package"
|
@echo " file, specific version tag, online and offline install package"
|
||||||
@echo " make cleanbinary: remove core and jobservice binary"
|
@echo " make cleanbinary: remove core and jobservice binary"
|
||||||
|
@echo " make cleanbaseimage: remove base image of Harbor images"
|
||||||
@echo " make cleanimage: remove Harbor images"
|
@echo " make cleanimage: remove Harbor images"
|
||||||
@echo " make cleandockercomposefile: remove specific version docker-compose"
|
@echo " make cleandockercomposefile: remove specific version docker-compose"
|
||||||
@echo " make cleanpackage: remove online and offline install package"
|
@echo " make cleanpackage: remove online and offline install package"
|
||||||
|
|
Loading…
Reference in New Issue