diff --git a/Makefile b/Makefile index d6835df6b..9c65f936a 100644 --- a/Makefile +++ b/Makefile @@ -101,7 +101,7 @@ REGISTRYVERSION=v2.6.2 NGINXVERSION=$(VERSIONTAG) NOTARYVERSION=v0.5.1 MARIADBVERSION=$(VERSIONTAG) -CLAIRVERSION=v2.0.4 +CLAIRVERSION=v2.0.5 CLAIRDBVERSION=$(VERSIONTAG) MIGRATORVERSION=$(VERSIONTAG) REDISVERSION=$(VERSIONTAG) diff --git a/make/harbor.cfg b/make/harbor.cfg index d048ccf22..1cbde0a23 100644 --- a/make/harbor.cfg +++ b/make/harbor.cfg @@ -173,7 +173,7 @@ clair_db_username = postgres clair_db = postgres #The interval of clair updaters, the unit is hour, set to 0 to disable the updaters. -clair_updaters_interval = 0 +clair_updaters_interval = 12 ##########End of Clair DB configuration############ diff --git a/make/photon/Makefile b/make/photon/Makefile index c86964f10..babf68b09 100644 --- a/make/photon/Makefile +++ b/make/photon/Makefile @@ -125,7 +125,7 @@ _build_clair: @if [ "$(CLAIRFLAG)" = "true" ] ; then \ if [ "$(BUILDBIN)" != "true" ] ; then \ rm -rf $(DOCKERFILEPATH_CLAIR)/binary && mkdir -p $(DOCKERFILEPATH_CLAIR)/binary && \ - $(call _get_binary, https://storage.googleapis.com/harbor-builds/bin/clair, $(DOCKERFILEPATH_CLAIR)/binary/clair); \ + $(call _get_binary, https://storage.googleapis.com/harbor-builds/bin/clair/release2.0-$(CLAIRVERSION)/clair, $(DOCKERFILEPATH_CLAIR)/binary/clair); \ else \ cd $(DOCKERFILEPATH_CLAIR) && $(DOCKERFILEPATH_CLAIR)/builder $(CLAIRVERSION); \ fi ; \ diff --git a/make/photon/clair/builder b/make/photon/clair/builder index 6ce9c07a7..086903f4d 100755 --- a/make/photon/clair/builder +++ b/make/photon/clair/builder @@ -20,7 +20,8 @@ cur=$PWD # the temp folder to store distribution source code... TEMP=`mktemp -d /$TMPDIR/clair.XXXXXX` -git clone -b $VERSION https://github.com/coreos/clair.git $TEMP +git clone https://github.com/coreos/clair.git $TEMP +cd $TEMP; git checkout $VERSION; cd - echo 'build the clair binary bases on the golang:1.7.3...' cp Dockerfile.binary $TEMP