diff --git a/Makefile b/Makefile index ebbbb8ddc..edca0d685 100644 --- a/Makefile +++ b/Makefile @@ -254,17 +254,17 @@ compile_golangimage: compile_clarity @echo "compiling binary for adminserver (golang image)..." @echo $(GOBASEPATH) @echo $(GOBUILDPATH) - @$(DOCKERCMD) run --rm -v $(BUILDPATH):$(GOBUILDPATH) -w $(GOBUILDPATH_ADMINSERVER) $(GOBUILDIMAGE) $(GOIMAGEBUILD) -v -o $(GOBUILDMAKEPATH_ADMINSERVER)/$(ADMINSERVERBINARYNAME) + @$(DOCKERCMD) run --rm -v $(BUILDPATH):$(GOBUILDPATH) -w $(GOBUILDPATH_ADMINSERVER) $(GOBUILDIMAGE) $(GOIMAGEBUILD) -o $(GOBUILDMAKEPATH_ADMINSERVER)/$(ADMINSERVERBINARYNAME) @echo "Done." @echo "compiling binary for ui (golang image)..." @echo $(GOBASEPATH) @echo $(GOBUILDPATH) - @$(DOCKERCMD) run --rm -v $(BUILDPATH):$(GOBUILDPATH) -w $(GOBUILDPATH_UI) $(GOBUILDIMAGE) $(GOIMAGEBUILD) -v -o $(GOBUILDMAKEPATH_UI)/$(UIBINARYNAME) + @$(DOCKERCMD) run --rm -v $(BUILDPATH):$(GOBUILDPATH) -w $(GOBUILDPATH_UI) $(GOBUILDIMAGE) $(GOIMAGEBUILD) -o $(GOBUILDMAKEPATH_UI)/$(UIBINARYNAME) @echo "Done." @echo "compiling binary for jobservice (golang image)..." - @$(DOCKERCMD) run --rm -v $(BUILDPATH):$(GOBUILDPATH) -w $(GOBUILDPATH_JOBSERVICE) $(GOBUILDIMAGE) $(GOIMAGEBUILD) -v -o $(GOBUILDMAKEPATH_JOBSERVICE)/$(JOBSERVICEBINARYNAME) + @$(DOCKERCMD) run --rm -v $(BUILDPATH):$(GOBUILDPATH) -w $(GOBUILDPATH_JOBSERVICE) $(GOBUILDIMAGE) $(GOIMAGEBUILD) -o $(GOBUILDMAKEPATH_JOBSERVICE)/$(JOBSERVICEBINARYNAME) @echo "Done." compile:check_environment compile_golangimage diff --git a/make/dev/adminserver/Dockerfile b/make/dev/adminserver/Dockerfile index d05f87da2..9d6b04f78 100644 --- a/make/dev/adminserver/Dockerfile +++ b/make/dev/adminserver/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.7.3 +FROM golang:1.9.2 MAINTAINER yinw@vmware.com @@ -6,7 +6,7 @@ COPY . /go/src/github.com/vmware/harbor WORKDIR /go/src/github.com/vmware/harbor/src/adminserver -RUN go build -v -a -o /go/bin/harbor_adminserver \ +RUN go build -a -o /go/bin/harbor_adminserver \ && chmod u+x /go/bin/harbor_adminserver WORKDIR /go/bin/ ENTRYPOINT ["/go/bin/harbor_adminserver"] diff --git a/make/dev/jobservice/Dockerfile b/make/dev/jobservice/Dockerfile index 87bc159fb..dc76a88bb 100644 --- a/make/dev/jobservice/Dockerfile +++ b/make/dev/jobservice/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.7.3 +FROM golang:1.9.2 MAINTAINER jiangd@vmware.com @@ -6,7 +6,7 @@ COPY . /go/src/github.com/vmware/harbor WORKDIR /go/src/github.com/vmware/harbor/src/jobservice -RUN go build -v -a -o /go/bin/harbor_jobservice \ +RUN go build -a -o /go/bin/harbor_jobservice \ && chmod u+x /go/bin/harbor_jobservice WORKDIR /go/bin/ ENTRYPOINT ["/go/bin/harbor_jobservice"] diff --git a/make/dev/ui/Dockerfile b/make/dev/ui/Dockerfile index 47f24c954..046b047ea 100644 --- a/make/dev/ui/Dockerfile +++ b/make/dev/ui/Dockerfile @@ -1,11 +1,11 @@ -FROM golang:1.7.3 +FROM golang:1.9.2 MAINTAINER jiangd@vmware.com COPY src/. /go/src/github.com/vmware/harbor/src WORKDIR /go/src/github.com/vmware/harbor/src/ui -RUN go build -v -a -o /go/bin/harbor_ui +RUN go build -a -o /go/bin/harbor_ui COPY src/ui/views /go/bin/views COPY src/ui/static /go/bin/static diff --git a/make/photon/adminserver/Dockerfile b/make/photon/adminserver/Dockerfile index 898881411..df430015e 100644 --- a/make/photon/adminserver/Dockerfile +++ b/make/photon/adminserver/Dockerfile @@ -2,7 +2,7 @@ FROM vmware/photon:1.0 RUN tdnf erase vim -y \ && tdnf distro-sync -y || echo \ - && tdnf install -y sudo \ + && tdnf install -y sudo >> /dev/null \ && tdnf clean all \ && groupadd -r -g 10000 harbor && useradd --no-log-init -r -g 10000 -u 10000 harbor \ && mkdir /harbor/ diff --git a/make/photon/clair/Dockerfile b/make/photon/clair/Dockerfile index b62cc9e67..f3c4cc14c 100644 --- a/make/photon/clair/Dockerfile +++ b/make/photon/clair/Dockerfile @@ -3,7 +3,7 @@ FROM vmware/photon:1.0 RUN tdnf distro-sync -y \ && tdnf erase vim -y \ - && tdnf install -y git shadow sudo bzr rpm xz python-xml \ + && tdnf install -y git shadow sudo bzr rpm xz python-xml >>/dev/null\ && tdnf clean all \ && mkdir /clair2.0.1/ \ && groupadd -r -g 10000 clair \ diff --git a/make/photon/jobservice/Dockerfile b/make/photon/jobservice/Dockerfile index ee3d353f7..c864aa831 100644 --- a/make/photon/jobservice/Dockerfile +++ b/make/photon/jobservice/Dockerfile @@ -2,7 +2,7 @@ FROM vmware/photon:1.0 RUN mkdir /harbor/ \ && tdnf distro-sync -y || echo \ - && tdnf install sudo -y \ + && tdnf install sudo -y >> /dev/null\ && tdnf clean all \ && groupadd -r -g 10000 harbor && useradd --no-log-init -r -g 10000 -u 10000 harbor HEALTHCHECK CMD curl -s -o /dev/null -w "%{http_code}" http://127.0.0.1:8080/api/jobs/replication/1/log|grep 401 diff --git a/make/photon/log/Dockerfile b/make/photon/log/Dockerfile index 1db6314b2..6c34a69a7 100644 --- a/make/photon/log/Dockerfile +++ b/make/photon/log/Dockerfile @@ -1,7 +1,7 @@ FROM vmware/photon:1.0 RUN tdnf distro-sync -y \ - && tdnf install -y cronie rsyslog logrotate shadow tar gzip sudo net-tools\ + && tdnf install -y cronie rsyslog logrotate shadow tar gzip sudo net-tools >> /dev/null\ && mkdir /etc/rsyslog.d/ \ && mkdir /var/spool/rsyslog \ && groupadd -r -g 10000 syslog && useradd --no-log-init -r -g 10000 -u 10000 syslog \ diff --git a/make/photon/mariadb/Dockerfile b/make/photon/mariadb/Dockerfile index a8cbb8821..be41ca200 100644 --- a/make/photon/mariadb/Dockerfile +++ b/make/photon/mariadb/Dockerfile @@ -3,9 +3,9 @@ FROM vmware/photon:1.0 #The Docker Daemon has to be running with storage backend btrfs when building the image RUN tdnf distro-sync -y \ - && tdnf install -y sed shadow procps-ng gawk gzip sudo net-tools \ + && tdnf install -y sed shadow procps-ng gawk gzip sudo net-tools >> /dev/null\ && groupadd -r -g 10000 mysql && useradd --no-log-init -r -g 10000 -u 10000 mysql \ - && tdnf install -y mariadb-server mariadb \ + && tdnf install -y mariadb-server mariadb >> /dev/null\ && mkdir /docker-entrypoint-initdb.d /docker-entrypoint-updatedb.d \ && rm -fr /var/lib/mysql \ && mkdir -p /var/lib/mysql /var/run/mysqld \ @@ -22,4 +22,4 @@ VOLUME /var/lib/mysql /docker-entrypoint-initdb.d /docker-entrypoint-updatedb.d EXPOSE 3306 ENTRYPOINT ["/usr/local/bin/docker-entrypoint.sh"] -CMD ["mysqld"] \ No newline at end of file +CMD ["mysqld"] diff --git a/make/photon/nginx/Dockerfile b/make/photon/nginx/Dockerfile index 9f6bd4353..3f1994db9 100644 --- a/make/photon/nginx/Dockerfile +++ b/make/photon/nginx/Dockerfile @@ -1,7 +1,7 @@ FROM vmware/photon:1.0 RUN tdnf distro-sync -y \ - && tdnf install -y nginx \ + && tdnf install -y nginx >> /dev/null\ && ln -sf /dev/stdout /var/log/nginx/access.log \ && ln -sf /dev/stderr /var/log/nginx/error.log \ && tdnf clean all diff --git a/make/photon/postgresql/Dockerfile b/make/photon/postgresql/Dockerfile index 37fbc1095..451fd17e4 100644 --- a/make/photon/postgresql/Dockerfile +++ b/make/photon/postgresql/Dockerfile @@ -4,7 +4,7 @@ ENV PGDATA /var/lib/postgresql/data RUN touch /etc/localtime.bak \ && tdnf distro-sync -y \ - && tdnf install -y sed shadow gzip postgresql\ + && tdnf install -y sed shadow gzip postgresql >> /dev/null\ && groupadd -r postgres --gid=999 \ && useradd -r -g postgres --uid=999 postgres \ && mkdir -p /docker-entrypoint-initdb.d \ diff --git a/make/photon/registry/Dockerfile b/make/photon/registry/Dockerfile index 2e17a8447..75393eef4 100644 --- a/make/photon/registry/Dockerfile +++ b/make/photon/registry/Dockerfile @@ -5,7 +5,7 @@ MAINTAINER wangyan@vmware.com # The original script in the docker offical registry image. RUN tdnf distro-sync -y \ && tdnf erase vim -y \ - && tdnf install sudo -y \ + && tdnf install sudo -y >> /dev/null\ && tdnf clean all \ && groupadd -r -g 10000 harbor && useradd --no-log-init -r -g 10000 -u 10000 harbor diff --git a/make/photon/ui/Dockerfile b/make/photon/ui/Dockerfile index cc875877c..12c7acd78 100644 --- a/make/photon/ui/Dockerfile +++ b/make/photon/ui/Dockerfile @@ -2,7 +2,7 @@ FROM vmware/photon:1.0 RUN tdnf distro-sync -y || echo \ && tdnf erase vim -y \ - && tdnf install sudo -y \ + && tdnf install sudo -y >> /dev/null\ && tdnf clean all \ && groupadd -r -g 10000 harbor && useradd --no-log-init -r -g 10000 -u 10000 harbor \ && mkdir /harbor/ diff --git a/tests/coverage4gotest.sh b/tests/coverage4gotest.sh index 4d648d3bc..24f5c43ed 100755 --- a/tests/coverage4gotest.sh +++ b/tests/coverage4gotest.sh @@ -26,7 +26,7 @@ for package in $packages do listDeps $package - echo "DEBUG: testing package $package" +# echo "DEBUG: testing package $package" go test -race -cover -coverprofile=profile.tmp -coverpkg "$deps" $package if [ -f profile.tmp ] then