okta / samples-nodejs-express-4

Express 4 samples. Will publish an artifact that can be consumed by end-to-end sample repos
Other
119 stars 119 forks source link

OIDC Middleware library integrated into express sample app #26

Closed vijetmahabaleshwar-okta closed 6 years ago

vijetmahabaleshwar-okta commented 6 years ago

To test the integration, you will need the following -

  1. Updated angular js front end (https://github.com/okta/samples-js-angular-1/pull/24)
  2. .samples.config.json should point to a real okta server / start mock-server to playback tapes
  3. client id/secret in .samples.config.json should refer to "Web App" in your okta org / left unchanged if using mock-server

Currently the tests won't work as the behavior of the express backend has changed after the integration. Test changes would be added in a separate PR The sample app now works with mock server as well. New tapes are recorded, which is added to this PR.

jmelberg-okta commented 6 years ago

@vijetmahabaleshwar-okta Have we tested that installing a different frontend, say @okta/samples-js-react will still work?

vijetmahabaleshwar-okta commented 6 years ago

@jmelberg-okta - No. I haven't tested it with any other front-end samples. React and Elm front-end samples need to be updated to work with this sample.

robertjd commented 6 years ago

It looks like we still have some work to do here:

vijetmahabaleshwar-okta commented 6 years ago

@robertjd

viniciusgama commented 6 years ago

Hey, thanks for the PR, it solves a problem I was having with with the okta mock while using the OIDC Middleware. I even tried to record the HTTP interactions all over again but got stuck in in the auth part. Can someone share how do you do the recording so I can do the same in my own project?

vijetmahabaleshwar-okta commented 6 years ago

@viniciusgama - You're welcome! I can share the details on using our mock-server to record your own tapes. But if you ask me, you should be using a real okta org for your needs. Going ahead, we will use the tapes only for our e2e testing. Is there any reason you don't want to use a real okta org?

viniciusgama commented 6 years ago

hey @vijetmahabaleshwar-okta, the mock server is going to be used only for local development. And also to make sure that the integration between okta and the middleware are working fine. In our deployed environments we are going to use a real okta instance. You still recommend not having okta for local development?