-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Description
Describe the bug
Laravel application with DynamoDB as cache and session driver fails to connect due to credentials missing. I've been using the same config as before for v3.258 and started failing when updated to v3.281.12
Error: Credentials must be an instance of 'Aws\Credentials\CredentialsInterface, an associative array that contains "key", "secret", and an optional "token" key-value pairs, a credentials provider function, or false.Array
The same app works on EC2 with role that has same permissions as the Lambda role.
Expected Behavior
Load the app by opening connection to DynamoDB for session and cache storage
Current Behavior
Laravel App with bref/bref that enables the app to run on lambda as a function, started failing when aws-sdk-php package was updated to 3.281.12 with error related to credentials
Error: Credentials must be an instance of 'Aws\Credentials\CredentialsInterface, an associative array that contains "key", "secret", and an optional "token" key-value pairs, a credentials provider function, or false.Array
Upon adding more debug logs to the library when it creates AWS Client, I see that there's only token being generated in the credentials and not key or secret being passed.
Reproduction Steps
Load Laravel app with Bref on a Lambda function and dynamodb as cache or session driver
Possible Solution
No response
Additional Information/Context
No response
SDK version used
3.281.12
Environment details (Version of PHP (php -v
)? OS name and version, etc.)
php 8.2 with arn:aws:lambda:us-east-2:534081306603:layer:php-82-fpm:48 layer