9
10

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

CloudFormationからElasticFileSytemをとりあえず立ち上げる(随時更新)

Posted at

夢叶ふ

ついにきましたね、EFS。

とりあえずFileSystemを立ち上げる

画面からだと面白くないので、かねてからずっと「あるけど使えないなー」と思っていたCloudFormationから立ち上げてみました。

AWS::EFS::FileSystem:https://docs.aws.amazon.com/ja_jp/AWSCloudFormation/latest/UserGuide/aws-resource-efs-filesystem.html

efs.json
{
  "AWSTemplateFormatVersion": "2010-09-09",
  "Description": "EFS Demo\n",
  "Resources": {
    "EFSFileSystem": {
      "Type": "AWS::EFS::FileSystem",
      "Properties": {
        "FileSystemTags": [
          {
            "Key": "Name",
            "Value": "EFSTest"
          }
        ]
      }
    }
  }
}

kumogataだとこんな感じです。

efs.rb
AWSTemplateFormatVersion "2010-09-09"
Description (<<-EOS).undent
  EFS Demo
EOS

Resources do
	EFSFileSystem do
		Type "AWS::EFS::FileSystem"
		Properties do
			FileSystemTags [
				_{
					Key "Name"
					Value "EFSTest"
				}
			]
		end
	end
end

実行結果

Stack Resource Summaries:
[
  {
    "LogicalResourceId": "EFSFileSystem",
    "PhysicalResourceId": "fs-XXXXXX",
    "ResourceType": "AWS::EFS::FileSystem",
    "ResourceStatus": "CREATE_COMPLETE",
    "ResourceStatusReason": null,
    "LastUpdatedTimestamp": "2016-06-29 04:39:16 UTC"
  }
]

Outputs:
{
}

スクリーンショット 2016-06-29 13.44.44.png

これだけだとEC2へのマウントも何もしていない「ただのファイルシステム」ですが、勢いは大事ということで一旦シェアします。

引き続きマウントとかやっていきますね。

9
10
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
9
10

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?