Automating Database Management and Administrations
- All the cloud infra is generally created using Infra Provisioning tools such as terraform, cloudformation, ARM Templates
- For basic automations, we can use shell scripts which use AWS or Azure CLIs
Using AWS CLI to Manage Databases
- Configuring a user for CLI access in AWS
- Lets create a mysql rds instance (free tier)
- AWS CLI
aws <service> <action> [-parameter1 value1] ...[-parametern valuen]
- AWS CLI has output formats Refer Here
- AWS CLI can help in setting pagination
- AWS CLI output can be filtered Refer Here
- bash cheat sheat
- Refer Here for the script
- To be continued
Using Azure CLI to Manage Databases
- Azure CLI
az <service> [sub-components] action
- using bash with azure cli
- Refer Here for the changes
