You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apisix.apache.org by kv...@apache.org on 2020/12/02 12:55:06 UTC

[apisix-ingress-controller] branch master updated: chore: improve Dockerfile (#43)

This is an automated email from the ASF dual-hosted git repository.

kvn pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix-ingress-controller.git


The following commit(s) were added to refs/heads/master by this push:
     new ac4368d  chore: improve Dockerfile (#43)
ac4368d is described below

commit ac4368dedd78344759c07a1c15bb3ae6ba94eb1b
Author: Jintao Zhang <ta...@163.com>
AuthorDate: Wed Dec 2 20:54:54 2020 +0800

    chore: improve Dockerfile (#43)
    
    Signed-off-by: Jintao Zhang <zh...@gmail.com>
---
 Dockerfile | 16 +++++++---------
 1 file changed, 7 insertions(+), 9 deletions(-)

diff --git a/Dockerfile b/Dockerfile
index 2f4c4b9..86cb493 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,5 +1,6 @@
 FROM golang:1.13.8 AS build-env
-MAINTAINER gxthrj@163.com
+LABEL maintainer="gxthrj@163.com"
+
 
 WORKDIR /go/src/github.com/api7/ingress-controller
 COPY . .
@@ -14,16 +15,13 @@ RUN mkdir /root/ingress-controller \
     && ln -s  /usr/share/zoneinfo/Hongkong /etc/localtime \
     && dpkg-reconfigure -f noninteractive tzdata
 
-FROM alpine:3.11
-MAINTAINER gxthrj@163.com
+FROM alpine:3.12.1
+LABEL maintainer="gxthrj@163.com"
 
 RUN mkdir /root/ingress-controller \
-   && apk update  \
-   && apk add ca-certificates \
+   && apk add --no-cache ca-certificates libc6-compat \
    && update-ca-certificates \
-   && apk add --no-cache libc6-compat \
-   && echo "hosts: files dns" > /etc/nsswitch.conf \
-   && rm -rf /var/cache/apk/*
+   && echo "hosts: files dns" > /etc/nsswitch.conf
 
 
 WORKDIR /root/ingress-controller
@@ -31,4 +29,4 @@ COPY --from=build-env /root/ingress-controller/* /root/ingress-controller/
 COPY --from=build-env /usr/share/zoneinfo/Hongkong /etc/localtime
 EXPOSE 8080
 RUN chmod +x ./build.sh
-CMD ["/root/ingress-controller/build.sh"]
\ No newline at end of file
+CMD ["/root/ingress-controller/build.sh"]