setting up AWS with Drizzle
Hello I’m trying to configure drizzle to connect to my AWS RDS. The docs state:
``
import { drizzle } from 'drizzle-orm/aws-data-api/pg';
import { RDSDataClient } from '@aws-sdk/client-rds-data';
import { fromIni } from '@aws-sdk/credential-providers';
const rdsClient = new RDSDataClient({
credentials: fromIni({ profile: process.env['PROFILE'] }),
region: 'us-east-1',
});
const db = drizzle(rdsClient, {
database: process.env['DATABASE']!,
secretArn: process.env['SECRET_ARN']!,
resourceArn: process.env['RESOURCE_ARN']!,
});
await db.select().from(...)...; ```
I’m looking at a page similar to this YouTube tutorial and I’m completely lost what profile, database and ARNs are. If you have successfully set this up can you please point me in the right direction. I know this is probably stupid question sorry 😣
5 Replies
the region
@goto3 what about the profile, database, and ARN.
const rdsClient = new RDSDataClient({
credentials: fromIni({ profile: process.env['PROFILE'] }),
region: 'us-east-1',
});
@goto3 thanks for pointing that out but my current issue is I don’t understand what I need to put in my ENV for PROFILE, DATABASE, and SECRET_ARN