rmetzger commented on a change in pull request #12172:
URL: https://github.com/apache/flink/pull/12172#discussion_r425818508



##########
File path: flink-end-to-end-tests/test-scripts/common_docker.sh
##########
@@ -33,8 +33,25 @@ function containers_health_check() {
   done
 }
 
-function build_image_with_jar() {
-    local job_artifacts=$1
-    local image_name=${2:-flink-job}
-    ./build.sh --from-local-dist --job-artifacts ${job_artifacts} --image-name 
${image_name}
+function build_image() {
+    local image_name=${1:-flink-job}
+
+    echo "Starting fileserver for Flink distribution"
+    pushd ${FLINK_DIR}/..
+    tar -czf "${TEST_DATA_DIR}/flink.tgz" flink-*
+    popd
+    pushd ${TEST_DATA_DIR}
+    python -m SimpleHTTPServer 9999 &

Review comment:
       This doesn't work with python3 anymore. Python 2 support has been 
discontinued.
   
   I'm a bit concerned that this blows up at some point. We could add a python 
version check, and use the equivalent python 3 call (`python3 -m http.server`), 
download a python binary from somewhere, dockerize it? ... 
   

##########
File path: flink-end-to-end-tests/test-scripts/common_docker.sh
##########
@@ -33,8 +33,25 @@ function containers_health_check() {
   done
 }
 
-function build_image_with_jar() {
-    local job_artifacts=$1
-    local image_name=${2:-flink-job}
-    ./build.sh --from-local-dist --job-artifacts ${job_artifacts} --image-name 
${image_name}
+function build_image() {
+    local image_name=${1:-flink-job}
+
+    echo "Starting fileserver for Flink distribution"

Review comment:
       This mechanism is quite useful for developers of Flink. Does it make 
sense to move this code into a script in "flink-docker.git" and use this here?
   
   ```bash
   git clone https://github.com/apache/flink-docker.git
   cd flink-docker
   ./build-from-local.sh /path/to/my/build/target username/image:tag
   ```
   

##########
File path: 
flink-end-to-end-tests/test-scripts/container-scripts/docker-compose.test.yml
##########
@@ -16,15 +16,31 @@
 # limitations under the License.
 
################################################################################
 
-# Extensions to flink-container/docker/docker-compose.yml that mounts volumes 
needed for tests
+# Docker compose file for a Flink job cluster deployment.
+#
+# Parameters:
+# * FLINK_DOCKER_IMAGE_NAME - Image name to use for the deployment (default: 
flink-job:latest)

Review comment:
       default seems to be `flink-job`, w/o the `:latest`.




----------------------------------------------------------------
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:
[email protected]


Reply via email to