samples-js-react icon indicating copy to clipboard operation
samples-js-react copied to clipboard

default file for dotenv config

Open haishengwu-okta opened this issue 4 years ago • 3 comments

These values must exist as environment variables. They can be exported in the shell, or saved in a file named testenv, at the root of this repository.

but I need to name it .env in root of okta-hosted-login root.

➜  okta-hosted-login git:(master) ✗ node --version
v12.13.0
➜  okta-hosted-login git:(master) ✗ npm --version
6.12.0

haishengwu-okta avatar Aug 18 '20 05:08 haishengwu-okta

I think the change may need to be made in the okta-oidc-tck library: https://oktainc.atlassian.net/browse/OKTA-247107

aarongranick-okta avatar Aug 18 '20 15:08 aarongranick-okta

is oidc-tck just an testing tool? is the sample code actually looking for testenv file or default .env?

haishengwu-okta avatar Aug 18 '20 15:08 haishengwu-okta

Also just had this issue. The problem is that okta-env.js is inside the env folder, so using

path.join(__dirname, '..', 'testenv'))

is actually looking in the okta-hosted-login folder, not the root folder of the project. Moving the testenv file inside the okta-hosted-login folder fixes the issue.

nabeards avatar Nov 01 '21 23:11 nabeards