forked from phoenix/litellm-mirror
fix(utils.py): make sure redis caching works with aws kms encryption
This commit is contained in:
parent
e4dbb9b2db
commit
8f140cb5ee
2 changed files with 4 additions and 1 deletions
|
@ -56,10 +56,11 @@ router_settings:
|
|||
|
||||
litellm_settings:
|
||||
success_callback: ["langfuse"]
|
||||
cache: True
|
||||
|
||||
general_settings:
|
||||
alerting: ["email"]
|
||||
key_management_system: "aws_kms"
|
||||
key_management_settings:
|
||||
hosted_keys: ["LITELLM_MASTER_KEY", "DATABASE_URL"]
|
||||
hosted_keys: ["LITELLM_MASTER_KEY", "DATABASE_URL", "REDIS_SSL_URL", "REDIS_HOST", "REDIS_PORT", "REDIS_PASSWORD"]
|
||||
|
||||
|
|
|
@ -10263,6 +10263,8 @@ def get_secret(
|
|||
# Extract and decode the plaintext
|
||||
plaintext = response["Plaintext"]
|
||||
secret = plaintext.decode("utf-8")
|
||||
if isinstance(secret, str):
|
||||
secret = secret.strip()
|
||||
elif key_manager == KeyManagementSystem.AWS_SECRET_MANAGER.value:
|
||||
try:
|
||||
get_secret_value_response = client.get_secret_value(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue