vvysotskyi commented on a change in pull request #1947: DRILL-7496: Update 
Dockerfile to publish release images under Apache Docker Hub
URL: https://github.com/apache/drill/pull/1947#discussion_r362731072
 
 

 ##########
 File path: Dockerfile
 ##########
 @@ -16,20 +16,28 @@
 # limitations under the License.
 #
 
-FROM centos:7
+# Uses intermediate image for building Drill to reduce target image size
+FROM maven:3.6-jdk-8 as build
 
-# Project version defined in pom.xml is passed as an argument
-ARG VERSION
+# Copy project sources into the container
+COPY . /src
 
-# JDK 8 is a pre-requisite to run Drill ; 'which' package is needed for 
drill-config.sh
-RUN yum install -y java-1.8.0-openjdk-devel which ; yum clean all ; rm -rf 
/var/cache/yum
+WORKDIR /src
 
-# The drill tarball is generated upon building the Drill project
-COPY target/apache-drill-$VERSION.tar.gz /tmp
+# Builds Drill
+RUN  mvn clean install -DskipTests -q
 
 Review comment:
   Yes, the purpose is to build the "official" Drill container for the releases 
and for the master branch. There are a lot of other Apache projects which do 
the same - build project when building the image.
   
   Automating the publishing simplifies things a lot, to publish Drill image, 
without it, you should create INFRA Jira to provide push access for Drill 
DockerHub, and only later push the image.
   
   I think that there wouldn't be significant differences between Drill built 
during the release and Drill, built inside Docker image.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to