shopware/development

Node 18 is installed in container (shopware/development) but requiered version ist 16.*.*

Opened this issue · 0 comments

PHP Version

7.4.33

Shopware Version

6

Expected behaviour

The node v18 is installed as default in the container (shopware/development). This causes Exception on run (./psh.phar install). I got around this by starting the container myself with "docker exec -u 0 -it [container] bash" and then using nvm to install node version 16.9.0. Then I ran ./psh.phar install. But now i have also problems by creating a new Theme. Namely the theme cannot be compiled. By executing ,,./psh.phar storefront:dev'' I get the following exception:

(2/4) Starting
> PROJECT_ROOT=/app/ npm --prefix vendor/shopware/platform/src/Storefront/Resources/app/storefront/ run development

        > sw-next-storefront@1.0.0 development
        > NODE_ENV=development webpack --config webpack.config.js

        # Webpack Plugin Injector: Plugin "Storefront" injected as a new entry point
        # Webpack Plugin Injector: Plugin "DmagTemplate" injected as a new entry point
        ℹ Compiling Shopware 6 Storefront
        node:internal/crypto/hash:71
          this[kHandle] = new _Hash(algorithm, xofLen);
                          ^

        Error: error:0308010C:digital envelope routines::unsupported
            at new Hash (node:internal/crypto/hash:71:19)
            at Object.createHash (node:crypto:133:10)
            at module.exports (/app/platform/src/Storefront/Resources/app/storefront/node_modules/webpack/lib/util/createHash.js:135:53)
            at NormalModule._initBuildHash (/app/platform/src/Storefront/Resources/app/storefront/node_modules/webpack/lib/NormalModule.js:412:16)
            at /app/platform/src/Storefront/Resources/app/storefront/node_modules/webpack/lib/NormalModule.js:444:10
            at /app/platform/src/Storefront/Resources/app/storefront/node_modules/webpack/lib/NormalModule.js:320:13
            at /app/platform/src/Storefront/Resources/app/storefront/node_modules/loader-runner/lib/LoaderRunner.js:367:11
            at /app/platform/src/Storefront/Resources/app/storefront/node_modules/loader-runner/lib/LoaderRunner.js:233:18
            at context.callback (/app/platform/src/Storefront/Resources/app/storefront/node_modules/loader-runner/lib/LoaderRunner.js:111:13)
            at /app/platform/src/Storefront/Resources/app/storefront/node_modules/babel-loader/lib/index.js:55:103 {
          opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ],
          library: 'digital envelope routines',
          reason: 'unsupported',
          code: 'ERR_OSSL_EVP_UNSUPPORTED'
        }

        Node.js v18.14.0

Execution aborted, a subcommand failed!

application@e47c10ef8b24:/app$ exit
exit

Execution aborted, a subcommand failed!

I suspect that the cause here is also the node version.

Actual behaviour

Exception on compiling a theme.

How to reproduce

change node version in container to 16.9.0