From 78103f1df3d89cbf5b3a75188e2ea097d2a8ca9f Mon Sep 17 00:00:00 2001 From: Chance Zibolski Date: Mon, 21 Jul 2014 20:20:35 -0700 Subject: [PATCH 1/4] Remove apt-get cleanup from Dockerfile Purging/cleaning packages using apt doesn't actually reduce image size, and only creates additional layers, which doesn't add any benefit to the overall image. --- dockerfiles/images/gogits/Dockerfile | 3 --- 1 file changed, 3 deletions(-) diff --git a/dockerfiles/images/gogits/Dockerfile b/dockerfiles/images/gogits/Dockerfile index 1f67d41ed..80801a09c 100644 --- a/dockerfiles/images/gogits/Dockerfile +++ b/dockerfiles/images/gogits/Dockerfile @@ -19,9 +19,6 @@ RUN cd /usr/local/go/src && ./make.bash --no-clean 2>&1 RUN go get -u -d github.com/gogits/gogs RUN cd $GOPATH/src/github.com/gogits/gogs && git checkout dev && git pull origin dev && go install && go build -tags redis -# Clean all the unused packages -RUN apt-get autoremove -y -RUN apt-get clean all # Add the deploy script to the docker image and assign execution permission to it. ADD ./deploy.sh / From febaddfd1d75727e67443d1ae954a071e20db444 Mon Sep 17 00:00:00 2001 From: taziden Date: Sun, 27 Jul 2014 20:32:41 +0200 Subject: [PATCH 2/4] actually use SshPort variable SshPort is defined (SSH_PORT) but the value is not actually used (just compared to default port 22). --- modules/middleware/repo.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/middleware/repo.go b/modules/middleware/repo.go index 8aa4a6a8a..41182788e 100644 --- a/modules/middleware/repo.go +++ b/modules/middleware/repo.go @@ -162,7 +162,7 @@ func RepoAssignment(redirect bool, args ...bool) martini.Handler { ctx.Data["BranchName"] = "" if setting.SshPort != 22 { - ctx.Repo.CloneLink.SSH = fmt.Sprintf("ssh://%s@%s/%s/%s.git", setting.RunUser, setting.Domain, user.LowerName, repo.LowerName) + ctx.Repo.CloneLink.SSH = fmt.Sprintf("ssh://%s@%s:%s/%s/%s.git", setting.RunUser, setting.Domain, setting.SshPort, user.LowerName, repo.LowerName) } else { ctx.Repo.CloneLink.SSH = fmt.Sprintf("%s@%s:%s/%s.git", setting.RunUser, setting.Domain, user.LowerName, repo.LowerName) } From 8453ffb7eddab65aa8deb9f290fdd60f0efb7f3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=97=A0=E9=97=BB?= Date: Mon, 28 Jul 2014 11:22:53 -0400 Subject: [PATCH 3/4] Revert "actually use SshPort variable" --- modules/middleware/repo.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/middleware/repo.go b/modules/middleware/repo.go index 41182788e..8aa4a6a8a 100644 --- a/modules/middleware/repo.go +++ b/modules/middleware/repo.go @@ -162,7 +162,7 @@ func RepoAssignment(redirect bool, args ...bool) martini.Handler { ctx.Data["BranchName"] = "" if setting.SshPort != 22 { - ctx.Repo.CloneLink.SSH = fmt.Sprintf("ssh://%s@%s:%s/%s/%s.git", setting.RunUser, setting.Domain, setting.SshPort, user.LowerName, repo.LowerName) + ctx.Repo.CloneLink.SSH = fmt.Sprintf("ssh://%s@%s/%s/%s.git", setting.RunUser, setting.Domain, user.LowerName, repo.LowerName) } else { ctx.Repo.CloneLink.SSH = fmt.Sprintf("%s@%s:%s/%s.git", setting.RunUser, setting.Domain, user.LowerName, repo.LowerName) } From 1661421a65ba73d28bff8fe33a5fdea16fb227c4 Mon Sep 17 00:00:00 2001 From: Lars Gregori Date: Sun, 24 Aug 2014 12:39:01 +0200 Subject: [PATCH 4/4] update dockerfiles README.md typo --- dockerfiles/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dockerfiles/README.md b/dockerfiles/README.md index fc27bdf4f..11d28d0fc 100644 --- a/dockerfiles/README.md +++ b/dockerfiles/README.md @@ -17,7 +17,7 @@ cd dockerfiles ./build.sh ``` -The build might take some time, just be paient. After it finishes, you will receive the message: +The build might take some time, just be patient. After it finishes, you will receive the message: ``` Now we have the MySQL image(running) and gogs image, use the follow command to start gogs service( the content might be different, according to your own configs):