Skip to content

Commit

Permalink
update callout location
Browse files Browse the repository at this point in the history
  • Loading branch information
ykethan committed Dec 24, 2024
1 parent 12a94f8 commit bdaf55f
Showing 1 changed file with 6 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,12 @@ npx ampx sandbox secret remove foo

## Set environment variables

<Callout warning>

Note: do not store secret values in environment variables. Environment variables values are rendered in plaintext to the build artifacts and can be accessed by anyone with access to the build artifacts or [get-app](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/amplify/get-app.html) command.

</Callout>

Environment variables work like key-value pairs to help manage configurable settings across different deployment environments, including development, staging, and production. Unlike secrets, which store sensitive data, environment variables are typically nonconfidential and are used for controlling application behavior in different environments. Another key difference is that environment variables are stored and managed by the Amplify managed service. You can set environment variables in the Amplify console (view the [AWS Amplify Hosting User Guide](https://docs.aws.amazon.com/amplify/latest/userguide/environment-variables.html#setting-env-vars) for detailed instructions).

<Video src="/images/gen2/secrets-and-vars/env-vars.mp4" description="Video - Secrets" />
Expand All @@ -136,13 +142,6 @@ build:
- npm run build
```
<Callout warning>
Note: do not store secret values in environment variables. Environment variables values are rendered in plaintext to the build artifacts and can be accessed by anyone with access to the build artifacts or [get-app](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/amplify/get-app.html) command.
</Callout>
<Callout info>
With the implementation above, the environment variable is written in a `.env` file. However, you can write it to any file depending on your platform.

Expand Down

0 comments on commit bdaf55f

Please sign in to comment.