forked from awslabs/aws-deployment-framework
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Install: Add version checks and pre-deploy warnings
**Why?** When you clone the ADF Github repository, it will not fetch the git tags. The installation docs describe that you should run `git fetch --tags` to retrieve those. However, if someone forgets to run that command, you run into a weird error that does not describe what is going wrong in a resolvable manner: > Error: Failed to create changeset for the stack: aws-deployment-framework, > Parameter validation failed: > Invalid length for parameter Tags[0].Value, value: 0, valid min length: 1 **What?** Added check to verify that the version number can be determined correctly. * If it did not return the version number, but an empty string instead: * it will test whether there is a .git folder. * If not, the user should clone a repository instead. * If the .git directory exists, it will instruct the user to fetch the git tags. * If a version number is returned, it will check whether the version number matches with the tag. * If it does, this means that it is building a released version of ADF. * If it does not, the user might not have switched to the right version tag yet. Hence, we warn the user to proceed with caution. Additionally, this change will add a warning when ADF gets deployed that the specific version and changes should be reviewed and tested in a non-production environment.
- Loading branch information
Showing
2 changed files
with
84 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters