Comments (7)
Hey there, @kitchenchem224! I'm here to help you with any issues you're experiencing while using our repository. Let's work together to get this sorted out.
To resolve the error "failed to solve: process '/bin/sh -c npm run ${BUILD_CMD}' did not complete successfully: exit code: 1" when running docker compose up
for the Superset repository, ensure that you are using the correct Node.js version specified in the .nvmrc
file of the superset-frontend
directory. The required Node.js version is v18.20.1
.
Here is how you can set the correct Node.js version:
-
Install NVM (Node Version Manager) if you haven't already:
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | bash source ~/.bashrc
-
Navigate to the
superset-frontend
directory:cd path/to/superset/superset-frontend
-
Use NVM to install and use the correct Node.js version:
nvm install nvm use
-
Verify the Node.js version:
node -v # It should output: v18.20.1
Additionally, ensure that the BUILD_CMD
environment variable is correctly set to "build" as specified in the Dockerfile. The relevant section of the Dockerfile is:
ARG NPM_BUILD_CMD="build"
...
ENV BUILD_CMD=${NPM_BUILD_CMD}
...
RUN npm run ${BUILD_CMD}
After ensuring the correct Node.js version is in use and the BUILD_CMD
is set correctly, try running docker compose up
again. This should resolve the error related to the build command [1][2].
To continue talking to Dosu, mention @dosu.
from superset.
To further troubleshoot the issue, let's ensure that all necessary dependencies are installed and check for any specific errors during the build process.
-
Verify Dependencies:
Ensure that all dependencies are correctly installed. The Dockerfile usesnpm ci
to install dependencies, which requires apackage-lock.json
file. Ensure that this file is present and up-to-date. -
Inspect the Build Command:
Run the build command manually inside the Docker container to see if it provides more detailed error messages. You can do this by starting a shell session in the container and running the command:docker run -it <image-id> /bin/sh cd /app/superset-frontend npm run build
-
Check for Specific Errors:
Look at the specific error messages provided when thenpm run build
command fails. These messages can give you more insight into what is going wrong. -
Increase Memory Limits:
Sometimes, the build process may fail due to insufficient memory. You can try increasing the memory limits for Docker. -
Ensure Environment Variables:
Make sure all necessary environment variables are set correctly. Thesuperset-frontend
build process requires specific environment variables such asNODE_OPTIONS
andBABEL_ENV
:"build": "cross-env NODE_OPTIONS=--max_old_space_size=8192 NODE_ENV=production BABEL_ENV=\"${BABEL_ENV:=production}\" webpack --mode=production --color",
-
Check for Additional Dependencies:
Ensure that all additional dependencies required for the build process are installed. The Dockerfile should include all necessary packages, but you can manually verify and install any missing dependencies.
If the above steps do not resolve the issue, please provide the specific error logs or details about the failure during the npm run build
process. This will help in diagnosing the problem more accurately [1][2].
To continue talking to Dosu, mention @dosu.
from superset.
Sidetrack but I'm still thinking it'd be great to have some some of check_env
script to check you have the right avoid of memory available, npm/node version, python version, ... and tell you what to do
from superset.
I am on the correct node version and the dockerfile is correct. I am still getting the error.
from superset.
Ahh... @mistercrunch and I have been discussing this a bit. I'm 99.99% certain you're just hitting a Docker memory limit, and the error doesn't make that clear. I'm curious your settings, but you're probably <12 GB ram. Bumping to 12-ish should work, and 16GB should be quite safe. We still have yet to find an ideal way to make this safer/stabler with some kind of resource-checking script when starting things up.
from superset.
Not sure what is the minimum req, but I know this works ->
from superset.
Thanks for the reply @rusackas @mistercrunch . I was able to get it running yesterday. I changed my docker resource allocation to a little less generous than yours. I also enabled Kubernetes and set my x-superset-image
to apache/superset:4.0.1-dev
The build time was pretty quick too. Only like 3 or 4 minutes, not the 15+ I've heard about.
from superset.
Related Issues (20)
- Failed to setup alerts and reports based pypi installation HOT 6
- 4.0.1: Alerting and reports does not take EMAIL RECIPIENTS* HOT 4
- Filter does not follow label HOT 1
- [SIP-138] Proposal for Slack file upload V2 integration for Alerts and Reports HOT 2
- [SIP-139] Proposal for Ant Design 5.x Upgrade HOT 4
- On KILL QUERY error "expected string or bytes-like object" in Clickhouse DB HOT 1
- Blank Charts while loading dashboard HOT 2
- Warning when upgrading DB HOT 1
- 500 error and unexpected keyword argument 'extra_filters' HOT 3
- sqlalchemy.exc.ArgumentError HOT 1
- Oracle as Metadata- Not working HOT 2
- Thumbnails work for Dashboards, not for charts HOT 1
- Unable to set role permissions for new schema unless a new connection is created. HOT 1
- Superset Login Redirect After Guest Token Usage in Angular Iframe HOT 1
- start of production no possible due to errors in docker-compose-non-dev.yml and docker/.env HOT 3
- Data Misalignment When Applying Filter HOT 5
- PLAYWRIGHT_REPORTS_AND_THUMBNAILS grey output for dashboards HOT 4
- Superset 3.1.3: Long Dashboards render blank thumbnails unless Dashboard length is reduced HOT 4
- Changing to non-temporal variable, then back, causes time grain to no longer function in 4.0.2rc2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from superset.