Support AWS Lightsail Generation 3 bundle IDs
- Dominant language
- TypeScript
- Stars
- 2.2k
- Forks
- 91
- PR merge metrics
- No merged PRs in 30d
Description
## Problem
The Lightsail driver has a hardcoded allowlist of bundle IDs in [`packages/driver-lightsail/src/driver/bundle-id.ts`](https://github.com/livecycle/preevy/blob/main/packages/driver-lightsail/src/driver/bundle-id.ts) that only includes **Generation 2** bundles:
```ts
export const BUNDLE_IDS = [
'nano_2_0',
'micro_2_0',
'small_2_0',
'medium_2_0',
'large_2_0',
'xlarge_2_0',
'2xlarge_2_0',
] as const
```
AWS has been rolling out **Generation 3** Lightsail instance plans across all regions. In some regions (e.g. `ap-south-1` Mumbai), Gen 2 bundles are **no longer available at all** — only Gen 3 bundles exist:
```
nano_3_0, micro_3_0, small_3_0, medium_3_0, large_3_0, xlarge_3_0, 2xlarge_3_0 (us-east-1, etc.)
nano_3_1, micro_3_1, small_3_1, medium_3_1, large_3_1, xlarge_3_1, 2xlarge_3_1 (ap-south-1, etc.)
```
This means:
- **Cannot create new profiles** in regions that only have Gen 3 bundles (like `ap-south-1`)
- **Cannot upgrade** existing profiles to Gen 3 for better performance (improved burst capabilities on modern Intel processors, at no additional cost)
- Existing profiles using Gen 2 still work for now, but AWS is deprecating Gen 2 and recommending upgrades
## Expected Behavior
Preevy should accept Gen 3 bundle IDs (e.g. `large_3_0`, `large_3_1`) in addition to Gen 2 ones when creating profiles or running `preevy up`.
## Suggested Fix
Update the `BUNDLE_IDS` array in `bundle-id.ts` to include Gen 3 bundle IDs. Ideally, instead of hardcoding, the CLI could query `aws lightsail get-bundles` to dynamically discover available bundles for the selected region.
## Environment
- Preevy version: `0.0.67`
- Driver: `lightsail`
- Affected regions: All regions with Gen 3 bundles; critical for regions where Gen 2 is no longer available (e.g. `ap-south-1`)
Contributor guide
Research direction
Start with packages/driver-lightsail/src/driver/bundle-id.ts and compare the existing Gen 2 allowlist with the Gen 3 bundle IDs listed in the issue. Verify that profile creation and `preevy up` accept Gen 3 IDs in regions such as ap-south-1; dynamic discovery via `aws lightsail get-bundles` is an optional broader direction mentioned by the issue.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, typescript
- Domain
- cli, cloud, devops
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 78/100