Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make in build/alpine produces error 137 #562

Closed
romanrev opened this issue Jan 9, 2019 · 2 comments
Closed

make in build/alpine produces error 137 #562

romanrev opened this issue Jan 9, 2019 · 2 comments

Comments

@romanrev
Copy link
Contributor

romanrev commented Jan 9, 2019

I am trying to build wire-server on my MBP (MacOS Mojave 10.14.2) with Docker version 18.09.0, build 4d60db4. After a while I the build ends with error 137, with no further log messages, as per below:

...
vector-algorithms-0.7.0.4: download
vector-algorithms-0.7.0.4: configure
vector-algorithms-0.7.0.4: build
The command '/bin/sh -c apk add --no-cache git ncurses &&     mkdir -p /src && cd /src &&     git clone -b develop https://github.com/wireapp/wire-server.git &&     cd wire-server &&     stack update &&     echo "allow-different-user: true"                                       >> /root/.stack/config.yaml &&     echo                                                                    >> /root/.stack/config.yaml &&     echo '# NB: do not touch following line!'                               >> /root/.stack/config.yaml &&     echo '# this image is used both for building docker images with the'    >> /root/.stack/config.yaml &&     echo '# integration tests (so they can be run on the ci) and for'       >> /root/.stack/config.yaml &&     echo '# interactive integration testing (with the working copy of the'  >> /root/.stack/config.yaml &&     echo '# host system mounted into the docker container).  in the latter' >> /root/.stack/config.yaml &&     echo '# use case, we want the docker container to write to its own'     >> /root/.stack/config.yaml &&     echo '# stack-work directory and not pollute the one on the host.'      >> /root/.stack/config.yaml &&     echo 'work-dir: .stack-docker'                                          >> /root/.stack/config.yaml &&     stack --work-dir .stack-docker-profile build --haddock --dependencies-only --profile haskell-src-exts &&     stack --work-dir .stack-docker         build --haddock --dependencies-only           haskell-src-exts &&     stack --work-dir .stack-docker-profile build --haddock --no-haddock-hyperlink-source --profile haskell-src-exts &&     stack --work-dir .stack-docker         build --haddock --no-haddock-hyperlink-source           haskell-src-exts &&     stack --work-dir .stack-docker-profile build --pedantic --haddock --test --no-run-tests --bench --no-run-benchmarks --dependencies-only --profile &&     stack --work-dir .stack-docker         build --pedantic --haddock --test --no-run-tests --bench --no-run-benchmarks --dependencies-only' returned a non-zero code: 137
make: *** [builder] Error 137
@neongreen
Copy link
Contributor

Try giving Docker more memory:

@romanrev
Copy link
Contributor Author

romanrev commented Jan 9, 2019

thanks! I thought that might be an issue, ended up pulling the alpine-builder image instead of pulling it

neongreen pushed a commit that referenced this issue Jan 9, 2019
neongreen pushed a commit that referenced this issue Jan 9, 2019
lfborjas added a commit to lfborjas/freenatalchart.xyz that referenced this issue Oct 18, 2020
It seems that certain haskell packages (in my case, haskell-src-exts,)
take up so much memory that docker dies trying to run them, so we make
it run with one job, vs. as many as possible in parallel.

See:

* https://github.com/facebook/duckling/blob/7889f396f324028075d39e5003f1083ad05d68f3/Dockerfile
* facebook/duckling#203
* wireapp/wire-server#562
* https://stackoverflow.com/questions/56496852/problem-building-a-docker-container-with-haskell-stack-how-can-i-ensure-that-ha
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants