AWS Classroomnotes 16/Dec/2022

Activity

  • Create a free tier rds instance from aws cli create-db-instance
  • Show the endpoint describe-db-instance
  • Delete the rds instance delete-db-instance
#!/bin/bash
# create the database
aws rds create-db-instance \
    --db-instance-identifier qt-mysql-instance \
    --db-instance-class db.t3.micro \
    --engine mysql \
    --master-username admin \
    --master-user-password secret99 \
    --allocated-storage 20
# wait till the database is created
endpoint=$(aws rds describe-db-instances \
    --db-instance-identifier qt-mysql-instance \
    --query "DBInstances[].Endpoint.Address" \
    --output text)

# delete the database
aws rds delete-db-instance \
    --db-instance-identifier qt-mysql-instance \
    --skip-final-snapshot \
    --delete-automated-backups

Published
Categorized as Uncategorized Tagged

By continuous learner

devops & cloud enthusiastic learner

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Please turn AdBlock off
Animated Social Media Icons by Acurax Responsive Web Designing Company

Discover more from Direct DevOps from Quality Thought

Subscribe now to keep reading and get access to the full archive.

Continue reading

Visit Us On FacebookVisit Us On LinkedinVisit Us On Youtube