You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/advanced/1_self_host/aws_eks_ecs.mdx
+58-1Lines changed: 58 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -104,14 +104,71 @@ Familiar with Terraform? The terraform files are available [here in Windmill's G
104
104
- We advise to use a certificate authority
105
105
- The port can be left to the default: `5432`
106
106
1. Database authentication
107
-
- Windmill uses Password authentication
107
+
- Windmill supports both Password authentication and IAM authentication. See [IAM database authentication](#iam-database-authentication) below for details on using IAM auth.
108
108
1. Monitoring
109
109
- Choose whatever you prefer to monitor your database
110
110
1. Additional configuration
111
111
- Initial database name should be set to `windmill`
112
112
- It is advised to enable automated backups
113
113
- Encryption can be set depending on your requirement, same for log export and maintenance.
114
114
115
+
### IAM database authentication
116
+
117
+
Windmill Enterprise supports IAM database authentication for RDS, eliminating the need to store database passwords. Windmill uses temporary IAM tokens that are automatically refreshed.
118
+
119
+
:::info Enterprise feature
120
+
IAM RDS authentication is only available in Windmill Enterprise Edition.
121
+
:::
122
+
123
+
#### Prerequisites
124
+
125
+
1.**Enable IAM authentication on your RDS instance**
126
+
- In RDS Console → Your instance → Modify → Enable "IAM database authentication"
127
+
128
+
2.**Grant the `rds_iam` role to the postgres user**
129
+
```sql
130
+
GRANT rds_iam TO postgres;
131
+
```
132
+
This tells RDS to accept IAM tokens for authentication. See [AWS documentation](https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/UsingWithRDS.IAMDBAuth.DBAccounts.html).
The port (`:5432`) is required for IAM authentication.
153
+
:::
154
+
155
+
Set the `AWS_REGION` environment variable:
156
+
```yaml
157
+
env:
158
+
- name: AWS_REGION
159
+
value: "eu-west-1"
160
+
```
161
+
162
+
On EKS, configure [IRSA](https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html) to provide AWS credentials to the pods.
163
+
164
+
#### Troubleshooting
165
+
166
+
| Error | Solution |
167
+
|-------|----------|
168
+
| `PAM authentication failed` | Check `AWS_REGION` is set and password is exactly `iamrds` |
169
+
| No `iamrds mode detected` log | Ensure you're using `windmill-ee` image |
170
+
| Token generation fails | Verify IRSA setup and `rds-db:connect` IAM policy |
171
+
115
172
### Create the ECS cluster
116
173
117
174
As said in the introduction, the architecture of your stack depends of your needs. The only requires parts are one Windmill server at least one multi-purpose worker.
0 commit comments