title: Take Scheduled EBS Snapshots using Cloud Watch and Cloud Formation
body: <p>The task seems to be simple: I want to take scheduled EBS snapshots of my EBS volumes on a daily basis. According to the documentation, CloudWatch seems to be the right place to do that:
  <a href="http://docs.aws.amazon.com/AmazonCloudWatch/latest/events/TakeScheduledSnapshot.html" rel="nofollow">http://docs.aws.amazon.com/AmazonCloudWatch/latest/events/TakeScheduledSnapshot.html</a></p>
  
  <p>Now I want to create such a scheduled rule when launching a new stack with CloudFormation. For this, there is a new resource type <code>AWS::Events::Rule</code>:
  <a href="http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-events-rule.html" rel="nofollow">http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-events-rule.html</a></p>
  
  <p>But now comes the tricky part: How can I use this resource type to create a built-in target that creates my EBS snapshot, like described in the above scenario?</p>
  
  <p>I'm pretty sure there is way to do it, but I can't help myself right now. My resource template looks like this at the moment:</p>
  
  <pre><code>"DailyEbsSnapshotRule": {
        "Type": "AWS::Events::Rule",
        "Properties": {
          "Description": "creates a daily snapshot of EBS volume (8 a.m.)",
          "ScheduleExpression": "cron(0 8 * * ? *)",
          "State": "ENABLED",
          "Targets": [{
            "Arn": { "Fn::Join": [ "", "arn:aws:ec2:", { "Ref": "AWS::Region" }, ":", { "Ref": "AWS::AccountId" }, ":volume/", { "Ref": "EbsVolume" } ] },
            "Id": "SomeId1"
          }]
        }
      }
  </code></pre>
  
  <p>Any ideas? </p>