Despite the way AWS Amplify currently works, some tools (e.g. EAS) require aws-exports.js
to be included in a project's repo. However in order to safely do this, aws-exports.js
needs to be edited locally so that sensitive information there is replaced with environment variables.
My question is, what happens if I do that? If I edit aws-exports.js
and replace values there with environment variables
push
or pull
or add
or update
)?aws-exports.js
is simply representation of your backend (so that the frontend can access to the backend).
If you edit it, it won't affect any of the backend configuration, and will be re-generated on backend changes.
It's true that Amplify CLI still lacks some features. For example: setting API GateWay authorization type to API KEY
. To do that, you need to use amplify override api
and it will generate file next to your API in /amplify/backend/api/...
directory where you can override default configs.