Skip to content

Commit 41c29d7

Browse files
adds custom deployment config support.
- new customType property to indicate that should not use the prefix for default CodeDeploy config - adds unit test for the case where customType is true - adds test case where customType is true - adds readme descriptions of the new feature
1 parent 95c591f commit 41c29d7

File tree

6 files changed

+1287
-2
lines changed

6 files changed

+1287
-2
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ functions:
4343
- http: GET hello
4444
deploymentSettings:
4545
type: Linear10PercentEvery1Minute
46+
customType: false
4647
alias: Live
4748
preTrafficHook: preHook
4849
postTrafficHook: postHook
@@ -60,7 +61,7 @@ You can see a working example in the [example folder](./example/).
6061
6162
## <a name="configuration"></a>Configuration
6263
63-
* `type`: (required) defines how the traffic will be shifted between Lambda function versions. It must be one of the following:
64+
* `type`: (required) defines how the traffic will be shifted between Lambda function versions. It must be one of the following if customType is not true:
6465
- `Canary10Percent5Minutes`: shifts 10 percent of traffic in the first increment. The remaining 90 percent is deployed five minutes later.
6566
- `Canary10Percent10Minutes`: shifts 10 percent of traffic in the first increment. The remaining 90 percent is deployed 10 minutes later.
6667
- `Canary10Percent15Minutes`: shifts 10 percent of traffic in the first increment. The remaining 90 percent is deployed 15 minutes later.
@@ -70,6 +71,7 @@ You can see a working example in the [example folder](./example/).
7071
- `Linear10PercentEvery3Minutes`: shifts 10 percent of traffic every three minutes until all traffic is shifted.
7172
- `Linear10PercentEvery10Minutes`: shifts 10 percent of traffic every 10 minutes until all traffic is shifted.
7273
- `AllAtOnce`: shifts all the traffic to the new version, useful when you only need to execute the validation hooks.
74+
* `customType`: (optional) When set to true you can use your custom CodeDeploy Deployment Configurations. (more info [here](https://docs.aws.amazon.com/codedeploy/latest/userguide/deployment-configurations.html)).
7375
* `alias`: (required) name that will be used to create the Lambda function alias.
7476
* `preTrafficHook`: (optional) validation Lambda function that runs before traffic shifting. It must use the CodeDeploy SDK to notify about this step's success or failure (more info [here](https://docs.aws.amazon.com/codedeploy/latest/userguide/reference-appspec-file-structure-hooks.html)).
7577
* `postTrafficHook`: (optional) validation Lambda function that runs after traffic shifting. It must use the CodeDeploy SDK to notify about this step's success or failure (more info [here](https://docs.aws.amazon.com/codedeploy/latest/userguide/reference-appspec-file-structure-hooks.html))

0 commit comments

Comments
 (0)