reactioncommerce / reaction-development-platform

Reaction Platform is the quickest way to run Reaction (reactioncommerce/reaction) and dependent services—Reaction Admin (reactioncommerce/reaction-admin) and Example Storefront (reactioncommerce/example-storefront)
https://mailchimp.com/developer/open-commerce/
GNU General Public License v3.0
228 stars 194 forks source link

The OAuth2 request resulted in an error. / Error: invalid_client #41

Closed Kanabanarama closed 5 years ago

Kanabanarama commented 5 years ago

With latest version and docker 18.09.0 Just cloning repository and make finishing without errors, the web ui works fine, but login is broken. localhost:4444 greets me with Error: invalid_client

After make, the following networks are available:

c18b988d7bb8        api.reaction.localhost             bridge              local
3b0cfb9dd126        auth.reaction.localhost            bridge              local
468075df3073        reaction-hydra_default             bridge              local
c6b6f43cb18f        reaction_default                   bridge              local
dd4bbbffd279        streams.reaction.localhost         bridge              local

The following (hydra) containers are running:

bcd94d4ec569        oryd/hydra:v1.0.0-beta.9-alpine         "hydra serve all --d…"   About an hour ago   Up 7 minutes                   0.0.0.0:4444-4445->4444-4445/tcp, 0.0.0.0:5555->5555/tcp   reaction-hydra_hydra_1
3b3dbcfcc726        oryd/hydra:v1.0.0-beta.9-alpine         "hydra migrate sql -e"   About an hour ago   Exited (0) 4 minutes ago                                                                  reaction-hydra_hydra-migrate_1
b593b1ffeef6        postgres:10.3                           "docker-entrypoint.s…"   About an hour ago   Up 7 minutes                   0.0.0.0:32770->5432/tcp                                    reaction-hydra_postgres_1

Docker logs of reaction-hydra_hydra_1:

time="2019-01-10T07:52:36Z" level=info msg="Connected to SQL!"
time="2019-01-10T07:52:36Z" level=info msg="Setting up Prometheus middleware"
time="2019-01-10T07:52:36Z" level=info msg="Transmission of telemetry data is enabled, to learn more go to: https://www.ory.sh/docs/guides/latest/telemetry/"
time="2019-01-10T07:52:36Z" level=info msg="Detected local environment, skipping telemetry commit"
time="2019-01-10T07:52:36Z" level=info msg="Detected local environment, skipping telemetry commit"
time="2019-01-10T07:52:36Z" level=info msg="Setting up http server on :4445"
time="2019-01-10T07:52:36Z" level=warning msg="HTTPS disabled. Never do this in production."
time="2019-01-10T07:52:36Z" level=info msg="Setting up http server on :4444"
time="2019-01-10T07:52:36Z" level=warning msg="HTTPS disabled. Never do this in production."
time="2019-01-10T07:55:19Z" level=info msg="started handling request" method=GET remote="172.20.0.1:56286" request="/oauth2/auth?response_type=code&redirect_uri=http%3A%2F%2Flocalhost%3A4000%2Fcallback&scope=offline%20openid&state=6Ne2FHijWWEVsxDWlyAeI0Mi&client_id=reaction-next-starterkit"
time="2019-01-10T07:55:19Z" level=error msg="An error occurred" description="Client authentication failed (e.g., unknown client, no client authentication included, or unsupported authentication method)" error=invalid_client hint="The requested OAuth 2.0 Client does not exist."
time="2019-01-10T07:55:19Z" level=info msg="completed handling request" measure#http://localhost:4444.latency=1930652 method=GET remote="172.20.0.1:56286" request="/oauth2/auth?response_type=code&redirect_uri=http%3A%2F%2Flocalhost%3A4000%2Fcallback&scope=offline%20openid&state=6Ne2FHijWWEVsxDWlyAeI0Mi&client_id=reaction-next-starterkit" status=302 text_status=Found took=1.930652ms
spencern commented 5 years ago

@impactmass can you take a look at this?

focusaurus commented 5 years ago

Could you check the starterkit logs with docker-compose -f reaction-next-starterkit/docker-compose.yml logs -f web please and post those? That's where the reaction-next-starterkit/bin/create-hydra-client.js script gets run. Your error seems like that might not have succeeded. Restarting the reaction-next-starterkit "web" service may also help since the create-hydra-client.js script runs on start.

impactmass commented 5 years ago

thanks @focusaurus.

@Kanabanarama as was mentioned, it looks like the client creation failed.

Here's logs from a fresh hydra install which had a successful client creation (note the last log):

hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:27Z" level=info msg="Connected to SQL!"
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:27Z" level=info msg="JSON Web Key Set hydra.openid.id-token does not exist yet, generating new key pair..."
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:28Z" level=info msg="Setting up Prometheus middleware"
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:28Z" level=info msg="Transmission of telemetry data is enabled, to learn more go to: https://www.ory.sh/docs/guides/latest/telemetry/"
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:28Z" level=info msg="Detected local environment, skipping telemetry commit"
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:28Z" level=info msg="Detected local environment, skipping telemetry commit"
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:28Z" level=info msg="JSON Web Key Set hydra.https-tls does not exist yet, generating new key pair..."
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:29Z" level=info msg="Setting up http server on :4445"
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:29Z" level=warning msg="HTTPS disabled. Never do this in production."
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:29Z" level=info msg="Setting up http server on :4444"
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:29Z" level=warning msg="HTTPS disabled. Never do this in production."
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:33Z" level=info msg="started handling request" method=POST remote="172.26.0.4:36864" request=/clients
hydra_1_e7e3e84a9eab | time="2019-01-10T17:07:33Z" level=info msg="completed handling request" measure#http://localhost:4444.latency=78738323 method=POST remote="172.26.0.4:36864" request=/clients status=201 text_status=Created took=78.738323ms

A restart of the reaction-next-starterkit should fix it.

Kanabanarama commented 5 years ago

Logs of reaction-next-starterkit:

Attaching to reaction-next-starterkit_web_1
web_1  | yarn install v1.12.3
web_1  | [1/4] Resolving packages...
web_1  | [2/4] Fetching packages...
web_1  | error An unexpected error occurred: "EACCES: permission denied, copyfile '/home/node/.cache/yarn/v4/npm-@babel-runtime-7.0.0-adeb78fedfc855aa05bc041640f3f6f98e85424c/node_modules/@babel/runtime/.yarn-tarball.tgz' -> '/home/node/.cache/yarn-offline-mirror/@babel-runtime-7.0.0.tgz'".
web_1  | info If you think this is a bug, please open a bug report with the information provided in "/usr/local/src/reaction-app/yarn-error.log".
web_1  | info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
reaction-next-starterkit_web_1 exited with code 1
impactmass commented 5 years ago

@Kanabanarama going by the EACCES: permission denied error, it looks like the starterkit container could not get access to the yarn cache. This could have happened because of an error on previous install attempt.

The yarn cache is in a docker volume [web-yarn](https://github.com/reactioncommerce/reaction-next-starterkit/blob/develop/docker-compose.yml#L31).

You can remove that volume docker volume rm reaction-next-starterkit_web-yarn. Or you can just docker-compose down -v in the starterkit folder. Then docker-compose up again.

Kanabanarama commented 5 years ago

Ok, this error happened later from trying to get it to work. With fresh containers the web container starts without errors, but I am still getting an oauth error page.

Attaching to reaction-next-starterkit_web_1
web_1  | yarn install v1.12.3
web_1  | [1/4] Resolving packages...
web_1  | success Already up-to-date.
web_1  | Done in 0.65s.
web_1  | yarn run v1.12.3
web_1  | $ NODE_ENV=development babel-node ./src/server.js
web_1  | > Using external babel configuration
web_1  | > Location: "/usr/local/src/reaction-app/.babelrc"
web_1  |  DONE  Compiled successfully in 5388ms13:53:37
web_1  | Server started ! ✓
web_1  | http://localhost:4000
web_1  | Press CTRL-C to stop
web_1  |     
web_1  | > Building page: /productGrid
web_1  |  DONE  Compiled successfully in 2105ms13:54:29
web_1  | Warning: The "extend" API will be removed in the upcoming v4.0 release. Use styled(StyledComponent) instead. You can find more information here: https://github.com/styled-components/styled-components/issues/1546
web_1  |  WAIT  Compiling...13:54:31
web_1  |  DONE  Compiled successfully in 150ms13:54:32
web_1  | > Disposing inactive page(s): /productGrid
web_1  |  DONE  Compiled successfully in 231ms13:55:37

I noticed that the make script checks out the master branch of the starterkit, but master does not have the mentioned create-hydra-client.js. I tried checking out the develop branch, but then those node EACCESS errors happen.

focusaurus commented 5 years ago

@spencern starterkit master branch hasn't been updated in 4 months. Seems like we should get rc8 out the door and update everything to use the new release-latest convention and configure reaction-platform to checkout that by default. Thoughts?

focusaurus commented 5 years ago

@Kanabanarama you'll definitely want the develop branch checked out. Your EACCESS errors might be fixed by running this command on your host: sudo chown -R 1000 ~/.cache/yarn. I think the issue is some versions of the docker image run as root and some as node (userid 1000 in the container) and switching between branches has put root-owned files/dirs in your yarn cache.

Kanabanarama commented 5 years ago

You're right, the storefront creates root owned cache files on the host. The command had to be sudo chown -R 1000 ~/.cache/yarn-offline-mirror. Then the image is build without problems and the hydra-client is coming up.

Why does your makefile utilize the hosts npm/yarn environment? As this is only for installing packages, couldn't that be done within with an disposable container or would that entail any drawbacks? I could make a PR if you want.

Anyway thanks, you're the friendliest maintainers alive :+1:

impactmass commented 5 years ago

@Kanabanarama good to know you got things working now.

Feel free to make an issue for the npm/yarn enhancement you talked about (and a PR too if you can).

I'll close this one as resolved.

focusaurus commented 5 years ago

@Kanabanarama I believe technically we do not currently run npm or yarn in the host OS via the reaction-platform Makefile. I filed this issue on that repo a while back to discuss removing them as required dependencies. Feel free to chime in there or throw a thumbs up reaction if you agree.

spencern commented 5 years ago

Thanks @focusaurus - rc.8 is released now for `reaction. Will release a matching rc.8 for the starterkit

Moumouls commented 5 years ago

@spencern , just here to notice people who are blocked with the EACCESS, on Mac OSX with latest Docker release 2.0.0.2, i'm currently using this config for make:

define SUBPROJECT_REPOS
git@github.com:/reactioncommerce/reaction-hydra.git,reaction-hydra,release-2.0.0-rc.9 \
git@github.com:/reactioncommerce/reaction.git,reaction,release-2.0.0-rc.9 \
git@github.com:/reactioncommerce/reaction-next-starterkit.git,reaction-next-starterkit,release-v2.0.0-rc.9
endef

I have replaced /node to /root for somes volumes in the docker-compose.yml of reaction-next-starterkit and it works :

- $HOME/.cache/yarn-offline-mirror:/home/root/.cache/yarn-offline-mirror
- web-yarn:/home/root/.cache/yarn
aktywnitu commented 5 years ago

I have similar problem: https://screenshotscdn.firefoxusercontent.com/images/ba1816c8-78db-4f92-b1f0-3b1bd3236e6e.png

hydra_1 | time="2019-01-24T17:54:05Z" level=error msg="An error occurred" description="Client authentication failed (e.g., unknown client, no client authentication included, or unsupported authentication method)" error=invalid_client hint="The requested OAuth 2.0 Client does not exist."`

Here is my reactiion-platform docker installation log:

`tom@laptopek:~/reaction-platform-master$ make
if [ ! -d "reaction-hydra" ] ; then git clone "git@github.com:/reactioncommerce/reaction-hydra.git" "reaction-hydra"; cd reaction-hydra && git checkout "master"; fi                                                      
Cloning into 'reaction-hydra'...                                                                             
remote: Enumerating objects: 3, done.
remote: Counting objects: 100% (3/3), done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 104 (delta 0), reused 2 (delta 0), pack-reused 101
Receiving objects: 100% (104/104), 26.41 KiB | 0 bytes/s, done.                                              
Resolving deltas: 100% (38/38), done.                                                                        
Checking connectivity... done.                                                                               
Already on 'master'                                                                                          
Your branch is up-to-date with 'origin/master'.                                                              
ce9bd63c46bef77f15389c43998e2fde8e6de0fff3e346f3191a93f6b54cdb6e                                             
217f1af45b75cb464c79213dd1baccfab331b956e2d0126137945293f2a85ff4
e8b1b662d00549d09a178275e6ff1b4a74481f905e9bb30d2fd9deae4c11376a
Running pre-build hook script for reaction-hydra.
reaction-hydra post-project-start script invoked.
postgres uses an image, skipping
hydra-migrate uses an image, skipping
hydra uses an image, skipping
Running post-build hook script for reaction-hydra.
reaction-hydra post-build script invoked.
Creating network "reaction-hydra_default" with the default driver
Creating volume "reaction-hydra_postgres-data" with default driver
Creating reaction-hydra_postgres_1 ... done
Creating reaction-hydra_hydra-migrate_1 ... done
Creating reaction-hydra_hydra_1         ... done
Running post-project-start hook script for reaction-hydra.
reaction-hydra post-project-start script invoked.
if [ ! -d "reaction" ] ; then git clone "git@github.com:/reactioncommerce/reaction.git" "reaction"; cd reaction && git checkout "master"; fi
Cloning into 'reaction'...
remote: Enumerating objects: 5, done.
remote: Counting objects: 100% (5/5), done.
remote: Compressing objects: 100% (5/5), done.
remote: Total 155897 (delta 0), reused 1 (delta 0), pack-reused 155892
Receiving objects: 100% (155897/155897), 71.54 MiB | 442.00 KiB/s, done.
Resolving deltas: 100% (89890/89890), done.
Checking connectivity... done.
Already on 'master'
Your branch is up-to-date with 'origin/master'.
Running pre-build hook script for reaction.
reaction post-project-start script invoked.
Adding HYDRA_ADMIN_URL to .env
Adding HYDRA_OAUTH2_INTROSPECT_URL to .env
Adding HYDRA_TOKEN_URL to .env
Adding METEOR_DISABLE_OPTIMISTIC_CACHING to .env
Adding METEOR_WATCH_POLLING_INTERVAL_MS to .env
Adding MONGO_OPLOG_URL to .env
Adding MONGO_URL to .env
Adding OAUTH2_CLIENT_DOMAINS to .env
Adding REACTION_AUTH to .env
Adding REACTION_EMAIL to .env
Adding REACTION_SECURE_DEFAULT_ADMIN to .env
Adding REACTION_USER_NAME to .env
Adding REACTION_USER to .env
Adding ROOT_URL to .env
mongo uses an image, skipping
Building reaction
Step 1/8 : FROM reactioncommerce/base:v1.8-meteor as meteor-dev
v1.8-meteor: Pulling from reactioncommerce/base
Digest: sha256:ad334cfe319fea43cd54947f241ec8118e74b5372a751ced4aeb6e3fdbd738eb
Status: Image is up to date for reactioncommerce/base:v1.8-meteor
# Executing 2 build triggers
 ---> Running in 4eeb9ff72502
Removing intermediate container 4eeb9ff72502
 ---> Running in 6d45b96ec2f0
Removing intermediate container 6d45b96ec2f0
 ---> 3909d5af4341
Step 2/8 : LABEL maintainer="Reaction Commerce <architecture@reactioncommerce.com>"
 ---> Running in b6dbce0e1364
Removing intermediate container b6dbce0e1364
 ---> 1ac613fdc6bc
Step 3/8 : ENV PATH $PATH:/home/node/.meteor:$APP_SOURCE_DIR/node_modules/.bin
 ---> Running in bd7ed801b52b
Removing intermediate container bd7ed801b52b
 ---> 16a6ae946d6c
Step 4/8 : COPY --chown=node package-lock.json $APP_SOURCE_DIR/
 ---> 337b8a22dfe3
Step 5/8 : COPY --chown=node package.json $APP_SOURCE_DIR/
 ---> 4c3d67eba611
Step 6/8 : RUN mkdir "$APP_SOURCE_DIR/node_modules" && chown node "$APP_SOURCE_DIR/node_modules"
 ---> Running in 267c2e13caf8
Removing intermediate container 267c2e13caf8
 ---> 298facb70329
Step 7/8 : RUN meteor npm install
 ---> Running in 75ed2136a7e4

> dtrace-provider@0.8.7 install /opt/reaction/src/node_modules/dtrace-provider
> node-gyp rebuild || node suppress-error.js

make: Entering directory '/opt/reaction/src/node_modules/dtrace-provider/build'
  TOUCH Release/obj.target/DTraceProviderStub.stamp
make: Leaving directory '/opt/reaction/src/node_modules/dtrace-provider/build'

> fibers@2.0.2 install /opt/reaction/src/node_modules/fibers
> node build.js || nodejs build.js

`linux-x64-57` exists; testing
Binary is fine; exiting

> sharp@0.20.5 install /opt/reaction/src/node_modules/sharp
> (node install/libvips && node install/dll-copy && prebuild-install) || (node-gyp rebuild && node install/dll-copy)

info sharp Downloading https://github.com/lovell/sharp-libvips/releases/download/v8.6.1/libvips-8.6.1-linux-x64.tar.gz                                                                                                    

> jss@9.8.7 postinstall /opt/reaction/src/node_modules/jss
> node -e "console.log('\u001b[35m\u001b[1mLove JSS? You can now support us on open collective:\u001b[22m\u001b[39m\n > \u001b[34mhttps://opencollective.com/jss/donate\u001b[0m')"

Love JSS? You can now support us on open collective:
 > https://opencollective.com/jss/donate

> mongodb-memory-server@2.7.3 postinstall /opt/reaction/src/node_modules/mongodb-memory-server
> node ./postinstall.js

mongodb-memory-server: checking MongoDB binaries cache...
mongodb-memory-server: binary path is /opt/reaction/src/node_modules/.cache/mongodb-memory-server/mongodb-binaries/latest/mongod

> nodemon@1.18.6 postinstall /opt/reaction/src/node_modules/nodemon
> node bin/postinstall || exit 0

Love nodemon? You can now support the project via the open collective:
 > https://opencollective.com/nodemon/donate

> styled-components@3.4.2 postinstall /opt/reaction/src/node_modules/styled-components
> node ./scripts/postinstall.js || exit 0

Use styled-components at work? Consider supporting our development efforts at opencollective.com/styled-components

> swiper@4.3.3 postinstall /opt/reaction/src/node_modules/swiper
> node -e "console.log('\u001b[35m\u001b[1mLove Swiper? Support Vladimir\'s work by donating or pledging on patreon:\u001b[22m\u001b[39m\n > \u001b[32mhttps://patreon.com/vladimirkharlampidi\u001b[0m\n')"

Love Swiper? Support Vladimir's work by donating or pledging on patreon:
 > https://patreon.com/vladimirkharlampidi

npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})                                                         

added 1876 packages from 1360 contributors and audited 29485 packages in 496.461s
found 0 vulnerabilities

Removing intermediate container 75ed2136a7e4
 ---> 272dc70991ae
Step 8/8 : COPY --chown=node . $APP_SOURCE_DIR
 ---> 2c3a72f8066f

Successfully built 2c3a72f8066f
Successfully tagged reaction_reaction:latest
Running post-build hook script for reaction.
reaction post-build script invoked.
Creating network "reaction_default" with the default driver
Creating volume "reaction_mongo-db" with default driver
Creating volume "reaction_reaction_node_modules" with default driver
Creating reaction_mongo_1 ... done
Creating reaction_reaction_1 ... done
Running post-project-start hook script for reaction.
reaction post-project-start script invoked.
if [ ! -d "reaction-next-starterkit" ] ; then git clone "git@github.com:/reactioncommerce/reaction-next-starterkit.git" "reaction-next-starterkit"; cd reaction-next-starterkit && git checkout "master"; fi
Cloning into 'reaction-next-starterkit'...
remote: Enumerating objects: 45, done.
remote: Counting objects: 100% (45/45), done.
remote: Compressing objects: 100% (32/32), done.
remote: Total 17021 (delta 20), reused 25 (delta 13), pack-reused 16976
Receiving objects: 100% (17021/17021), 4.46 MiB | 355.00 KiB/s, done.
Resolving deltas: 100% (11960/11960), done.
Checking connectivity... done.
Branch master set up to track remote branch master from origin.
Switched to a new branch 'master'
Running pre-build hook script for reaction-next-starterkit.
reaction-next-starterkit post-project-start script invoked.
Adding NODE_ENV to .env
Adding INTERNAL_GRAPHQL_URL to .env
Adding EXTERNAL_GRAPHQL_URL to .env
Adding FAVICON_URL to .env
Adding PLACEHOLDER_IMAGE_URL_GALLERY to .env
Adding PLACEHOLDER_IMAGE_URL_GRID to .env
Adding SEGMENT_ANALYTICS_SKIP_MINIMIZE to .env
Adding SEGMENT_ANALYTICS_WRITE_KEY to .env
Adding KEYCLOAK_REALM to .env
Adding KEYCLOAK_CLIENT_ID to .env
Adding KEYCLOAK_URL to .env
Adding KEYCLOAK_REDIRECT_URI to .env
Adding STRIPE_PUBLIC_API_KEY to .env
Adding OAUTH2_AUTH_URL to .env
Adding OAUTH2_TOKEN_URL to .env
Adding OAUTH2_CLIENT_ID to .env
Adding OAUTH2_CLIENT_SECRET to .env
Adding OAUTH2_REDIRECT_URL to .env
Adding PASSPORT_SESSION_SECRET to .env
Adding CANONICAL_URL to .env
Building web
Step 1/36 : FROM node:8-alpine
8-alpine: Pulling from library/node
Digest: sha256:f30a55706c7336a648493b926128f56176e4500cfdc968764bfdb711716e0109
Status: Image is up to date for node:8-alpine
 ---> 5c0c5c94503f
Step 2/36 : ARG NAME=reaction-next-starterkit
 ---> Running in 71aeeafb8ece
Removing intermediate container 71aeeafb8ece
 ---> 7290c5be681b
Step 3/36 : ARG DESCRIPTION=""
 ---> Running in 2a1f5dcb22a4
Removing intermediate container 2a1f5dcb22a4
 ---> d9fc31f7507b
Step 4/36 : ARG URL=https://github.com/reactioncommerce/reaction-next-starterkit
 ---> Running in 2bc7a5d2eddc
Removing intermediate container 2bc7a5d2eddc
 ---> 0b569ac00d39
Step 5/36 : ARG DOC_URL=https://github.com/reactioncommerce/reaction-next-starterkit
 ---> Running in 1c8651d0baa7
Removing intermediate container 1c8651d0baa7
 ---> 4204de229bc5
Step 6/36 : ARG VCS_URL=https://github.com/reactioncommerce/reaction-next-starterkit
 ---> Running in 7bbf3e0b37b2
Removing intermediate container 7bbf3e0b37b2
 ---> 958feddc8ea2
Step 7/36 : ARG VCS_REF
 ---> Running in 752dcc5b36d3
Removing intermediate container 752dcc5b36d3
 ---> 207944a30261
Step 8/36 : ARG VENDOR
 ---> Running in 77f1b36c818d
Removing intermediate container 77f1b36c818d
 ---> 7ff54f6ecf25
Step 9/36 : ARG BUILD_DATE
 ---> Running in 52fc05d7f268
Removing intermediate container 52fc05d7f268
 ---> c9c3182a7320
Step 10/36 : ARG BUILD_COMPARE_URL
 ---> Running in dc9f6efd75f3
Removing intermediate container dc9f6efd75f3
 ---> 08ef4b1b3288
Step 11/36 : ARG BUILD_ENV=test
 ---> Running in bb8569263fc9
Removing intermediate container bb8569263fc9
 ---> 3a69d8646fd2
Step 12/36 : ARG BUILD_NUMBER
 ---> Running in ab8eda1fe0ec
Removing intermediate container ab8eda1fe0ec
 ---> 3825b271b312
Step 13/36 : ARG BUILD_PLATFORM
 ---> Running in 692067a11630
Removing intermediate container 692067a11630
 ---> cf69d61db837
Step 14/36 : ARG BUILD_PLATFORM_PROJECT_USERNAME
 ---> Running in a91dd76cc9b3
Removing intermediate container a91dd76cc9b3
 ---> a56f2867dd66
Step 15/36 : ARG BUILD_PLATFORM_PROJECT_REPONAME
 ---> Running in 00fa234a679e
Removing intermediate container 00fa234a679e
 ---> a6c8ef04b9d5
Step 16/36 : ARG BUILD_PULL_REQUESTS
 ---> Running in 9fb112f3cc0a
Removing intermediate container 9fb112f3cc0a
 ---> f24b84243c68
Step 17/36 : ARG BUILD_TRIGGERED_BY_TAG
 ---> Running in ffe86ae2b429
Removing intermediate container ffe86ae2b429
 ---> e3d5ac68109c
Step 18/36 : ARG BUILD_URL
 ---> Running in 7f8af405f7cf
Removing intermediate container 7f8af405f7cf
 ---> 069bbc898ec8
Step 19/36 : ARG CIRCLE_WORKSPACE_ID
 ---> Running in bfe213d0079d
Removing intermediate container bfe213d0079d
 ---> e65522ea6f8c
Step 20/36 : ARG CIRCLE_WORKFLOW_ID
 ---> Running in b32a562848ad
Removing intermediate container b32a562848ad
 ---> 96595aa62a8f
Step 21/36 : ARG CIRCLE_WORKFLOW_JOB_ID
 ---> Running in 237fd1dde6ba
Removing intermediate container 237fd1dde6ba
 ---> 8eae957687b6
Step 22/36 : ARG CIRCLE_WORKFLOW_UPSTREAM_JOB_IDS
 ---> Running in a436221fb02f
Removing intermediate container a436221fb02f
 ---> 797eed8afaa1
Step 23/36 : ARG CIRCLE_WORKSPACE_ID
 ---> Running in e241741ce9c2
Removing intermediate container e241741ce9c2
 ---> 1a14b75ecec9
Step 24/36 : ARG GIT_REPOSITORY_URL
 ---> Running in 8d40a43a6e6f
Removing intermediate container 8d40a43a6e6f
 ---> fe7360dd3105
Step 25/36 : ARG GIT_SHA1
 ---> Running in 5dfae3a35385
Removing intermediate container 5dfae3a35385
 ---> ce13bc546d94
Step 26/36 : ARG LICENSE
 ---> Running in bb281c5377ba
Removing intermediate container bb281c5377ba
 ---> 9e7fc2ecfbec
Step 27/36 : ENV APP_SOURCE_DIR=/usr/local/src/reaction-app     PATH=$PATH:/usr/local/src/node_modules/.bin
 ---> Running in 7add049f3528
Removing intermediate container 7add049f3528
 ---> bcf0a3426d6f
Step 28/36 : LABEL maintainer="Reaction Commerce <engineering@reactioncommerce.com>"       com.reactioncommerce.build-date=$BUILD_DATE       com.reactioncommerce.name=$NAME       com.reactioncommerce.description=$DESCRIPTION       com.reactioncommerce.url=$URL       com.reactioncommerce.vcs-url=$VCS_URL       com.reactioncommerce.vcs-ref=$VCS_REF       com.reactioncommerce.vendor=$VENDOR       com.reactioncommerce.docker.build.compare-url=$BUILD_COMPARE_URL       com.reactioncommerce.docker.build.number=$BUILD_NUMBER       com.reactioncommerce.docker.build.platform=$BUILD_PLATFORM       com.reactioncommerce.docker.build.platform.project.username=$BUILD_PLATFORM_PROJECT_USERNAME       com.reactioncommerce.docker.build.platform.project.reponame=$BUILD_PLATFORM_PROJECT_REPONAME       com.reactioncommerce.docker.build.pull-requests=$BUILD_PULL_REQUESTS       com.reactioncommerce.docker.build.triggered-by-tag=$BUILD_TRIGGERED_BY_TAG       com.reactioncommerce.docker.build.url=$BUILD_URL       com.reactioncommerce.docker.build.circle.workflow.id=$CIRCLE_WORKFLOW_ID       com.reactioncommerce.docker.build.circle.workflow.job.id=$CIRCLE_WORKFLOW_JOB_ID       com.reactioncommerce.docker.build.circle.workflow.upstream.job.ids=$CIRCLE_WORKFLOW_UPSTREAM_JOB_IDS       com.reactioncommerce.docker.build.circle.workflow.url=https://circleci.com/workflow-run/$CIRCLE_WORKFLOW_ID       com.reactioncommerce.docker.build.circle.workspace.id=$CIRCLE_WORKSPACE_ID       com.reactioncommerce.docker.git.repository.url=$GIT_REPOSITORY_URL       com.reactioncommerce.docker.git.sha1=$GIT_SHA1       com.reactioncommerce.docker.license=$LICENSE
 ---> Running in 439a1f3ebcfb
Removing intermediate container 439a1f3ebcfb
 ---> bb333a14b344
Step 29/36 : RUN apk add --no-cache rsync
 ---> Running in 670e7d513499
fetch http://dl-cdn.alpinelinux.org/alpine/v3.8/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.8/community/x86_64/APKINDEX.tar.gz
(1/4) Installing libattr (2.4.47-r7)
(2/4) Installing libacl (2.2.52-r5)
(3/4) Installing popt (1.16-r7)
(4/4) Installing rsync (3.1.3-r1)
Executing busybox-1.28.4-r2.trigger
OK: 6 MiB in 19 packages
Removing intermediate container 670e7d513499
 ---> 110d3322bc6c
Step 30/36 : WORKDIR $APP_SOURCE_DIR/..
 ---> Running in 51ec2040107a
Removing intermediate container 51ec2040107a
 ---> 0a2797275737
Step 31/36 : COPY package.json yarn.lock $APP_SOURCE_DIR/../
 ---> 46cdb86609c5
Step 32/36 : RUN set -ex;   if [ "$BUILD_ENV" = "production" ]; then     yarn install       --frozen-lockfile       --ignore-scripts       --no-cache;   elif [ "$BUILD_ENV" = "test" ]; then     yarn install       --frozen-lockfile       --ignore-scripts       --no-cache;   elif [ "$BUILD_ENV" = "development" ]; then     yarn install       --cache-folder /home/node/.cache/yarn       --ignore-scripts;   fi;   rm package.json yarn.lock
 ---> Running in 709dcef25f59
+ '[' development '=' production ]
+ '[' development '=' test ]                                                                                 
+ '[' development '=' development ]                                                                          
+ yarn install --cache-folder /home/node/.cache/yarn --ignore-scripts                                        
yarn install v1.12.3
[1/4] Resolving packages...
[2/4] Fetching packages...
info fsevents@1.2.4: The platform "linux" is incompatible with this module.
info "fsevents@1.2.4" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > react-tracking@5.2.1" has unmet peer dependency "babel-runtime@^6.20.0".
warning " > react-tracking@5.2.1" has incorrect peer dependency "react@^15.0.0".                             
[4/4] Building fresh packages...
warning Ignored scripts due to flag.
Done in 105.18s.
+ rm package.json yarn.lock
Removing intermediate container 709dcef25f59
 ---> cd7087c80dee
Step 33/36 : WORKDIR $APP_SOURCE_DIR
 ---> Running in cda99f86b919
Removing intermediate container cda99f86b919
 ---> 75ad567a5103
Step 34/36 : COPY . $APP_SOURCE_DIR
 ---> 6d9c4294034e
Step 35/36 : RUN set -ex;   if [ "$BUILD_ENV" = "production" ]; then     yarn build;   fi;
 ---> Running in c0bb89602bd4
+ '[' development '=' production ]
Removing intermediate container c0bb89602bd4
 ---> 096e40696717
Step 36/36 : CMD ["yarn", "start"]
 ---> Running in bc22d8e4d566
Removing intermediate container bc22d8e4d566
 ---> 12acc7ebc166

Successfully built 12acc7ebc166
Successfully tagged reaction-next-starterkit_web:latest
Running post-build hook script for reaction-next-starterkit.
reaction-next-starterkit post-build script invoked.
Creating volume "reaction-next-starterkit_web-yarn" with default driver
Creating volume "reaction-next-starterkit_empty_node_modules" with default driver
Creating volume "reaction-next-starterkit_node_modules" with default driver
Creating reaction-next-starterkit_web_1 ... done
Running post-project-start hook script for reaction-next-starterkit.
reaction-next-starterkit post-project-start script invoked.
Running post-system-start hook script for reaction-hydra.
reaction-hydra post-system-start script invoked.

Running post-system-start hook script for reaction.
reaction post-system-start script invoked.

Running post-system-start hook script for reaction-next-starterkit.
reaction-next-starterkit post-system-start script invoked.

I have also noticed some errors in hydra postgreql logs:

hydra_1          | time="2019-01-24T18:26:06Z" level=info msg="Connected to SQL!"
hydra_1          | time="2019-01-24T18:26:06Z" level=fatal msg="Could not fetch private signing key for OpenID Connect - did you forget to run \"hydra migrate sql\" or forget to set the SYSTEM_SECRET?" error="pq: relation \"hydra_jwk\" does not exist"

Solution from above don't work: (sudo chown -R 1000 ~/.cache/yarn-offline-mirror and again cleaning volumes and make command). Please give me some advice.

spencern commented 5 years ago

@aktywnitu I'm not certain what's going on there as based on the logs it seems that things started okay. We've released another version shortly after you experienced this issue. It may be worth trying that new version. If you're still seeing this issue, please create a new issue.

aktywnitu commented 5 years ago

OK. I will try today test version v2.0.0-rc.9.

Jorgelg13 commented 4 years ago

Hi, I have the same problem, someone can help me, I am trying to get the most up-to-date version. the browser returns this to me when trying to create a new account.

NickPyae commented 4 years ago

@Jorgelg13 I had the same issue. But I could manage to fix it. What I did was I added this ENTRYPOINT ["tini", "--", "./bin/start"] to at the end of Dockerfile and also updated docker-compose.yml file build context with this web: build: context: . Then we run docker-compose up --build from your terminal. It should fix your issue.