문제

Brand new to AWS and trying to put together a stack with a CloudFormation template.

The stack will have two EC2 Instances with a windows service running on each. Some of the storage will be on S3 and some will be on AWS Glacier.

I can't find samples or instructions on how to add Glacier as Resource in the CF Template.

Am I missing something and this is not possible through a CF template?

Has anyone done this before, and can someone provide a sample, if it is possible?

Thanks.

도움이 되었습니까?

해결책

As of 2013-02-27, CloudFormation does not support Glacier.

If/when it does, you'll see Glacier show up in the CloudFormation resource types documentation here:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-template-resource-type-ref.html

Any support for auto-migration from S3 to Glacier should show up here:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket.html

To register your desire for Amazon to work on this feature, add a +1 comment in this forum thread:

https://forums.aws.amazon.com/thread.jspa?threadID=117947

다른 팁

Workaround would be following: Instead you can user the S3 rules to attach a Glacier policy OR S3 Lifecycle Rule. This rule will move the object automatically to the Glacier or even delete object after some time.

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket-lifecycleconfig-rule.html

AWS CloudFormation has added support for custom resources, where you can use AWS Lambda functions to do the job of creating resources that CloudFormation doesn't natively support. The resource type in the CloudFormation template file would end up being AWS::CloudFormation::CustomResource or Custom::String

For more info, check these official AWS docs:

  1. http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-cfn-customresource.html?shortFooter=true
  2. http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/template-custom-resources-lambda.html?shortFooter=true
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top