Skip to content

Instantly share code, notes, and snippets.

@serban-petrescu
Created February 8, 2021 12:25
Show Gist options
  • Save serban-petrescu/61bef041642cc96213a089595da78cf3 to your computer and use it in GitHub Desktop.
Save serban-petrescu/61bef041642cc96213a089595da78cf3 to your computer and use it in GitHub Desktop.
const database = new rds.DatabaseInstance(this, 'example', {
engine: rds.DatabaseInstanceEngine.postgres({ version: rds.PostgresEngineVersion.VER_11 }),
vpc: ec2.Vpc.fromLookup(this, 'vpc', { isDefault: true }),
credentials: rds.Credentials.fromGeneratedSecret('admin'),
// other RDS instance properties
});
database.addRotationSingleUser({
automaticallyAfter: cdk.Duration.days(8 * 7),
excludeCharacters: '!@#$%^&*'
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment