Skip to content

RDS

CloudMock emulates Amazon RDS management operations, supporting DB instance, cluster, snapshot, and subnet group lifecycle. Instances are metadata-only records — no database engine is started.

OperationStatusNotes
CreateDBInstanceSupportedCreates a DB instance record
DeleteDBInstanceSupportedDeletes a DB instance
DescribeDBInstancesSupportedReturns all DB instances
ModifyDBInstanceSupportedUpdates instance attributes
CreateDBClusterSupportedCreates an Aurora cluster
DeleteDBClusterSupportedDeletes a cluster
DescribeDBClustersSupportedReturns all clusters
CreateDBSnapshotSupportedCreates a snapshot of a DB instance
DeleteDBSnapshotSupportedDeletes a snapshot
DescribeDBSnapshotsSupportedReturns all snapshots
CreateDBSubnetGroupSupportedCreates a subnet group
DescribeDBSubnetGroupsSupportedReturns all subnet groups
DeleteDBSubnetGroupSupportedDeletes a subnet group
AddTagsToResourceSupportedAdds tags to a resource
RemoveTagsFromResourceSupportedRemoves tags
ListTagsForResourceSupportedReturns tags for a resource
Terminal window
# Create a DB instance
curl -X POST "http://localhost:4566/?Action=CreateDBInstance&DBInstanceIdentifier=my-db&DBInstanceClass=db.t3.micro&Engine=mysql&MasterUsername=admin&MasterUserPassword=Password123&AllocatedStorage=20"
# Describe instances
curl -X POST "http://localhost:4566/?Action=DescribeDBInstances"
import { RDSClient, CreateDBInstanceCommand, DescribeDBInstancesCommand } from '@aws-sdk/client-rds';
const rds = new RDSClient({
endpoint: 'http://localhost:4566',
region: 'us-east-1',
credentials: { accessKeyId: 'test', secretAccessKey: 'test' },
});
await rds.send(new CreateDBInstanceCommand({
DBInstanceIdentifier: 'test-db',
DBInstanceClass: 'db.t3.micro',
Engine: 'postgres',
MasterUsername: 'postgres',
MasterUserPassword: 'postgres123',
AllocatedStorage: 20,
}));
const { DBInstances } = await rds.send(new DescribeDBInstancesCommand({}));
DBInstances?.forEach(db => console.log(db.DBInstanceIdentifier, db.DBInstanceStatus));
import boto3
rds = boto3.client('rds', endpoint_url='http://localhost:4566',
aws_access_key_id='test', aws_secret_access_key='test',
region_name='us-east-1')
rds.create_db_instance(
DBInstanceIdentifier='test-db',
DBInstanceClass='db.t3.micro',
Engine='postgres',
MasterUsername='postgres',
MasterUserPassword='postgres123',
AllocatedStorage=20,
)
response = rds.describe_db_instances()
for db in response['DBInstances']:
print(db['DBInstanceIdentifier'], db['DBInstanceStatus'])
cloudmock.yml
services:
rds:
enabled: true

No additional service-specific configuration is required.

  • DB instances are metadata-only records. No actual database engine is started.
  • Connection strings and endpoints returned in DescribeDBInstances are synthetic and not connectable.
  • Parameter groups, option groups, and enhanced monitoring are accepted but not enforced.
  • Aurora serverless v2, Proxy, and Blue/Green deployments are not implemented.
  • Instance status immediately transitions to available after creation.
CodeHTTP StatusDescription
DBInstanceNotFound404The specified DB instance does not exist
DBInstanceAlreadyExists400A DB instance with this identifier already exists
DBSnapshotNotFound404The specified snapshot does not exist
InvalidDBInstanceState400The DB instance is not in a valid state for this operation