From 1e15b74de63771f28f242050963124fbf01218d5 Mon Sep 17 00:00:00 2001 From: Tim Saunders Date: Wed, 23 Feb 2022 22:57:14 +0000 Subject: [PATCH 1/2] Clarify the location of the local.env.sh files --- auth/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/auth/README.md b/auth/README.md index 94b5a93..5ea423c 100644 --- a/auth/README.md +++ b/auth/README.md @@ -57,7 +57,7 @@ hash_config { #### Set your Hash Parameters Now that you have your 4 hash parameters, you can set them up in your environment(s): ##### For a local development server (or hosting your own `NodeJS` server): -* copy the file `local.env.sh.sample` to `local.env.sh` +* copy the file `local.env.sh.sample` to `local.env.sh` (in the middleware/verify-firebase-pw folder) * edit the `MEMCOST`, `ROUNDS`, `SALTSEPARATOR`, and `SIGNERKEY` environment variables you obtained in the previous step Sample `local.env.sh` file: From b8f5b7293aa26a7967e0a20ce4c9101bae60451e Mon Sep 17 00:00:00 2001 From: Tim Saunders Date: Wed, 23 Feb 2022 23:12:21 +0000 Subject: [PATCH 2/2] Improve hosting middleware instructions --- auth/README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/auth/README.md b/auth/README.md index 5ea423c..db91826 100644 --- a/auth/README.md +++ b/auth/README.md @@ -98,7 +98,8 @@ Sample `[env]` section for the `fly.toml` file: #### Hosting the Middleware ##### Local hosting for testing (or for running your own server using `NodeJS`): * make sure you've set up `local.env.sh` as described above -* run `node local.sh` +* run `npm i` in `auth/middleware/verify-firebase-pw/` to install dependencies +* run `./local.sh` The `local.sh` file does two things: ```sh source ./local.env.sh # sets environment variables stored in ./local.env.sh