Skip to content

Commit

Permalink
adds docs for aws secret manager
Browse files Browse the repository at this point in the history
  • Loading branch information
zemuldo committed Apr 17, 2024
1 parent 800fcb7 commit 5c78e63
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 1 deletion.
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ You can configure:
- Azure Keyvault
- Azure Managed Identity
- Google Secret Manager
- AWS Secret Manager

## Provider Config

Expand Down Expand Up @@ -153,6 +154,19 @@ Using certificate. You can use `client_certificate_path` or `client_certificate_
}
```

AWS Secret Manager:

Using secret access key. Using instance role is coming soon.

```elixir
config :ex_secrets, :providers, %{
aws_secrets_manager: %{
access_key_id: "taccess_key_id",
secret_access_key: "secret_access_key"
}
}
```

Dotenv file:

```elixir
Expand Down
17 changes: 16 additions & 1 deletion lib/providers/aws_secrets_manager.ex
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,22 @@ defmodule ExSecrets.Providers.AwsSecretsManager do
use ExSecrets.Providers.Base

@moduledoc """
This module functions to access secrets in an Elixir application.
This module provides a provider for AWS Secrets Manager - https://aws.amazon.com/secrets-manager/
Code for authenticating with AWS has been has been forked from ex_aws See https://github.com/ex-aws/ex_aws
## Configuration
```elixir
config :ex_secrets, :providers, %{
aws_secrets_manager: %{
access_key_id: "taccess_key_id",
secret_access_key: "secret_access_key"
}
}
```
Its is recomended to create an access key and secret access key for the access key with only the required permissions.
Limiting thye scope of the access key will help in reducing the risk of the access key being compromised.
"""

@process_name :ex_secrets_aws_secrets_manager
Expand Down

0 comments on commit 5c78e63

Please sign in to comment.