CloudFront Invalidation
Type: DEVRAMPS:CLOUDFRONT:INVALIDATE
Category: deploy
Version: 1.0.0
Description
Invalidate paths on a CloudFront distribution and wait for completion.
Creates a CloudFront invalidation for the specified paths and polls until the invalidation completes. This ensures that edge caches are cleared before the pipeline proceeds. Commonly used after deploying static assets to S3 to ensure users receive the latest content.
Parameters
Required Parameters
| Parameter | Type | Description |
|---|---|---|
distribution_id | string | CloudFront distribution ID. |
paths | array<string> | Paths to invalidate (e.g., ["/*"] for all paths). |
Optional Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
account_id | string | - | AWS account ID. Defaults to stage account. |
region | string | - | AWS region. Defaults to stage region. |
timeout | integer | 15 | Maximum time to wait for invalidation completion in minutes. |
Example Usage
- type: DEVRAMPS:CLOUDFRONT:INVALIDATE
name: Invalidate CDN Cache
params:
distribution_id: E1234567890ABC
paths:
- "/*"
timeout: 15