Skip to content

Commit

Permalink
Merge pull request #62 from ServerlessLife/fix-cr-random-update-cause…
Browse files Browse the repository at this point in the history
…s-deploy-failure

fix: The IoT custom resource should return the endpoint even on updates
  • Loading branch information
Lewenhaupt authored Jan 15, 2025
2 parents 9e112eb + a1b1a6d commit 3eb723e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/ServerlessSpy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,15 @@ export class ServerlessSpy extends Construct {
endpointType: 'iot:Data-ATS',
},
},
onUpdate: {
service: 'Iot',
action: 'describeEndpoint',
physicalResourceId:
custom_resources.PhysicalResourceId.fromResponse('endpointAddress'),
parameters: {
endpointType: 'iot:Data-ATS',
},
},
installLatestAwsSdk: false,
policy: custom_resources.AwsCustomResourcePolicy.fromSdkCalls({
resources: custom_resources.AwsCustomResourcePolicy.ANY_RESOURCE,
Expand Down

0 comments on commit 3eb723e

Please sign in to comment.