Vue-storefront: Error on yarn run. (TS specific?)

0

Current behavior

When trying to start the project using docker-compose up --build it failes on starting vue-storefront_app.

Expected behavior

Expecting project to run and container to be up and running.

Steps to reproduce the issue

Clone repository, using the standard mode.
Run docker-compose up --build.

Can you handle fixing this bug by yourself?

NO

Environment details

  • Browser: Version 72.0.3626.96
  • OS: Mac OS 10.14.3 (18D42)
  • Node: node:10-alpine

Additional information

Slack conversation:

Jens [9:22 AM]
Is anyone else experiencing this? on a clean install and `docker-compose up --build` 

pkarw (Core Team) [10:03 AM]
Hi @Jens are you on the most recent version 1.8?

Jens [10:08 AM]
I'm on latest master

pkarw (Core Team) [10:10 AM]
OK, could You please create a n issue for that? It need to be retested
You might want also to test rebuilding the images

as we’ve added the TS support for webcpack config
it looks like, this issue is related to TS support added in 1.8

Output

Building app Step 1/7 : FROM node:10-alpine ---> fe6ff768f798 Step 2/7 : ENV VS_ENV prod ---> Using cache ---> c128bf37369f Step 3/7 : WORKDIR /var/www ---> Using cache ---> 3059ffc1821e Step 4/7 : COPY package.json ./ ---> Using cache ---> 5b3e534da44f Step 5/7 : RUN apk add --no-cache --virtual .build-deps ca-certificates wget git && yarn install --no-cache && apk del .build-deps ---> Using cache ---> dea2e7d94e81 Step 6/7 : COPY docker/vue-storefront/vue-storefront.sh /usr/local/bin/ ---> Using cache ---> 9e9736618ddf Step 7/7 : CMD ["vue-storefront.sh"] ---> Using cache ---> 0cfe583e0d8c Successfully built 0cfe583e0d8c Successfully tagged vue-storefront_app:latest Starting vue-storefront_app_1 ... done Attaching to vue-storefront_app_1 app_1 | yarn install v1.13.0 app_1 | [1/5] Validating package.json... app_1 | [2/5] Resolving packages... app_1 | success Already up-to-date. app_1 | Done in 2.87s. app_1 | yarn run v1.13.0 app_1 | $ cross-env NODE_ENV=production TS_NODE_PROJECT="tsconfig-build.json" webpack --config ./core/build/webpack.prod.client.config.ts --mode production --progress --hide-modules app_1 | /var/www/core/build/webpack.prod.client.config.ts:1 app_1 | (function (exports, require, module, __filename, __dirname) { import path from 'path'; app_1 | ^^^^ app_1 | app_1 | SyntaxError: Unexpected identifier app_1 | at new Script (vm.js:79:7) app_1 | at NativeCompileCache._moduleCompile (/var/www/node_modules/webpack-cli/node_modules/v8-compile-cache/v8-compile-cache.js:226:18) app_1 | at Module._compile (/var/www/node_modules/webpack-cli/node_modules/v8-compile-cache/v8-compile-cache.js:172:36) app_1 | at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10) app_1 | at Module.load (internal/modules/cjs/loader.js:599:32) app_1 | at tryModuleLoad (internal/modules/cjs/loader.js:538:12) app_1 | at Function.Module._load (internal/modules/cjs/loader.js:530:3) app_1 | at Module.require (internal/modules/cjs/loader.js:637:17) app_1 | at require (/var/www/node_modules/webpack-cli/node_modules/v8-compile-cache/v8-compile-cache.js:159:20) app_1 | at WEBPACK_OPTIONS (/var/www/node_modules/webpack-cli/bin/convert-argv.js:115:13) app_1 | at requireConfig (/var/www/node_modules/webpack-cli/bin/convert-argv.js:117:6) app_1 | at /var/www/node_modules/webpack-cli/bin/convert-argv.js:124:17 app_1 | at Array.forEach (<anonymous>) app_1 | at module.exports (/var/www/node_modules/webpack-cli/bin/convert-argv.js:122:15) app_1 | at yargs.parse (/var/www/node_modules/webpack-cli/bin/cli.js:228:39) app_1 | at Object.parse (/var/www/node_modules/yargs/yargs.js:567:18) app_1 | at /var/www/node_modules/webpack-cli/bin/cli.js:206:8 app_1 | at Object.<anonymous> (/var/www/node_modules/webpack-cli/bin/cli.js:500:3) app_1 | at Module._compile (internal/modules/cjs/loader.js:689:30) app_1 | at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10) app_1 | at Module.load (internal/modules/cjs/loader.js:599:32) app_1 | at tryModuleLoad (internal/modules/cjs/loader.js:538:12) app_1 | at Function.Module._load (internal/modules/cjs/loader.js:530:3) app_1 | at Module.require (internal/modules/cjs/loader.js:637:17) app_1 | at require (internal/modules/cjs/helpers.js:22:18) app_1 | at Object.<anonymous> (/var/www/node_modules/webpack/bin/webpack.js:156:2) app_1 | at Module._compile (internal/modules/cjs/loader.js:689:30) app_1 | at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10) app_1 | at Module.load (internal/modules/cjs/loader.js:599:32) app_1 | at tryModuleLoad (internal/modules/cjs/loader.js:538:12) app_1 | error Command failed with exit code 1. app_1 | info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command. vue-storefront_app_1 exited with code 1

Jensderond picture Jensderond  ·  11 Feb 2019

Most helpful comment

3

@benjick I've done a checkout to v1.8.1 tag and had an error stated in the first post. Checkout to either v1.8.2 or latest master solves the issue for me. I cannot reproduce your problem.

Nevertheless, please, try docker-compose down && docker-compose rm && docker-compose up and make sure that your docker-compose.yml is not manually modified.

lukeromanowicz picture lukeromanowicz  ·  11 Feb 2019

All comments

0

Any workaround to get it up and running?

benjick picture benjick  ·  11 Feb 2019
1

Possibly related to #2269

lukeromanowicz picture lukeromanowicz  ·  11 Feb 2019
1

@lukeromanowicz that PR fixes the problem! 😄

Jensderond picture Jensderond  ·  11 Feb 2019
0

Still seeing this error, HEAD @ 928458f7cf43312986a03e5347e58782dcde7a94. Tried doing docker-compose build

benjick picture benjick  ·  11 Feb 2019
3

@benjick I've done a checkout to v1.8.1 tag and had an error stated in the first post. Checkout to either v1.8.2 or latest master solves the issue for me. I cannot reproduce your problem.

Nevertheless, please, try docker-compose down && docker-compose rm && docker-compose up and make sure that your docker-compose.yml is not manually modified.

lukeromanowicz picture lukeromanowicz  ·  11 Feb 2019
0

great. We had the same error on #2400
Today we will try it. thanks to all.

iacopop picture iacopop  ·  12 Feb 2019