1 Star 0 Fork 292

powerdream / go-fastdfs

forked from sjqzhang / go-fastdfs 
Gitee —— 企业级 DevOps 研发管理平台
加入 Gitee
克隆/下载
Dockerfile 970 Bytes
一键复制 编辑 Web IDE 原始数据 按行查看 历史
sjqzhang 提交于 2019-02-22 11:38 . remove docker version
FROM registry.cn-hangzhou.aliyuncs.com/prince/alpine-golang:1.11.5 as builder
MAINTAINER prince <8923052@qq.com>
ARG VERSION=1.1.7
RUN set -xe; \
apk update; \
apk add --no-cache --virtual .build-deps \
git; \
cd /go/src/; \
git clone https://github.com/sjqzhang/go-fastdfs.git; \
cd go-fastdfs; \
go get; \
CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o fileserver; \
ls -lh .;
FROM registry.cn-hangzhou.aliyuncs.com/prince/alpine-bash
COPY --from=builder /go/src/go-fastdfs/fileserver /
ENV INSTALL_DIR /usr/local/go-fastdfs
ENV PATH $PATH:$INSTALL_DIR/
ENV GO_FASTDFS_DIR $INSTALL_DIR/data
RUN set -xe; \
mkdir -p $GO_FASTDFS_DIR; \
mkdir -p $GO_FASTDFS_DIR/conf; \
mkdir -p $GO_FASTDFS_DIR/data; \
mkdir -p $GO_FASTDFS_DIR/files; \
mkdir -p $GO_FASTDFS_DIR/log; \
mkdir -p $INSTALL_DIR; \
mv /fileserver $INSTALL_DIR/; \
chmod +x $INSTALL_DIR/fileserver;
WORKDIR $INSTALL_DIR
VOLUME $GO_FASTDFS_DIR
CMD ["fileserver" , "${OPTS}"]

评论 ( 0 )

你可以在登录后,发表评论

Go
1
https://gitee.com/powerdream/go-fastdfs.git
git@gitee.com:powerdream/go-fastdfs.git
powerdream
go-fastdfs
go-fastdfs
master

搜索帮助

122604 9befe709 551147 122411 94cd1624 551147