Error calling SSM to get parameters Name or service not known

0

My dotnet web application lambda was working great, I have the distributed Redis cache working with data protection enabled with services.AddDataProtection(). PersistKesToAWSSystemsManager ("/AWCWebManager/DataProtection"). Everything worked fine for a more than 10 days of testing and development, however after a seemingly incremental and unrelated change to the app after publishing to AWS Lambda now the Web client on access to the application times out with:

{"message": "Endpoint request timed out"}

In the Event Logs I see:

021-05-27 01:15:08: info: Amazon.AspNetCore.DataProtection.SSM.SSMXmlRepository[0]
2021-05-27 01:15:08: Using SSM Parameter Store to persist DataProtection keys with parameter name prefix /AWCWebManager/DataProtection/
2021-05-27 01:15:08: [Information] Amazon.AspNetCore.DataProtection.SSM.SSMXmlRepository: Using SSM Parameter Store to persist DataProtection keys with parameter name prefix /AWCWebManager/DataProtection/
2021-05-27 01:15:42: fail: Amazon.AspNetCore.DataProtection.SSM.SSMXmlRepository[0]
2021-05-27 01:15:42: Error calling SSM to get parameters starting with /AWCWebManager/DataProtection/: Name or service not known
2021-05-27 01:15:42: [Error] Amazon.AspNetCore.DataProtection.SSM.SSMXmlRepository: Error calling SSM to get parameters starting with /AWCWebManager/DataProtection/: Name or service not known
2021-05-27 01:15:42: fail: Microsoft.AspNetCore.DataProtection.KeyManagement.KeyRingProvider[48]
2021-05-27 01:15:42: An error occurred while reading the key ring.

Checking IAM the application role has full access to SSM.
The AWS Systems Manager Parameter Store has a few rows with proper prefix and different /key suffix.
Anyone have suggestions as to what could cause the data session protection with SSM to glitch like this?
Thanks,
Mike

mwfox
질문됨 3년 전378회 조회
1개 답변
0

The problem stemmed from adding a second website project to the visual studio solution. The second website did not have any permissions or used SSM. I noticed the wrong appsetting.json in the S2 bucket, by removing the second web project and redeploying everything is back to working. It would be great if the Visual Studio publish Lambda function realized it did not know how to handle the situation and offered a warning instead of populating the bucket with broken configuraitons.

mwfox
답변함 3년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠