Skip to content

Comments

Add support for opt-in regions#116

Open
FiendishDrWu wants to merge 2 commits intoc6fc:devfrom
FiendishDrWu:region_ami_owner_override
Open

Add support for opt-in regions#116
FiendishDrWu wants to merge 2 commits intoc6fc:devfrom
FiendishDrWu:region_ami_owner_override

Conversation

@FiendishDrWu
Copy link

Add regional AMI owner override to lambda_functions/execute_campaign/main.js

Add regional AMI owner override to lambda_functions/execute_campaign/main.js
@FiendishDrWu
Copy link
Author

FiendishDrWu commented Dec 6, 2025

AMI Owner ID Regional Override Update

Adds support for specifying region-specific default AMI owner IDs for AWS regions whose Deep Learning AMIs do not use the standard owner ID (898082745236).

The build_owner_map.sh script (see build_owner_map.sh) scans all enabled commercial regions and records the owner ID of the latest AMI for each of the following AMI families:

  • "Deep Learning Base OSS Nvidia Driver GPU AMI (Amazon Linux 2023) *"
  • "Deep Learning ARM64 Base OSS Nvidia Driver GPU AMI (Amazon Linux 2023) *"
  • "amzn2-ami-amd-hvm--x86_64-"

The complete output is included here:

The same list filtered for regions whose owner ID differs from the global AWS default:

These overrides are added:

```json
"ap-south-2": "442309848619",
"eu-south-1": "771282176748",
"eu-south-2": "565266784259",
"me-central-1": "077386991849",
"eu-central-2": "350317392379",
"af-south-1": "380973545650",
"me-south-1": "130039589902",
"ap-east-1": "452469860969",
"ap-southeast-3": "534350146288",
"ap-southeast-4": "064406389444",
"ap-southeast-5": "803833843295",
```

Unsupported Regions

The following regions should be considered unsupported by NPK

Regions with no AMIs

These regions produced zero matches for all three AMI families:

  • ap-southeast-6 (Asia Pacific – New Zealand)
  • ca-west-1 (Canada West – Calgary)
  • il-central-1 (Israel – Tel Aviv)

Regions missing a valid AMI

These regions contain only the AMD AMI, but not the custom one with owner 679593333241 specified in gpu_instance_families.json. This was verified separately, the build_owner_map.sh script just checked for the AMI's by name.

  • ap-east-2
  • mx-central-1
  • ap-southeast-7

Because these regions do not have the correct custom image, these regions should also be treated as unsupported.


Summary

  • Adds region-specific AMI owner ID overrides wherever AWS uses a non-default owner.
  • Leaves all default-owner regions unchanged.
  • Ensures that AMI selection behaves reliably across all supported AWS commercial regions.

edit - formatting

@FiendishDrWu FiendishDrWu changed the title Refactor default image owner handling by region Add support for opt-in regions Dec 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant