Skip to content

Commit e6ce9b6

Browse files
authored
Merge pull request #97 from spacesuitdiver/patch-1
Add credentials in the event no awscli credentials are available.
2 parents f6dbc6b + 2d32f2f commit e6ce9b6

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

README.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,14 +165,19 @@ var AWS = require('aws-sdk');
165165
```
166166
new AWS.DynamoDB.DocumentClient({
167167
region: 'localhost',
168-
endpoint: 'http://localhost:8000'
168+
endpoint: 'http://localhost:8000',
169+
accessKeyId: 'DEFAULT_ACCESS_KEY', // needed if you don't have aws credentials at all in env
170+
secretAccessKey: 'DEFAULT_SECRET' // needed if you don't have aws credentials at all in env
169171
})
170172
```
171173
e.g. for dynamodb document client sdk
172174
```
173175
new AWS.DynamoDB({
174176
region: 'localhost',
175-
endpoint: 'http://localhost:8000'
177+
endpoint: 'http://localhost:8000',
178+
accessKeyId: 'DEFAULT_ACCESS_KEY', // needed if you don't have aws credentials at all in env
179+
secretAccessKey: 'DEFAULT_SECRET' // needed if you don't have aws credentials at all in env
180+
176181
})
177182
```
178183

0 commit comments

Comments
 (0)