Skip to content

Commit

Permalink
Add a requirements.txt file for the deployment script
Browse files Browse the repository at this point in the history
  • Loading branch information
iuriaranda committed Jun 21, 2017
1 parent 11da71f commit 7ab1d24
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
18 changes: 17 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,10 @@ module "cpu-scaling" {
```

## Blue-green deployments

The `bluegreen.py` script performs a bluegreen deployment of the selected terraform stack. It only works with Python 2.7.
The blue-green deployment script expects certain inputs and outputs in the Terraform project you want to deploy in a blue-green fashion.

### Required outputs:
```
output "blue_asg_id" {
Expand Down Expand Up @@ -103,7 +106,20 @@ variable "green_ami" {
}
```

These input variables need to be assigned to your module. Make sure you do a terraform refresh to be sure that the terraform outputs are saved in the Terraform state file. After that you can execute the blue-green script.
These input variables need to be assigned to your module. Make sure you do a terraform refresh to be sure that the terraform outputs are saved in the Terraform state file.

### Usage

First you need to install the requirements:

```sh
pip install -r requirements.txt
```

Run `./bluegreen.py --help` to see the available options.

Example:

```sh
./bluegreen.py -f stacks/test/application -a ami-xxxx -c apply -t 500
```
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
boto3

0 comments on commit 7ab1d24

Please sign in to comment.