For more information on how this repository was set up, check out this Confluence page on how to bootstrap AWS accounts.
-
Create an isolated Python virtual environment using
pipenv
after cd'ing into the repository's directory.pipenv install --dev
-
Install the pre-commit hooks into Git to lint files before commiting changes.
pipenv run pre-commit install
-
Create an IAM user with programmatic access using the AWS Management Console accessible via JumpCloud.
-
Configure a profile with the AWS CLI.
aws configure --profile <aws_profile>
You can test the deployment of a stack group and then delete the resulting resources using the following commands:
# Activate the pipenv virtual environment to use sceptre
pipenv shell
# Test the deployment of the 'prod' stack group
sceptre --var "profile=<aws_profile>" launch --yes prod
# Delete the test deployment of the 'prod' stack group
sceptre --var "profile=<aws_profile>" delete --yes prod
N.B. If your text editor (e.g. Visual Studio Code) or shell (e.g. using direnv
) can automatically activate the pipenv
virtual environment, you can omit the pipenv shell
command.
If you need to add a Python dependency or bump a package version, you need to manually edit the Pipfile accordingly and run the following command to update the associated Pipfile.lock
with the corresponding versions and hashes.
pipenv update