vite build within docker is killed

See original GitHub issue

Describe the bug

When I try to build an app in a docker container that has the @arcgis/core module the build fails.

Reproduction

  1. clone this repo git clone https://github.com/steveoh/esri-docker.git
  2. give execute permission to build script chmod +x ./scripts/docker-build.sh
  3. execute the build ./scripts/docker-build.sh

This fails in docker for me. It is successful on macos and with the dev command. Does this make it a rollup or esbuild issue?

System Info

My system

System:
    OS: macOS 10.15.7
    CPU: (16) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
    Memory: 75.61 MB / 32.00 GB
    Shell: 5.7.1 - /bin/zsh
  Binaries:
    Node: 16.2.0 - /usr/local/bin/node
    npm: 7.13.0 - /usr/local/bin/npm
  Browsers:
    Chrome: 90.0.4430.212
    Firefox: 87.0
    Safari: 14.1.1
  npmPackages:
    vite: ^2.3.5 => 2.3.6 

docker system

 System:
#15 1.944     OS: Linux 5.10 Debian GNU/Linux 9 (stretch) 9 (stretch)
#15 1.944     CPU: (8) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
#15 1.944     Memory: 794.97 MB / 1.94 GB
#15 1.944     Container: Yes
#15 1.944     Shell: 4.4.12 - /bin/bash
#15 1.944   Binaries:
#15 1.944     Node: 14.17.0 - /usr/local/bin/node
#15 1.944     Yarn: 1.22.5 - /usr/local/bin/yarn
#15 1.944     npm: 7.15.1 - /usr/local/bin/npm
#15 1.944   npmPackages:
#15 1.944     vite: ^2.3.5 => 2.3.6 

Used package manager: npm


Before submitting the issue, please make sure you do the following

  • Read the Contributing Guidelines.
  • Read the docs.
  • Check that there isn’t already an issue that reports the same bug to avoid creating a duplicate.
  • Provide a description in this issue that describes the bug.
  • Make sure this is a Vite issue and not a framework-specific issue. For example, if it’s a Vue SFC related bug, it should likely be reported to https://github.com/vuejs/vue-next instead.
  • Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord Chat Server.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:10 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
nihalgonsalvescommented, Jun 7, 2021

@steveoh 137 is OOM (out of memory). You could try adjusting your Docker VM settings in macOS and/or setting a NODE_OPTIONS env variable with a suitable --max-old-space-size flag.

I’m closing this as this isn’t a Vite issue.

0reactions
github-actions[bot]commented, Jul 15, 2021

This issue has been locked since it has been closed for more than 14 days.

If you have found a concrete bug or regression related to it, please open a new bug report with a reproduction against the latest Vite version. If you have any other comments you should join the chat at Vite Land or create a new discussion.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Vite React app: esbuild error in Docker container
I'm running into an issue with esbuild inside docker. I'm trying to get a dev setup going, so I want to mount my...
Read more >
VueJs app building Killed in Docker - Heap limit allocation fail ...
Coding example for the question VueJs app building Killed in Docker - Heap limit ... You need to create a file in operating...
Read more >
Frequently asked questions - Docker Documentation
After the timeout, a SIGKILL is sent to the container to forcefully kill it. ... In “detached” mode ( -d ), Compose exits...
Read more >
Deploy React/Vue/Angular in Docker simply and efficiently ...
We will run this command in Docker at build time using correct layers caching. Just create a Dockerfile in a frontend folder: FROM ......
Read more >
Dockerizing a Vue App - Michael Herman
Docker · Build - The node_modules directory is created in the image. · Run - The current directory is mounted into the container,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found