-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #30 from antonku/chore/upgrade-aws-sdk
chore: aws-sdk v2 -> v3 migration
- Loading branch information
Showing
6 changed files
with
3,303 additions
and
181 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
# 1.0.0. Release notes (2023-08-02) | ||
|
||
- `aws-sdk` is no longer a peer dependency | ||
- [BREAKING] From now on the minimum supported version of Node.js is 14.0.0. | ||
- [BREAKING] Changes in IAM configuration. If you explicitly passed aws-sdk@2 credentials to `VaultClient.boot` like below: | ||
```js | ||
const vaultClient = VaultClient.boot('main', { | ||
api: {url: 'https://vault.example.com:8200/'}, | ||
auth: { | ||
type: 'iam', | ||
mount: 'example', | ||
config: { | ||
iam_server_id_header_value: 'example', | ||
role: 'example', | ||
credentials: AWS.CredentialProviderChain.defaultProviders // <-- this line | ||
} | ||
}, | ||
}); | ||
``` | ||
This will no longer work. You need to either: | ||
- Do not pass the credentials at all and rely on the credentials auto-discovery | ||
```js | ||
const vaultClient = VaultClient.boot('main', { | ||
api: {url: 'https://vault.example.com:8200/'}, | ||
auth: { | ||
type: 'iam', | ||
mount: 'example', | ||
config: { | ||
iam_server_id_header_value: 'example', | ||
role: 'example', | ||
} | ||
}, | ||
}); | ||
``` | ||
[OR] | ||
- Pass the credentials explicitly in the following format | ||
```js | ||
const vaultClient = VaultClient.boot('main', { | ||
api: {url: 'https://vault.example.com:8200/'}, | ||
auth: { | ||
type: 'iam', | ||
mount: 'example', | ||
config: { | ||
iam_server_id_header_value: 'example', | ||
role: 'example', | ||
credentials: { | ||
accessKeyId: 'AWS_ACCESS_KEY', | ||
secretAccessKey: 'AWS_SECRET_KEY', | ||
} | ||
} | ||
}, | ||
}); | ||
``` |
Oops, something went wrong.