Skip to content
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

Permission denied error (??) on Ubuntu 18.04.3 (LTS) x64 #91

Closed
2 tasks done
hems opened this issue Jan 3, 2020 · 16 comments
Closed
2 tasks done

Permission denied error (??) on Ubuntu 18.04.3 (LTS) x64 #91

hems opened this issue Jan 3, 2020 · 16 comments

Comments

@hems
Copy link

hems commented Jan 3, 2020

Prerequisites

  • Are you running the latest version?
    ^ as per documentation, i simply run git clone git@github.com:reactioncommerce/reaction-platform.git

  • Did you search the issue queue for existing issue? [Search issues]
    yes

Issue Description

I created a droplet on Digital Ocean, using Ubuntu 18.04.3 (LTS) x64 once i execute docker ps i can see the following images running:

35eed103c220        reactioncommerce/node-dev:10.16.3-v2   "tini -- /usr/local/…"   10 minutes ago      Up 10 minutes       0.0.0.0:4000->4000/tcp                                     example-storefront_web_1
96616bca9986        mongo:3.6.3                            "docker-entrypoint.s…"   11 minutes ago      Up 11 minutes       0.0.0.0:27017->27017/tcp                                   reaction_mongo_1
ee2b4734c6ec        oryd/hydra:v1.0.0-beta.9-alpine        "hydra serve all --d…"   17 minutes ago      Up 17 minutes       0.0.0.0:4444-4445->4444-4445/tcp, 0.0.0.0:5555->5555/tcp   reaction-hydra_hydra_1
6ff41c37fe05        postgres:10.3                          "docker-entrypoint.s…"   17 minutes ago      Up 17 minutes       0.0.0.0:32768->5432/tcp                                    reaction-hydra_postgres_1

On the documentation it says i should have example-storefront_web running, but it's not running after make.

Steps to Reproduce

Please provide starting context, i.e. logged in as a user, configure a particular payment method.

  1. Create Ubuntu box
  2. Login with root
  3. Install Node.js ( i installed version 13 )
  4. Install docker
  5. run make
@hems
Copy link
Author

hems commented Jan 3, 2020

Found this out:

cd example-storefront
docker-compose logs -f

Then open another window and do:

curl http://localhost:4000

I will get the following error on the first window:

web_1  | > Building page: /productGrid
web_1  |  WAIT  Compiling...7:49:47 PM
web_1  |
web_1  | [7:49:48 PM] Compiling server
web_1  | [7:49:48 PM] Compiling client
web_1  | [7:49:49 PM] Compiled client in 1s
web_1  |  DONE  Compiled successfully in 1509ms7:49:49 PM
web_1  |
web_1  | [7:49:49 PM] Compiled server in 2s
web_1  | Unable to access the GraphQL API. Is it running and accessible at http://reaction.api.reaction.localhost:3000/graphql-beta from the Storefront UI server?
web_1  | { Error: Network error: request to http://reaction.api.reaction.localhost:3000/graphql-beta failed, reason: getaddrinfo ENOTFOUND reaction.api.reaction.localhost reaction.api.reaction.localhost:3000
web_1  |     at new ApolloError (/usr/local/src/app/node_modules/apollo-client/bundle.umd.js:99:32)
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:978:45
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:1345:21
web_1  |     at Array.forEach (<anonymous>)
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:1344:22
web_1  |     at Map.forEach (<anonymous>)
web_1  |     at QueryManager.broadcastQueries (/usr/local/src/app/node_modules/apollo-client/bundle.umd.js:1339:26)
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:928:35
web_1  |     at process._tickCallback (internal/process/next_tick.js:68:7)
web_1  |   graphQLErrors: [],
web_1  |   networkError:
web_1  |    { FetchError: request to http://reaction.api.reaction.localhost:3000/graphql-beta failed, reason: getaddrinfo ENOTFOUND reaction.api.reaction.localhost reaction.api.reaction.localhost:3000
web_1  |        at ClientRequest.<anonymous> (/usr/local/src/app/node_modules/node-fetch/index.js:133:11)
web_1  |        at ClientRequest.emit (events.js:198:13)
web_1  |        at Socket.socketErrorListener (_http_client.js:392:9)
web_1  |        at Socket.emit (events.js:198:13)
web_1  |        at emitErrorNT (internal/streams/destroy.js:91:8)
web_1  |        at emitErrorAndCloseNT (internal/streams/destroy.js:59:3)
web_1  |        at process._tickCallback (internal/process/next_tick.js:63:19)
web_1  |      name: 'FetchError',
web_1  |      message:
web_1  |       'request to http://reaction.api.reaction.localhost:3000/graphql-beta failed, reason: getaddrinfo ENOTFOUND reaction.api.reaction.localhost reaction.api.reaction.localhost:3000',
web_1  |      type: 'system',
web_1  |      errno: 'ENOTFOUND',
web_1  |      code: 'ENOTFOUND' },
web_1  |   message:
web_1  |    'Network error: request to http://reaction.api.reaction.localhost:3000/graphql-beta failed, reason: getaddrinfo ENOTFOUND reaction.api.reaction.localhost reaction.api.reaction.localhost:3000',
web_1  |   extraInfo: undefined }
web_1  | Unable to access the GraphQL API. Is it running and accessible at http://reaction.api.reaction.localhost:3000/graphql-beta from the Storefront UI server?
web_1  | { Error: Network error: request to http://reaction.api.reaction.localhost:3000/graphql-beta failed, reason: getaddrinfo ENOTFOUND reaction.api.reaction.localhost reaction.api.reaction.localhost:3000
web_1  |     at new ApolloError (/usr/local/src/app/node_modules/apollo-client/bundle.umd.js:99:32)
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:978:45
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:1345:21
web_1  |     at Array.forEach (<anonymous>)
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:1344:22
web_1  |     at Map.forEach (<anonymous>)
web_1  |     at QueryManager.broadcastQueries (/usr/local/src/app/node_modules/apollo-client/bundle.umd.js:1339:26)
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:928:35
web_1  |     at process._tickCallback (internal/process/next_tick.js:68:7)
web_1  |   graphQLErrors: [],
web_1  |   networkError:
web_1  |    { FetchError: request to http://reaction.api.reaction.localhost:3000/graphql-beta failed, reason: getaddrinfo ENOTFOUND reaction.api.reaction.localhost reaction.api.reaction.localhost:3000
web_1  |        at ClientRequest.<anonymous> (/usr/local/src/app/node_modules/node-fetch/index.js:133:11)
web_1  |        at ClientRequest.emit (events.js:198:13)
web_1  |        at Socket.socketErrorListener (_http_client.js:392:9)
web_1  |        at Socket.emit (events.js:198:13)
web_1  |        at emitErrorNT (internal/streams/destroy.js:91:8)
web_1  |        at emitErrorAndCloseNT (internal/streams/destroy.js:59:3)
web_1  |        at process._tickCallback (internal/process/next_tick.js:63:19)
web_1  |      name: 'FetchError',
web_1  |      message:
web_1  |       'request to http://reaction.api.reaction.localhost:3000/graphql-beta failed, reason: getaddrinfo ENOTFOUND reaction.api.reaction.localhost reaction.api.reaction.localhost:3000',
web_1  |      type: 'system',
web_1  |      errno: 'ENOTFOUND',
web_1  |      code: 'ENOTFOUND' },
web_1  |   message:
web_1  |    'Network error: request to http://reaction.api.reaction.localhost:3000/graphql-beta failed, reason: getaddrinfo ENOTFOUND reaction.api.reaction.localhost reaction.api.reaction.localhost:3000',
web_1  |   extraInfo: undefined }
web_1  | Unable to access the GraphQL API. Is it running and accessible at http://reaction.api.reaction.localhost:3000/graphql-beta from the Storefront UI server?
web_1  | (node:72) UnhandledPromiseRejectionWarning: Error: Network error: request to http://reaction.api.reaction.localhost:3000/graphql-beta failed, reason: getaddrinfo ENOTFOUND reaction.api.reaction.localhost reaction.api.reaction.localhost:3000
web_1  |     at new ApolloError (/usr/local/src/app/node_modules/apollo-client/bundle.umd.js:99:32)
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:978:45
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:1345:21
web_1  |     at Array.forEach (<anonymous>)
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:1344:22
web_1  |     at Map.forEach (<anonymous>)
web_1  |     at QueryManager.broadcastQueries (/usr/local/src/app/node_modules/apollo-client/bundle.umd.js:1339:26)
web_1  |     at /usr/local/src/app/node_modules/apollo-client/bundle.umd.js:928:35
web_1  |     at process._tickCallback (internal/process/next_tick.js:68:7)
web_1  | (node:72) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 9)

@hems
Copy link
Author

hems commented Jan 3, 2020

I did make start afterwards to see what happens, turns out reaction_reaction will start but then it will shutdown.

have a look on this screenshot:

image

@spencern
Copy link
Contributor

spencern commented Jan 3, 2020

How much ram are you running with?

@hems
Copy link
Author

hems commented Jan 3, 2020

How much ram are you running with?

In order to make sure i started a new machine with 4GB RAM, installed virtual box manager and followed the instructions found here, which basically is:

docker-machine stop
VBoxManage modifyvm default --cpus 2
VBoxManage modifyvm default --memory 4096
docker-machine start

Once done that, i cloned the repo again and did execute make, this time i got a couple funny messages at the start, probably because i tried to run it before installing docker-compose once, and then installed docker-compose, then run it again.

root@reaction-commerce:~/reaction-platform# make
Error response from daemon: network with name auth.reaction.localhost already exists
Error response from daemon: network with name api.reaction.localhost already exists
Error response from daemon: network with name streams.reaction.localhost already exists
Running pre-build hook script for reaction-hydra.
reaction-hydra post-project-start script invoked.
postgres uses an image, skipping
...

Once that finished i did docker ps and got pretty much the same result:

root@reaction-commerce:~/reaction-platform# docker ps
CONTAINER ID        IMAGE                                  COMMAND                  CREATED             STATUS              PORTS                                                      NAMES
babf278c2b00        reactioncommerce/node-dev:10.16.3-v2   "tini -- /usr/local/…"   2 minutes ago       Up 2 minutes        0.0.0.0:4000->4000/tcp                                     example-storefront_web_1
0c9d53ea777f        mongo:3.6.3                            "docker-entrypoint.s…"   2 minutes ago       Up 2 minutes        0.0.0.0:27017->27017/tcp                                   reaction_mongo_1
bafeb0190e2b        oryd/hydra:v1.0.0-beta.9-alpine        "hydra serve all --d…"   7 minutes ago       Up 7 minutes        0.0.0.0:4444-4445->4444-4445/tcp, 0.0.0.0:5555->5555/tcp   reaction-hydra_hydra_1
5a1904cf58dd        postgres:10.3                          "docker-entrypoint.s…"   7 minutes ago       Up 7 minutes        0.0.0.0:32768->5432/tcp                                    reaction-hydra_postgres_1

i can then do make stop then make start and i will get the following result for docker ps

CONTAINER ID        IMAGE                                  COMMAND                  CREATED             STATUS              PORTS                                                      NAMES
babf278c2b00        reactioncommerce/node-dev:10.16.3-v2   "tini -- /usr/local/…"   6 minutes ago       Up 2 seconds        0.0.0.0:4000->4000/tcp                                     example-storefront_web_1
33dbd91f7df3        reaction_reaction                      "bash -c 'time meteo…"   7 minutes ago       Up 4 seconds        0.0.0.0:3000->3000/tcp, 0.0.0.0:9229->9229/tcp             reaction_reaction_1
0c9d53ea777f        mongo:3.6.3                            "docker-entrypoint.s…"   7 minutes ago       Up 6 seconds        0.0.0.0:27017->27017/tcp                                   reaction_mongo_1
bafeb0190e2b        oryd/hydra:v1.0.0-beta.9-alpine        "hydra serve all --d…"   11 minutes ago      Up 8 seconds        0.0.0.0:4444-4445->4444-4445/tcp, 0.0.0.0:5555->5555/tcp   reaction-hydra_hydra_1
5a1904cf58dd        postgres:10.3                          "docker-entrypoint.s…"   11 minutes ago      Up 11 seconds       0.0.0.0:32769->5432/tcp                                    reaction-hydra_postgres_1

Looking at reaction_1 logs i found something funny about a permission error tough..

Check the "permission denied" error..

reaction_1  | npm WARN saveError EACCES: permission denied, open '/opt/reaction/src/package-lock.json.2993279708'
reaction_1  | npm WARN @apollo/react-common@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-components@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-hoc@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-hooks@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-testing@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/catalyst@1.12.0 requires a peer of prop-types@~15.6.2 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/catalyst@1.12.0 requires a peer of react-dom@~16.9.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN mdi-material-ui@5.8.0 requires a peer of @material-ui/core@^1.0.0 || ^3.0.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/components@0.67.2 requires a peer of react@~16.9.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/components@0.67.2 requires a peer of reacto-form@~1.4.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/components@0.67.2 requires a peer of styled-components@~3.3.3 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/eslint-config@2.1.0 requires a peer of eslint-plugin-promise@>=4 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN acorn-jsx@5.0.1 requires a peer of acorn@^6.0.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN apollo-graphql@0.3.3 requires a peer of graphql@^14.2.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN eslint-plugin-import@2.12.0 requires a peer of eslint@2.x - 4.x but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN eslint-plugin-jsx-a11y@6.1.1 requires a peer of eslint@^3 || ^4 || ^5 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN eslint-plugin-react@7.8.2 requires a peer of eslint@^3.0.0 || ^4.0.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN graphql-iso-date@3.5.0 requires a peer of graphql@^0.5.0 || ^0.6.0 || ^0.7.0 || ^0.8.0-b || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN graphql-relay@0.5.5 requires a peer of graphql@^0.5.0 || ^0.6.0 || ^0.7.0 || ^0.8.0-b || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN graphql-tag@2.9.2 requires a peer of graphql@^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN react-addons-test-utils@15.6.2 requires a peer of react-dom@^15.4.2 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN react-apollo@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-runtime/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-runner/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-haste-map/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-config/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/test-sequencer/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/reporters/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/environment/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/core/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  |
reaction_1  | added 4 packages from 2 contributors in 52.915s
reaction_1  |
reaction_1  | real	0m56.126s
reaction_1  | user	0m44.000s
reaction_1  | sys	0m5.598s
reaction_1  | MongoDB replica set initialized and ready.
reaction_1  | (node:52) ExperimentalWarning: The ESM module loader is experimental.
reaction_1  | Setting up plugin imports...
reaction_1  |
reaction_1  | Failed to reset plugins file at /opt/reaction/src/client/plugins.js
reaction_1  | npm WARN saveError EACCES: permission denied, open '/opt/reaction/src/package-lock.json.1741052225'
reaction_1  | npm WARN @apollo/react-common@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-components@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-hoc@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-hooks@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-testing@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/catalyst@1.12.0 requires a peer of prop-types@~15.6.2 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/catalyst@1.12.0 requires a peer of react-dom@~16.9.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN mdi-material-ui@5.8.0 requires a peer of @material-ui/core@^1.0.0 || ^3.0.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/components@0.67.2 requires a peer of react@~16.9.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/components@0.67.2 requires a peer of reacto-form@~1.4.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/components@0.67.2 requires a peer of styled-components@~3.3.3 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/eslint-config@2.1.0 requires a peer of eslint-plugin-promise@>=4 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN acorn-jsx@5.0.1 requires a peer of acorn@^6.0.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN apollo-graphql@0.3.3 requires a peer of graphql@^14.2.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN eslint-plugin-import@2.12.0 requires a peer of eslint@2.x - 4.x but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN eslint-plugin-jsx-a11y@6.1.1 requires a peer of eslint@^3 || ^4 || ^5 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN eslint-plugin-react@7.8.2 requires a peer of eslint@^3.0.0 || ^4.0.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN graphql-iso-date@3.5.0 requires a peer of graphql@^0.5.0 || ^0.6.0 || ^0.7.0 || ^0.8.0-b || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN graphql-relay@0.5.5 requires a peer of graphql@^0.5.0 || ^0.6.0 || ^0.7.0 || ^0.8.0-b || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN graphql-tag@2.9.2 requires a peer of graphql@^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN react-addons-test-utils@15.6.2 requires a peer of react-dom@^15.4.2 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN react-apollo@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-runtime/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-runner/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-haste-map/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-config/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/test-sequencer/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/reporters/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/environment/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/core/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  |
reaction_1  | added 4 packages from 2 contributors in 46.854s
reaction_1  |
reaction_1  | real	0m48.555s
reaction_1  | user	0m43.296s
reaction_1  | sys	0m4.113s
reaction_1  | MongoDB replica set initialized and ready.
reaction_1  | (node:47) ExperimentalWarning: The ESM module loader is experimental.
reaction_1  | Setting up plugin imports...
reaction_1  |
reaction_1  | Failed to reset plugins file at /opt/reaction/src/client/plugins.js

@hems hems changed the title Problem installing on 18.04.3 (LTS) x64 Permission denied error (??) on Ubuntu 18.04.3 (LTS) x64 Jan 3, 2020
@spencern
Copy link
Contributor

spencern commented Jan 8, 2020

That permission error makes me think that there are some file permissions that need to be changed on your machine in order for npm to install dependencies properly.

@willopez have you installed on Ubuntu before?

@willopez
Copy link
Member

willopez commented Jan 8, 2020

@hems change the ownership of the reaction installation directory like so:

chown -R youruser:youruser: reaction_install_directory

and also set the permissions of the same directory like so:

chmod -R 755 reaction_install_directory

and then restart the Docker service by executing:

docker-compose down && docker-compose up

@hems
Copy link
Author

hems commented Jan 8, 2020

@willopez thanks for your suggestion, i tried changing the permissions all around but still go that error.

reaction_1  |
reaction_1  | added 4 packages from 2 contributors in 40.219s
reaction_1  |
reaction_1  | real	0m41.274s
reaction_1  | user	0m37.360s
reaction_1  | sys	0m3.790s
reaction_1  | MongoDB replica set initialized and ready.
reaction_1  | (node:47) ExperimentalWarning: The ESM module loader is experimental.
reaction_1  | Setting up plugin imports...
reaction_1  |
reaction_1  | Failed to reset plugins file at /opt/reaction/src/client/plugins.js
reaction_reaction_1 exited with code 1

i suspect that error is inside the container on docker so chown and chmod wouldn't change much ?

or maybe i have to rebuild an image because of those permission changes?

any ideas?

@willopez
Copy link
Member

willopez commented Jan 8, 2020

try rebuilding the image

@hems
Copy link
Author

hems commented Jan 8, 2020

try rebuilding the image

will do by using docker system prune and then make, is that correct?

@willopez
Copy link
Member

willopez commented Jan 8, 2020

you should only need to remove the Reaction image:

docker-compose down --rmi all 

and then docker-compose up and the image will be rebuilt.

@hems
Copy link
Author

hems commented Jan 8, 2020

and then docker-compose up and the image will be rebuilt.

I tried previously with system prune then make and it did not see to work, I'm doing now only he reaction folder, hopefully, it will not yield the error.

@hems
Copy link
Author

hems commented Jan 8, 2020

unfortunately, ended up with the same error.

reaction_1  | npm WARN saveError EACCES: permission denied, open '/opt/reaction/src/package-lock.json.1752014446'
reaction_1  | npm WARN @apollo/react-common@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-components@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-hoc@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-hooks@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @apollo/react-testing@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/catalyst@1.12.0 requires a peer of prop-types@~15.6.2 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/catalyst@1.12.0 requires a peer of react-dom@~16.9.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN mdi-material-ui@5.8.0 requires a peer of @material-ui/core@^1.0.0 || ^3.0.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/components@0.67.2 requires a peer of react@~16.9.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/components@0.67.2 requires a peer of reacto-form@~1.4.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/components@0.67.2 requires a peer of styled-components@~3.3.3 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN @reactioncommerce/eslint-config@2.1.0 requires a peer of eslint-plugin-promise@>=4 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN acorn-jsx@5.0.1 requires a peer of acorn@^6.0.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN apollo-graphql@0.3.3 requires a peer of graphql@^14.2.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN eslint-plugin-import@2.12.0 requires a peer of eslint@2.x - 4.x but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN eslint-plugin-jsx-a11y@6.1.1 requires a peer of eslint@^3 || ^4 || ^5 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN eslint-plugin-react@7.8.2 requires a peer of eslint@^3.0.0 || ^4.0.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN graphql-iso-date@3.5.0 requires a peer of graphql@^0.5.0 || ^0.6.0 || ^0.7.0 || ^0.8.0-b || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN graphql-relay@0.5.5 requires a peer of graphql@^0.5.0 || ^0.6.0 || ^0.7.0 || ^0.8.0-b || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN graphql-tag@2.9.2 requires a peer of graphql@^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN react-addons-test-utils@15.6.2 requires a peer of react-dom@^15.4.2 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN react-apollo@3.0.0 requires a peer of graphql@^14.3.1 but none is installed. You must install peer dependencies yourself.
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-runtime/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-runner/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-haste-map/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/jest-config/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/test-sequencer/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/reporters/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/environment/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  | npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/@jest/core/node_modules/fsevents):
reaction_1  | npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
reaction_1  |
reaction_1  | added 4 packages from 2 contributors in 32.032s
reaction_1  |
reaction_1  | real	0m33.550s
reaction_1  | user	0m31.990s
reaction_1  | sys	0m3.287s
mongo_1     | 2020-01-08T23:34:04.657+0000 I NETWORK  [listener] connection accepted from 172.25.0.3:39716 #1 (1 connection now open)
mongo_1     | 2020-01-08T23:34:04.665+0000 I NETWORK  [conn1] received client metadata from 172.25.0.3:39716 conn: { driver: { name: "nodejs", version: "3.1.13" }, os: { type: "Linux", name: "linux", architecture: "x64", version: "4.15.0-66-generic" }, platform: "Node.js v8.11.4, LE, mongodb-core: 3.1.11" }
mongo_1     | 2020-01-08T23:34:04.676+0000 I REPL     [conn1] replSetInitiate admin command received from client
reaction_1  | MongoDB replica set initialized and ready.
mongo_1     | 2020-01-08T23:34:04.683+0000 I NETWORK  [conn1] end connection 172.25.0.3:39716 (0 connections now open)
reaction_1  | (node:47) ExperimentalWarning: The ESM module loader is experimental.
reaction_1  | Setting up plugin imports...
reaction_1  |
reaction_1  | Failed to reset plugins file at /opt/reaction/src/client/plugins.js

@willopez
Copy link
Member

willopez commented Jan 9, 2020

it looks like somehow, perhaps you are installing reaction as a root user, the node_modules is most likely owned by root which will cause issues. Inside the Docker container, the /opt/reaction/src directory and node_modules within should be owned by user node with user id 1000. Seems, that the root cause of your issues, is installing Reaction as a root user. I would recommend that you create a new user as shown in this article: https://www.digitalocean.com/community/tutorials/initial-server-setup-with-ubuntu-18-04

And then run the Reaction platform installation from the beginning, make sure you prune your entire Docker system to avoid any issues, docker system prune

@mikelxc
Copy link

mikelxc commented Jan 15, 2020

I actually ran in to the same problem a couple days ago. The system runs perfectly on my Mac, but fails to build and run properly on my ubuntu server. And here's another I ran across while building reaction.

> mongodb-memory-server@5.2.8 postinstall /opt/reaction/src/node_modules/@shelf/jest-mongodb/node_modules/mongodb-memory-server
> node ./postinstall.js

(node:27) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 SIGINT listeners added. Use emitter.setMaxListeners() to increase limit
Could not resolve postinstall configuration

It just occurs to me that there might be a problem with the mongodb installation that causes this problem.

@aldeed
Copy link
Contributor

aldeed commented Feb 6, 2020

@mikelxc mongodb-memory-server was removed so that shouldn't be an issue anymore. Can you try on 3.0 (latest trunk branch of platform repo) and see if permission issues are resolved? With the permission issues, the problem is that Docker caches volumes in various ways and it seems to be difficult to get it to clear all the caches where incorrect permissions might have become stuck. If you do a system prune, be sure to use --volumes flag on it. Or docker-compose down -v in the reaction folder should also do it.

@Akarshit
Copy link
Contributor

This shouldn't be an issue with the latest version. Please re-open if someone is still encountering this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants