Skip to content

Commit

Permalink
Fix typos in "Load Secrets from .env" (sst#422)
Browse files Browse the repository at this point in the history
"gets loading" to "gets loaded"
"environment variables called" to "environment variable called"
  • Loading branch information
adam-hawkins authored and jayair committed Dec 16, 2019
1 parent 2e25b6c commit 311455e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions _chapters/load-secrets-from-env.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ Your `environment:` block should look like this:

A quick explanation on the above:

- The `STRIPE_SECRET_KEY` from the `.env` file above gets loading as an environment variable when we test our code locally.
- The `STRIPE_SECRET_KEY` from the `.env` file above gets loaded as an environment variable when we test our code locally.

- This allows us to add a Lambda environment variables called `stripeSecretKey`. We do this using the `stripeSecretKey: ${env:STRIPE_SECRET_KEY}` line. And just like our `tableName` environment variable, we can reference it in our Lambda function using `process.env.stripeSecretKey`.
- This allows us to add a Lambda environment variable called `stripeSecretKey`. We do this using the `stripeSecretKey: ${env:STRIPE_SECRET_KEY}` line. And just like our `tableName` environment variable, we can reference it in our Lambda function using `process.env.stripeSecretKey`.

Now we need to ensure that we don't commit our `.env` file to git. The starter project that we are using has the following in the `.gitignore`.

Expand Down

0 comments on commit 311455e

Please sign in to comment.