You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@heron.apache.org by GitBox <gi...@apache.org> on 2018/12/20 01:03:00 UTC

[GitHub] nwangtw closed pull request #3130: Fix docker rc and scripts for building heron

nwangtw closed pull request #3130: Fix docker rc and scripts for building heron
URL: https://github.com/apache/incubator-heron/pull/3130
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/docker/Readme.md b/docker/Readme.md
index a9c0220e15..158570878b 100644
--- a/docker/Readme.md
+++ b/docker/Readme.md
@@ -1,6 +1,7 @@
 # Docker
 
 ## To compile source, into Heron release artifacts, using a docker container:
+Make sure enough resources are configured in Docker settings: 2 CPU, 4G RAM and 128G disk.
 ```
 ./docker/scripts/build-artifacts.sh <platform> <version_string> [source-tarball] <output-directory>
 # e.g.  ./docker/scripts/build-artifacts.sh ubuntu14.04 testbuild ~/heron-release
diff --git a/docker/scripts/build-exec-docker.sh b/docker/scripts/build-exec-docker.sh
index f9842bbcd7..88d615a7d4 100755
--- a/docker/scripts/build-exec-docker.sh
+++ b/docker/scripts/build-exec-docker.sh
@@ -49,7 +49,7 @@ build_exec_image() {
   HERON_VERSION=$2
   OUTPUT_DIRECTORY=$(realpath $3)
 
-  DOCKER_FILE="$SCRATCH_DIR/Dockerfile.dist.$TARGET_PLATFORM"
+  DOCKER_FILE="$SCRATCH_DIR/dist/Dockerfile.dist.$TARGET_PLATFORM"
   DOCKER_TAG="heron:$HERON_VERSION-$TARGET_PLATFORM"
 
   setup_scratch_dir $SCRATCH_DIR
diff --git a/docker/scripts/compile-platform.sh b/docker/scripts/compile-platform.sh
index 384a9dfba1..69dd36fe64 100755
--- a/docker/scripts/compile-platform.sh
+++ b/docker/scripts/compile-platform.sh
@@ -57,6 +57,7 @@ else
   exit 1
 fi
 
+bazel version
 ./bazel_configure.py
 bazel clean
 
diff --git a/tools/docker/bazel.rc b/tools/docker/bazel.rc
index b0a70692be..f6bb4eaf53 100644
--- a/tools/docker/bazel.rc
+++ b/tools/docker/bazel.rc
@@ -24,3 +24,11 @@ build --verbose_failures
 # fails to run tests.
 build --spawn_strategy=standalone --genrule_strategy=standalone
 test --test_strategy=standalone
+
+# Workaround https://github.com/bazelbuild/bazel/issues/3645
+# Bazel doesn't calculate the memory ceiling correctly when running under Docker.
+# Limit Bazel to consuming 4G ram and 2 cores.
+build --local_resources=4096,2.0,1.0
+
+# Echo all the configuration settings and their source
+ build --announce_rc
\ No newline at end of file
diff --git a/website/content/docs/operators/deployment/schedulers/dcos.md b/website/content/docs/operators/deployment/schedulers/dcos.md
index a380574f9d..f63c4929dc 100644
--- a/website/content/docs/operators/deployment/schedulers/dcos.md
+++ b/website/content/docs/operators/deployment/schedulers/dcos.md
@@ -78,7 +78,7 @@ bucket).
 * `heron.executor.docker.image` --- Specified the Docker image to be used for running the executor.
 For the time being, a public image has been made available at `ndustrialio/heron-executor:jre8`. 
 However, you can create your own version of this Docker image by creating a Docker image with
-the Dockerfile provided at `heron/docker/Dockerfile.dist.ubuntu14.04` and pushing it to your own 
+the Dockerfile provided at `heron/docker/dist/Dockerfile.dist.ubuntu14.04` and pushing it to your own
 publicly-available Docker repository.
 
 ### Example Marathon Scheduler Configuration


 

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


With regards,
Apache Git Services