Reputation: 602
I have integrated the AWS S3 ADK version 2.4.9 in iOS App. I'm seeing the below weird issue in my xcode.
Couldn't read credentials provider configurations from
Info.plist
. Please check yourInfo.plist
if you are providing the SDK configuration values throughInfo.plist
.
How can I resolve this?
Upvotes: 1
Views: 1100
Reputation: 847
You need to set the default SDK configuration through code or info.plist file of your app to use the defaultS3
client.
To do it via info.plist:
You need to replace the pool id and the regions for cognito identity id and S3 below.
<key>AWS</key>
<dict>
<key>CredentialsProvider</key>
<dict>
<key>CognitoIdentity</key>
<dict>
<key>Default</key>
<dict>
<key>PoolId</key>
<string>YOUR_POOL_ID_HERE</string>
<key>Region</key>
<string>USEast1</string>
</dict>
</dict>
</dict>
<key>S3</key>
<dict>
<key>Default</key>
<dict>
<key>Region</key>
<string>USEast1</string>
</dict>
</dict>
</dict>
To do it via code
AWSCognitoCredentialsProvider *credentialsProvider = [[AWSCognitoCredentialsProvider alloc] initWithRegionType:CognitoRegionType
identityPoolId:CognitoIdentityPoolId];
AWSServiceConfiguration *configuration = [[AWSServiceConfiguration alloc] initWithRegion:DefaultServiceRegionType
credentialsProvider:credentialsProvider];
AWSServiceManager.defaultServiceManager.defaultServiceConfiguration = configuration;
Thanks, Rohan
Upvotes: 4