Skip to content

Feature/aws iam authentication #12

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 20 additions & 3 deletions docs/docs/connection-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,18 +75,35 @@ node dist/src/index.js --postgresql --host dbserver.example.com --database sampl
| `--mysql` | Specifies MySQL mode | - | Yes |
| `--host` | MySQL hostname or IP | - | Yes |
| `--database` | Database name | - | Yes |
| `--user` | MySQL username | - | No |
| `--password` | MySQL password | - | No |
| `--user` | MySQL username | - | No* |
| `--password` | MySQL password | - | No* |
| `--port` | MySQL port | 3306 | No |
| `--ssl` | Use SSL connection (true/false or object) | false | No |
| `--connection-timeout` | Connection timeout in ms | 30000 | No |
| `--aws-iam-auth` | Enable AWS IAM authentication | false | No |
| `--aws-region` | AWS region for RDS IAM auth | - | No** |

### Example
*Required for standard authentication
**Required when using `--aws-iam-auth`

### Standard Authentication Example

```bash
node dist/src/index.js --mysql --host localhost --database sample_db --port 3306 --user root --password secret
```

### AWS IAM Authentication Example

**Prerequisites:** AWS credentials must be configured using the default credential provider chain:
- `aws configure` (default profile)
- `AWS_PROFILE=myprofile` environment variable
- `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY` environment variables
- IAM roles (if running on EC2)

```bash
node dist/src/index.js --mysql --aws-iam-auth --host rds-endpoint.region.rds.amazonaws.com --database sample_db --user aws-username --aws-region us-east-1
```

## Environment Variables

Instead of specifying sensitive credentials on the command line, you can use environment variables:
Expand Down
Loading
Loading