1 Star 0 Fork 36

星旋·虚眼/Hugo-Go

forked from Gitee 极速下载/Hugo-Go 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Dockerfile 743 Bytes
一键复制 编辑 原始数据 按行查看 历史
# GitHub: https://github.com/gohugoio
# Twitter: https://twitter.com/gohugoio
# Website: https://gohugo.io/
FROM golang:1.11-stretch AS build
WORKDIR /go/src/github.com/gohugoio/hugo
RUN apt-get install \
git gcc g++ binutils
COPY . /go/src/github.com/gohugoio/hugo/
ENV GO111MODULE=on
RUN go get -d .
ARG CGO=0
ENV CGO_ENABLED=${CGO}
ENV GOOS=linux
# default non-existent build tag so -tags always has an arg
ARG BUILD_TAGS="99notag"
RUN go install -ldflags '-w -extldflags "-static"' -tags ${BUILD_TAGS}
# ---
FROM alpine:3.9
RUN apk add --no-cache ca-certificates
COPY --from=build /go/bin/hugo /hugo
ARG WORKDIR="/site"
WORKDIR ${WORKDIR}
VOLUME ${WORKDIR}
EXPOSE 1313
ENTRYPOINT [ "/hugo" ]
CMD [ "--help" ]
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/itdb/Hugo-Go.git
git@gitee.com:itdb/Hugo-Go.git
itdb
Hugo-Go
Hugo-Go
master

搜索帮助