- Newest
- Most votes
- Most comments
The behavior you're describing is not the default or expected behavior for AWS Amplify. Typically, when you connect a new frontend branch to an existing backend environment (like staging), Amplify should use that existing backend environment rather than creating a new one for each CI/CD run.
The fact that this started happening recently suggests there might have been a change in your Amplify configuration or a potential issue with how the backend environment is being referenced.
A few things to consider:
-
Check your Amplify app settings in the AWS Console to ensure that the backend environments are correctly linked to your frontend branches.
-
Review any recent changes to your project configuration, especially anything related to Amplify settings or environment variables.
-
The amplifyPush command in your amplify.yml file should be using the existing backend environment. You might want to try explicitly specifying the environment name:
amplifyPush --simple --envName staging
-
Since you mention that you don't have an amplify folder in your repo and get aws-exports.json during build, make sure that the process generating this file is correctly referencing your existing backend environment.
-
Check if there have been any recent updates to the Amplify CLI or your project dependencies that might have changed this behavior.
If the issue persists, you may want to reach out to AWS support for further assistance, as this behavior is not typical and could indicate a configuration problem or a potential bug in recent Amplify updates.
Sources
AWS Amplify FAQs | Front-End Web & Mobile | Amazon Web Services
AWS Amplify - Code First Development
Relevant content
- AWS OFFICIALUpdated 3 years ago