Dockerfile 374 B

1234567891011121314151617
  1. FROM google/golang:latest
  2. ENV TAGS="sqlite redis memcache cert" USER="git" HOME="/home/git"
  3. COPY . /gopath/src/github.com/gogits/gogs/
  4. WORKDIR /gopath/src/github.com/gogits/gogs/
  5. RUN go get -v -tags="$TAGS" github.com/gogits/gogs \
  6. && go build -tags="$TAGS" \
  7. && useradd -d $HOME -m $USER \
  8. && chown -R $USER .
  9. USER $USER
  10. ENTRYPOINT [ "./gogs" ]
  11. CMD [ "web" ]