1
0

feat: use centos images

This commit is contained in:
502647092 2018-09-11 20:08:58 +08:00
parent 0c567a6c8a
commit 66d4e0f273
3 changed files with 8 additions and 12 deletions

2
.gitignore vendored
View File

@ -25,4 +25,4 @@ _testmain.go
*.prof *.prof
/vendor /vendor
main #main

View File

@ -1,17 +1,13 @@
FROM golang:alpine AS build FROM centos
WORKDIR /go/src/github.com/yumc.pw/cloud/html2pic
ADD . .
RUN go build -o main
FROM alpine:edge
LABEL maintainer="MiaoWoo<admin@yumc.pw>" LABEL maintainer="MiaoWoo<admin@yumc.pw>"
ENV LANG C.UTF-8 ENV LANG C.UTF-8
WORKDIR /root WORKDIR /root
RUN apk add --no-cache ca-certificates RUN yum install -y fontconfig
COPY --from=build /go/src/github.com/yumc.pw/cloud/html2pic/main ./main ADD main main
ADD lib /root/lib ADD lib lib
CMD ./main -lib /root/lib ENV LIB_DIR=/root/lib
CMD ./main -lib ${LIB_DIR}

BIN
main Executable file

Binary file not shown.