shyim / shopware-docker

Easy to use Docker Installation for Shopware 5 and Shopware 6
MIT License
115 stars 27 forks source link

swdc storefront-watch not working Properly under Shopware 6.4. #95

Closed stormannsgalskap closed 3 years ago

stormannsgalskap commented 3 years ago

Hy, first of all thanks for this tool.

I updated the Shopware version to 6.4. Since than i started to get this error. After starting swdc storefront-watch compiles everything and runs under the correct url / port. swdc storefront-watch <directory> The Shop content loads but it looks like it has no styles nor js. This is the Browser log.

image

Since it was a new Shopware version, i pulled the repository again, ran the update-images, but the error persists. git pull swdc update-images

When i try building to init the storefront swdc storefront-init <directory> it says that python has to be installed (very long error message) at command node-gyp rebuild

image

Havy any idea why it's failing? I guess the python failing has something to do with the error. Thanks!

shyim commented 3 years ago

Which type of template is it? production?

It could be that the Resources/app/storefront/build/proxy-server-hot/index.js is now wrong. Can you check that file is unchanged to 6.4.0.0 release?

stormannsgalskap commented 3 years ago

Production.

As much as i cann tell, these changes has been made from 6.3.5 to 6.4

https://github.com/shopware/storefront/commit/10411f5837e5321a87f4961162f751be0091890b#diff-08fe350e533ff0ceedb5a20dc10261be86acf272918b373288d7c843bc635ddb

https://github.com/shopware/storefront/commit/e11a9c070637dbcc62f24c2d9f769ae7e12f0126#diff-08fe350e533ff0ceedb5a20dc10261be86acf272918b373288d7c843bc635ddb

shyim commented 3 years ago

Is it in your codebase changed to the git version? In the older version that file has been patched by this setup there

stormannsgalskap commented 3 years ago

i just compared the code. In truth the content is not the same. But why?

I did updated Shopware from the backend. Are there other steps to be done? Should i update shopware with composer maybe?

shyim commented 3 years ago

For 6.4.0.0 it should run into these if conditions: https://github.com/shyim/shopware-docker/blob/master/modules/platform-local/storefront-watch.sh#L12-L16

That happens when this file contains this line: https://github.com/shopware/platform/blob/trunk/src/Storefront/Resources/app/storefront/webpack.config.js#L61

For some reason, it doesn't run at your installation there. Is very strange 🙈. Could you check that file?

stormannsgalskap commented 3 years ago

Hy,

The storefront-watch from shopware-docker are the same.

The differences in the webpack file are like u see in the Image below. Not relevant... image

stormannsgalskap commented 3 years ago

So..

i tried to debug the storefront-watch script, and i found following: I looks like there a Slash missing. After i added the slash, the script downloaded a new Docker Image, and now the storefront watch is running under the url http://storefront-sw6.dev.localhost/ at port 80. But the CORS error is still present.

Does this help in any way?

no-slash new Image

shyim commented 3 years ago

Yes it helps. The cors error are introduced from the core

stormannsgalskap commented 3 years ago

ok.. CORS could be tricked around. I am intrested more on fixing the missing js files. Please let me know, how i could help. Maybe an other hint, what to search for?