Skip to content

Commit

Permalink
add comments linking boto3 docs for kms_key_arns function
Browse files Browse the repository at this point in the history
  • Loading branch information
joneszc committed Oct 24, 2024
1 parent 36518be commit 567a05d
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/_nebari/provider/cloud/amazon_web_services.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,16 +126,13 @@ def kms_key_arns(region: str) -> Dict[str, dict]:
"""Return dict of available/enabled KMS key IDs and associated KeyMetadata for the AWS region."""
session = aws_session(region=region)
client = session.client("kms")
# https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/kms/client/list_keys.html
paginator = client.get_paginator("list_keys")
fields = [
"Arn",
"KeyUsage",
"KeySpec",
# "KeyState",
# "Origin",
# "KeyManager",
# "EncryptionAlgorithms",
# "MultiRegion",
# https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/kms/client/describe_key.html#:~:text=Response%20Structure
]
kms_keys = [
client.describe_key(KeyId=j["KeyId"]).get("KeyMetadata")
Expand Down

0 comments on commit 567a05d

Please sign in to comment.