forked from zhenorzz/goploy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
37 lines (27 loc) · 878 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# Import sql manually https://github.com/zhenorzz/goploy/blob/master/model/sql/goploy.sql
FROM alpine
LABEL maintainer="[email protected]"
ARG GOPLOY_VER=v1.6.0
ENV GOPLOY_VER=${GOPLOY_VER}
ENV MYSQL_PORT=3306
RUN echo "http://mirrors.aliyun.com/alpine/latest-stable/main/" > /etc/apk/repositories
RUN echo "http://mirrors.aliyun.com/alpine/latest-stable/community/" >> /etc/apk/repositories
#install
RUN apk update && \
apk add --no-cache \
openssh-client \
ca-certificates \
bash \
git \
rsync \
&& rm -rf /var/cache/apk/*
#git
RUN git config --global pull.rebase false
#goploy
ADD https://github.com/zhenorzz/goploy/releases/download/${GOPLOY_VER}/goploy /opt/goploy/
RUN chmod a+x /opt/goploy/goploy
EXPOSE 80
VOLUME ["/opt/goploy/repository/"]
WORKDIR /opt/goploy/
ENTRYPOINT ["bash", "-c"]
CMD ["./goploy --asset-dir=./repository"]