https://github.com/tejeshkumarreddyc/auto-backup-and-dr-of-ec2-ebs
In this project backup of EC2 instance and EBS is taken and stored in different aws region for disaster recovery(DR) and can be recovered if it is needed.
https://github.com/tejeshkumarreddyc/auto-backup-and-dr-of-ec2-ebs
aws aws-backup coldstorage disaster-recovery ebs-volumes ec2 event-driven eventbridge iam lambda sns-notifications
Last synced: 20 days ago
JSON representation
In this project backup of EC2 instance and EBS is taken and stored in different aws region for disaster recovery(DR) and can be recovered if it is needed.
- Host: GitHub
- URL: https://github.com/tejeshkumarreddyc/auto-backup-and-dr-of-ec2-ebs
- Owner: TejeshKumarReddyC
- Created: 2025-01-31T12:31:02.000Z (3 months ago)
- Default Branch: master
- Last Pushed: 2025-02-01T16:44:32.000Z (3 months ago)
- Last Synced: 2025-02-13T10:53:23.030Z (2 months ago)
- Topics: aws, aws-backup, coldstorage, disaster-recovery, ebs-volumes, ec2, event-driven, eventbridge, iam, lambda, sns-notifications
- Language: Python
- Homepage:
- Size: 19.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
**Workflow:-** EC2_or_EBS ---> EventBridge ---> Lambda ---> Auto_backup(AWS_Backup) ---> If_backup_fails_send_notification(SNS).
-->**Introduction:**
In this project whenever an **EC2** instance is powered on or powered off then it triggers the **LAMBDA** via **EVENTBRIDGE**. That **LAMBDA_function** starts the backup job in **AWS_BACKUP_VAULT**, if backup job is failed then an alert will be sent by the **SNS**.-->**Configurations:**
I. Launch an **EC2** instance.
II. Create a **EVENTBUS** and create a **rule** with the below pattern in that eventbus.
Note: Replace the instance_id with yours.
{
"source": ["aws.ec2"],
"detail-type": ["EC2 Instance State-change Notification"],
"detail": {
"state": ["stopped", "running"],
"instance-id": ["Your_instance_id"]
}
}III. Create an **SNS_TOPIC** and subscribe to that with the email.
IV. Create a **LAMBDA_FUNCTION**.
V. Create the backup vault in **AWS_BACKUP**.