-
Notifications
You must be signed in to change notification settings - Fork 52
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
Cannot find module 'react' #23
Comments
Facing the same problem |
Adding React does not fix the problem in and of itself: react-dom, react-router-dom, and styled-components also will need to be added to the image. This can be fixed quickly by including the packages in the dockerfile(s) - versions per the error logs
Alternatively, the entire above line in the dockerfile(s) can be dropped as the For building new Strapi v4 projects with the above removed, migrate the entrypoint(s) from I just did the migration on my fork for reference. I also included a catch for adding the missing packages to existing projects as well as a version upgrade check to compare the current Strapi project version and the image version; upgrading if necessary. @naskio I'm happy to open a PR for the migration |
@V-Shadbolt the fork seems hangs on
I am using default docker compose yaml, starting from the scratch
|
@kuncevic there was a breaking change (in relation to the docker image) between v4 and v5 of Strapi with how the CLI works on project setup. Specifically it prompts user input now for Strapi Cloud login/signup. Release 4.35.11 of the fork should still work as expected. There seems to be a flag I can use to bypass the Strapi Cloud questions which should solve the issue but I’ll need to do some testing around it first before I implement it into the docker image. I would recommend opening this as an issue against my fork for tracking purposes. |
same problem |
I give you two options to move forward: 1: docker run -d -p 1337:1337 naskio/strapi:4.14.5-alpine 2: services:
// NODE_ENV: production volumes: |
I have the same problem on different versions. Also the latest. |
same issue v5.9.0 |
Shadbolt, thanks for the fork. The image shouldn't be broken out of the box like this. Your image works. Cheers mate! |
@V-Shadbolt I spoke too soon. I need mysql which isn't in your entrypoint. I may modify that for my purposes, but for now your solution is on the right track... |
@zebulun78 This should now fixed in my fork in v5.10.2 and 4.25.20. |
The text was updated successfully, but these errors were encountered: