@@ -75,18 +75,35 @@ node dist/src/index.js --postgresql --host dbserver.example.com --database sampl
75
75
| ` --mysql ` | Specifies MySQL mode | - | Yes |
76
76
| ` --host ` | MySQL hostname or IP | - | Yes |
77
77
| ` --database ` | Database name | - | Yes |
78
- | ` --user ` | MySQL username | - | No |
79
- | ` --password ` | MySQL password | - | No |
78
+ | ` --user ` | MySQL username | - | No* |
79
+ | ` --password ` | MySQL password | - | No* |
80
80
| ` --port ` | MySQL port | 3306 | No |
81
81
| ` --ssl ` | Use SSL connection (true/false or object) | false | No |
82
82
| ` --connection-timeout ` | Connection timeout in ms | 30000 | No |
83
+ | ` --aws-iam-auth ` | Enable AWS IAM authentication | false | No |
84
+ | ` --aws-region ` | AWS region for RDS IAM auth | - | No** |
83
85
84
- ### Example
86
+ * Required for standard authentication
87
+ ** Required when using ` --aws-iam-auth `
88
+
89
+ ### Standard Authentication Example
85
90
86
91
``` bash
87
92
node dist/src/index.js --mysql --host localhost --database sample_db --port 3306 --user root --password secret
88
93
```
89
94
95
+ ### AWS IAM Authentication Example
96
+
97
+ ** Prerequisites:** AWS credentials must be configured using the default credential provider chain:
98
+ - ` aws configure ` (default profile)
99
+ - ` AWS_PROFILE=myprofile ` environment variable
100
+ - ` AWS_ACCESS_KEY_ID ` and ` AWS_SECRET_ACCESS_KEY ` environment variables
101
+ - IAM roles (if running on EC2)
102
+
103
+ ``` bash
104
+ 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
105
+ ```
106
+
90
107
## Environment Variables
91
108
92
109
Instead of specifying sensitive credentials on the command line, you can use environment variables:
0 commit comments