diff options
Diffstat (limited to 'docker/build.sh')
-rwxr-xr-x | docker/build.sh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/docker/build.sh b/docker/build.sh new file mode 100755 index 0000000000..0616aa40f4 --- /dev/null +++ b/docker/build.sh @@ -0,0 +1,17 @@ +#!/bin/sh + +# Install build deps +apk -U --no-progress add linux-pam-dev go@community gcc musl-dev + +# Init go environment to build Gogs +mkdir -p ${GOPATH}/src/github.com/gogits/ +ln -s /app/gogs/ ${GOPATH}/src/github.com/gogits/gogs +cd ${GOPATH}/src/github.com/gogits/gogs +go get -v -tags "sqlite redis memcache cert pam" +go build -tags "sqlite redis memcache cert pam" + +# Cleanup GOPATH +rm -r $GOPATH + +# Remove build deps +apk --no-progress del linux-pam-dev go gcc musl-dev |