text: /*!------------------------------------------------------------------
   * Copyright 2019 Reindeer Technology Pte. Ltd.
   *
   * Licensed under the Apache License, Version 2.0 (the "License");
   * you may not use this file except in compliance with the License.
   * You may obtain a copy of the License at
   *
   *     http://www.apache.org/licenses/LICENSE-2.0
   *
   * Unless required by applicable law or agreed to in writing, software
   * distributed under the License is distributed on an "AS IS" BASIS,
   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   * See the License for the specific language governing permissions and
   * limitations under the License.
  *-------------------------------------------------------------------*/
  export const state = () => ({
  list:[{"id":"cloudDesignRoot","isRoot":true,"fmt":"json","lang":"cdd","data":"{\r\n    \"reindeer\": \"1.1.0\",\r\n    \"self\": \"cloudDesing.json\",\r\n    \"info\": {\r\n        \"title\": {\r\n            \"en\": \"Cloud Design Petstore\",\r\n            \"ja\": \"クラウドデザインペットストア\"\r\n        },\r\n        \"description\": {\r\n            \"en\": \"This is a sample definition of the cloud design. \",\r\n            \"ja\": \"これはクラウドデザインのサンプルドキュメントです。\"\r\n        },\r\n        \"version\": \"1.0.0\",\r\n        \"license\": {\r\n            \"type\": \"CC0\"\r\n        },\r\n        \"status\": \"draft\",\r\n        \"designedAt\": 1552999163,\r\n        \"authors\": {\r\n            \"ShintaroHara\": {\r\n                \"roles\": [\r\n                    \"designer\"\r\n                ],\r\n                \"joinedAt\": 1552299161,\r\n                \"leavedAt\": 1552999163\r\n            }\r\n        }\r\n    },\r\n    \"actors\": {\r\n        \"customer\": {\r\n            \"type\": \"market\",\r\n            \"title\": {\r\n                \"en\": \"Customers of the petstore site\",\r\n                \"ja\": \"ペットストアサイトの顧客\"\r\n            },\r\n            \"description\": {\r\n                \"en\": \"Prospected cutomers at 2019 in U.S.\",\r\n                \"ja\": \"米国における2019年の見込み顧客\"\r\n            },\r\n            \"sourceIdentification\": false,\r\n            \"market\": {\r\n                \"$ref\": \"#/components/markets/petMarketOfUS2019\"\r\n            },\r\n            \"marketShare\": 0.2\r\n        },\r\n        \"operator\": {\r\n            \"type\": \"persons\",\r\n            \"title\": {\r\n                \"en\": \"Operator of the petstore site\",\r\n                \"ja\": \"ペットストアサイトの運用担当者\"\r\n            },\r\n            \"description\": {\r\n                \"en\": \"Operators administrating inventory and customer's order information.\",\r\n                \"ja\": \"商品在庫や顧客の注文情報を管理する運用担当者\"\r\n            },\r\n            \"sourceIdentification\": true,\r\n            \"num\": 3\r\n        },\r\n        \"extermalCRMSystem\": {\r\n            \"$ref\": \"#/components/actors/externalAPIofCRM\"\r\n        }\r\n    },\r\n    \"resources\": [\r\n        {\r\n            \"$ref\": \"awsTemplate.json\",\r\n            \"type\": \"acf\"\r\n        },\r\n        {\r\n            \"$ref\": \"gcpTemplate.yaml\",\r\n            \"type\": \"gdm\"\r\n        }\r\n    ],\r\n    \"contexts\": {\r\n        \"customerWebAccess\": {\r\n            \"title\": {\r\n                \"en\": \"Website usage by customers\",\r\n                \"ja\": \"顧客によるウェブサイト利用\"\r\n            },\r\n            \"description\": {\r\n                \"en\": \"Customer's web access to the petstore site. Providing dynamic contents of our inventory and receiving purchase order.\",\r\n                \"ja\": \"顧客によるペットストアサイトへのWebアクセス。動的コンテンツを提供し、受注を受け付ける。\"\r\n            },\r\n            \"trigger\": {\r\n                \"type\": \"webAccess\",\r\n                \"description\": {\r\n                    \"en\": \"Customer's web access to the petstore.\",\r\n                    \"ja\": \"ペットストアに対する顧客のWEBアクセス\"\r\n                },\r\n                \"infoType\": {\r\n                    \"$ref\": \"#/components/infoTypes/classA\"\r\n                },\r\n                \"ports\": [\r\n                    443\r\n                ],\r\n                \"restriction\": false,\r\n                \"internet\": true,\r\n                \"pagesVisit\": {\r\n                    \"min\": 5,\r\n                    \"max\": 5\r\n                },\r\n                \"reqPage\": {\r\n                    \"min\": 100,\r\n                    \"max\": 100\r\n                },\r\n                \"kbPage\": {\r\n                    \"min\": 500,\r\n                    \"max\": 500\r\n                },\r\n                \"postsVisit\": {\r\n                    \"min\": 0.05,\r\n                    \"max\": 0.1\r\n                },\r\n                \"kbPost\": {\r\n                    \"min\": 50,\r\n                    \"max\": 100\r\n                },\r\n                \"busyHours\": {\r\n                    \"min\": 8,\r\n                    \"max\": 8\r\n                },\r\n                \"dau\": {\r\n                    \"min\": 0.05,\r\n                    \"max\": 0.1\r\n                },\r\n                \"storedRatio\": {\r\n                    \"min\":0,\r\n                    \"max\":0     \r\n                },\r\n                \"endpointTitle\": {\r\n                    \"en\": \"Load balancer (Redundant)\",\r\n                    \"ja\": \"ロードバランサー（冗長構成）\"\r\n                },\r\n                \"start\": {\r\n                    \"$ref\": \"#/actors/customer\"\r\n                },\r\n                \"end\": [\r\n                    {\r\n                        \"$ref\": \"awsTemplate.json#/resources/ApplicationLoadBalancer\"\r\n                    },\r\n                    {\r\n                        \"$ref\": \"awsTemplate.json#/resources/ALBListener\"\r\n                    }\r\n                ]\r\n            },\r\n            \"traffics\": {\r\n                \"dynamicContents\": {\r\n                    \"type\": \"passThroughRatio\",\r\n                    \"internet\": false,\r\n                    \"description\": {\r\n                        \"en\": \"Request dynamic contents and posting user data.\",\r\n                        \"ja\": \"動的コンテンツの要求とユーザーデータの送信\"\r\n                    },\r\n                    \"infoType\": {\r\n                        \"$ref\": \"#/components/infoTypes/classA\"\r\n                    },\r\n                    \"ports\": [\r\n                        80\r\n                    ],\r\n                    \"restriction\": true,\r\n                    \"source\": {\r\n                        \"$ref\": \"#/contexts/customerWebAccess/trigger\"\r\n                    },\r\n                    \"end\": [\r\n                        {\r\n                            \"$ref\": \"awsTemplate.json#/resources/ALBTargetGroup\"\r\n                        },\r\n                        {\r\n                            \"$ref\": \"awsTemplate.json#/resources/WebServerGroup\"\r\n                        },\r\n                        {\r\n                            \"$ref\": \"awsTemplate.json#/resources/LaunchConfig\"\r\n                        }\r\n                    ],\r\n                    \"passThroughReqRatio\": {\r\n                        \"max\": 1,\r\n                        \"min\": 1\r\n                    },\r\n                    \"compositResRatio\": {\r\n                        \"max\": 1,\r\n                        \"min\": 1\r\n                    },\r\n                    \"endpointTitle\": {\r\n                        \"en\": \"Web servers x 2~5 (Redundant)\",\r\n                        \"ja\": \"Webサーバ x 2~5（冗長構成）\"\r\n                    },\r\n                    \"storedRatio\": {\r\n                        \"min\": 0.5,\r\n                        \"max\": 1\r\n                    },\r\n                    \"storedInfoType\": {\r\n                        \"$ref\": \"#/components/infoTypes/classB\"\r\n                    },\r\n                    \"storageDescription\": {\r\n                        \"en\": \"Access log of the web application.\",\r\n                        \"ja\": \"WEBアプリケーションのログ\"\r\n                    }\r\n                },\r\n                \"storeAuditLogs\": {\r\n                    \"type\": \"passThroughRatio\",\r\n                    \"internet\": true,\r\n                    \"description\": {\r\n                        \"en\": \"Store logs aiming to detect security violation\",\r\n                        \"ja\": \"セキュリティ違反の検出を目的としたログを保存\"\r\n                    },\r\n                    \"infoType\": {\r\n                        \"$ref\": \"#/components/infoTypes/classB\"\r\n                    },\r\n                    \"ports\": [\r\n                        443\r\n                    ],\r\n                    \"restriction\": true,\r\n                    \"source\": {\r\n                        \"$ref\": \"#/contexts/customerWebAccess/traffics/dynamicContents\"\r\n                    },\r\n                    \"end\": [\r\n                        {\r\n                            \"$ref\": \"gcpTemplate.yaml#/resources/quickstart-deployment-vm\"\r\n                        }\r\n                    ],\r\n                    \"passThroughReqRatio\": {\r\n                        \"min\": 0.1,\r\n                        \"max\": 0.2\r\n                    },\r\n                    \"compositResRatio\": {\r\n                        \"min\": 0,\r\n                        \"max\": 0\r\n                    },\r\n                    \"endpointTitle\": {\r\n                        \"en\": \"Audit log processing\",\r\n                        \"ja\": \"セキュリティ監査ログ処理\"\r\n                    },\r\n                    \"storedRatio\": {\r\n                        \"min\": 1,\r\n                        \"max\": 1\r\n                    },\r\n                    \"storedInfoType\": {\r\n                        \"$ref\": \"#/components/infoTypes/classB\"\r\n                    },\r\n                    \"storageDescription\": {\r\n                        \"en\": \"Logs aiming to detect security violation\",\r\n                        \"ja\": \"セキュリティ監査用ログを格納\"\r\n                    }\r\n                },\r\n                \"storeCustomerData\": {\r\n                    \"type\": \"passThroughRatio\",\r\n                    \"internet\": false,\r\n                    \"description\": {\r\n                        \"en\": \"Request and post persistent data to database system.\",\r\n                        \"ja\": \"データベースシステムへの永続データの送受信\"\r\n                    },\r\n                    \"infoType\": {\r\n                        \"$ref\": \"#/components/infoTypes/classA\"\r\n                    },\r\n                    \"ports\": [\r\n                        3306\r\n                    ],\r\n                    \"restriction\": true,\r\n                    \"source\": {\r\n                        \"$ref\": \"#/contexts/customerWebAccess/traffics/dynamicContents\"\r\n                    },\r\n                    \"end\": [\r\n                        {\r\n                            \"$ref\": \"awsTemplate.json#/resources/DBInstance\"\r\n                        }\r\n                    ],\r\n                    \"passThroughReqRatio\": {\r\n                        \"min\": 0.1,\r\n                        \"max\": 0.5\r\n                    },\r\n                    \"compositResRatio\": {\r\n                        \"min\": 0.05,\r\n                        \"max\": 0.1\r\n                    },\r\n                    \"endpointTitle\": {\r\n                        \"en\": \"DB servers x 2 (Redundant)\",\r\n                        \"ja\": \"DBサーバ x 2（冗長構成）\"\r\n                    },\r\n                    \"storedRatio\": {\r\n                        \"min\": 1,\r\n                        \"max\": 1\r\n                    },\r\n                    \"storedInfoType\": {\r\n                        \"$ref\": \"#/components/infoTypes/classA\"\r\n                    },\r\n                    \"storageDescription\": {\r\n                        \"en\": \"Customer, order and inventory information and so on.\",\r\n                        \"ja\": \"顧客、受注、商品在庫などの情報を格納\"\r\n                    }\r\n                },\r\n                \"confirmationMail\": {\r\n                    \"type\": \"passThroughRatio\",\r\n                    \"internet\": true,\r\n                    \"description\": {\r\n                        \"en\": \"Sending order confirmation e-mail.\",\r\n                        \"ja\": \"受注確認メールの送信\"\r\n                    },\r\n                    \"infoType\": {\r\n                        \"$ref\": \"#/components/infoTypes/classA\"\r\n                    },\r\n                    \"ports\": [\r\n                        25,587\r\n                    ],\r\n                    \"restriction\": true,\r\n                    \"source\": {\r\n                        \"$ref\": \"#/contexts/customerWebAccess/traffics/dynamicContents\"\r\n                    },\r\n                    \"end\": [\r\n                        {\r\n                            \"$ref\": \"#/actors/customer\"\r\n                        }\r\n                    ],\r\n                    \"passThroughReqRatio\": {\r\n                        \"min\": 0.01,\r\n                        \"max\": 0.05\r\n                    },\r\n                    \"compositResRatio\": {\r\n                        \"min\": 0.005,\r\n                        \"max\": 0.01\r\n                    },\r\n                    \"endpointTitle\": {\r\n                        \"en\": \"Customers of the petstore site\",\r\n                        \"ja\": \"ペットストアサイトの利用者\"\r\n                    },\r\n                    \"storedRatio\": {\r\n                        \"min\": 0,\r\n                        \"max\": 0\r\n                    }\r\n                }\r\n            }\r\n        },\r\n        \"operatorWebAccess\": {\r\n            \"title\": {\r\n                \"en\": \"Console usage by operators\",\r\n                \"ja\": \"運用者の管理画面利用\"\r\n            },\r\n            \"description\": {\r\n                \"en\": \"Operator's web access to the console pages. Managing inventory, purchase order and contents publishing.\",\r\n                \"ja\": \"運用者による管理画面へのWebアクセス。商品在庫と注文、配信コンテンツの管理を行う。\"\r\n            },\r\n            \"trigger\": {\r\n                \"type\": \"webAccess\",\r\n                \"description\": {\r\n                    \"en\": \"Operator's web access to the console pages.\",\r\n                    \"ja\": \"運用者による管理画面へのWEBアクセス\"\r\n                },\r\n                \"infoType\": {\r\n                    \"$ref\": \"#/components/infoTypes/classA\"\r\n                },\r\n                \"ports\": [\r\n                    443\r\n                ],\r\n                \"restriction\": true,\r\n                \"internet\": true,\r\n                \"pagesVisit\": {\r\n                    \"min\": 10,\r\n                    \"max\": 10\r\n                },\r\n                \"reqPage\": {\r\n                    \"min\": 100,\r\n                    \"max\": 100\r\n                },\r\n                \"kbPage\": {\r\n                    \"min\": 300,\r\n                    \"max\": 500\r\n                },\r\n                \"postsVisit\": {\r\n                    \"min\": 0.5,\r\n                    \"max\": 1\r\n                },\r\n                \"kbPost\": {\r\n                    \"min\": 800,\r\n                    \"max\": 1024\r\n                },\r\n                \"busyHours\": {\r\n                    \"min\": 2,\r\n                    \"max\": 3\r\n                },\r\n                \"dau\": {\r\n                    \"min\": 0.8,\r\n                    \"max\": 1\r\n                },\r\n                \"storedRatio\": {\r\n                    \"min\":0,\r\n                    \"max\":0    \r\n                },\r\n                \"endpointTitle\": {\r\n                    \"en\": \"Load balancer (Redundant)\",\r\n                    \"ja\": \"ロードバランサー（冗長構成）\"\r\n                },\r\n                \"start\": {\r\n                    \"$ref\": \"#/actors/operator\"\r\n                },\r\n                \"end\": [\r\n                    {\r\n                        \"$ref\": \"awsTemplate.json#/resources/ApplicationLoadBalancer\"\r\n                    },\r\n                    {\r\n                        \"$ref\": \"awsTemplate.json#/resources/ALBListener\"\r\n                    }\r\n                ]\r\n            },\r\n            \"traffics\": {\r\n                \"dynamicContents\": {\r\n                    \"type\": \"passThroughRatio\",\r\n                    \"internet\": false,\r\n                    \"description\": {\r\n                        \"en\": \"Request dynamic contents and posting user data.\",\r\n                        \"ja\": \"動的コンテンツの要求とユーザーデータの送信\"\r\n                    },\r\n                    \"infoType\": {\r\n                        \"$ref\": \"#/components/infoTypes/classA\"\r\n                    },\r\n                    \"ports\": [\r\n                        80\r\n                    ],\r\n                    \"restriction\": true,\r\n                    \"source\": {\r\n                        \"$ref\": \"#/contexts/operatorWebAccess/trigger\"\r\n                    },\r\n                    \"end\": [\r\n                        {\r\n                            \"$ref\": \"awsTemplate.json#/resources/ALBTargetGroup\"\r\n                        },\r\n                        {\r\n                            \"$ref\": \"awsTemplate.json#/resources/WebServerGroup\"\r\n                        },\r\n                        {\r\n                            \"$ref\": \"awsTemplate.json#/resources/LaunchConfig\"\r\n                        }\r\n                    ],\r\n                    \"passThroughReqRatio\": {\r\n                        \"max\": 1,\r\n                        \"min\": 1\r\n                    },\r\n                    \"compositResRatio\": {\r\n                        \"max\": 1,\r\n                        \"min\": 1\r\n                    },\r\n                    \"endpointTitle\": {\r\n                        \"en\": \"Web servers x 2~5 (Redundant)\",\r\n                        \"ja\": \"Webサーバ x 2~5（冗長構成）\"\r\n                    },\r\n                    \"storedRatio\": {\r\n                        \"min\": 0.5,\r\n                        \"max\": 1\r\n                    },\r\n                    \"storedInfoType\": {\r\n                        \"$ref\": \"#/components/infoTypes/classB\"\r\n                    },\r\n                    \"storageDescription\": {\r\n                        \"en\": \"Access log of the web application.\",\r\n                        \"ja\": \"WEBアプリケーションのログ\"\r\n                    }\r\n                },\r\n                \"storeCustomerData\": {\r\n                    \"type\": \"passThroughRatio\",\r\n                    \"internet\": false,\r\n                    \"description\": {\r\n                        \"en\": \"Request and post persistent data to database system.\",\r\n                        \"ja\": \"データベースシステムへの永続データの要求と送信\"\r\n                    },\r\n                    \"infoType\": {\r\n                        \"$ref\": \"#/components/infoTypes/classA\"\r\n                    },\r\n                    \"ports\": [\r\n                        80\r\n                    ],\r\n                    \"restriction\": true,\r\n                    \"source\": {\r\n                        \"$ref\": \"#/contexts/operatorWebAccess/traffics/dynamicContents\"\r\n                    },\r\n                    \"end\": [\r\n                        {\r\n                            \"$ref\": \"awsTemplate.json#/resources/DBInstance\"\r\n                        }\r\n                    ],\r\n                    \"passThroughReqRatio\": {\r\n                        \"min\": 0.8,\r\n                        \"max\": 1.0\r\n                    },\r\n                    \"compositResRatio\": {\r\n                        \"min\": 0.5,\r\n                        \"max\": 0.8\r\n                    },\r\n                    \"endpointTitle\": {\r\n                        \"en\": \"DB servers x 2 (Redundant)\",\r\n                        \"ja\": \"DBサーバ x 2（冗長構成）\"\r\n                    },\r\n                    \"storedRatio\": {\r\n                        \"min\": 1,\r\n                        \"max\": 1\r\n                    },\r\n                    \"storedInfoType\": {\r\n                        \"$ref\": \"#/components/infoTypes/classA\"\r\n                    },\r\n                    \"storageDescription\": {\r\n                        \"en\": \"Customer, order and inventory information and so on.\",\r\n                        \"ja\": \"顧客、受注、商品在庫などの情報を格納\"\r\n                    }\r\n                }                \r\n            }\r\n        },\r\n        \"crmAPIcall\": {\r\n            \"title\": {\r\n                \"en\": \"Transfer customer data to CRM\",\r\n                \"ja\": \"CRMシステムへの顧客データ送信\"\r\n            },\r\n            \"description\": {\r\n                \"en\": \"Sending customer contact history to the external CRM System.\",\r\n                \"ja\": \"顧客との接触履歴を外部のCRMシステムに送信する。\"\r\n            },\r\n            \"trigger\": {\r\n                \"type\": \"timedAction\",\r\n                \"description\": {\r\n                    \"en\": \"Sending customer contact history periodically.\",\r\n                    \"ja\": \"顧客との接触履歴を定期的に送信\"\r\n                },\r\n                \"infoType\": {\r\n                    \"$ref\": \"#/components/infoTypes/classA\"\r\n                },\r\n                \"ports\": [\r\n                    443\r\n                ],\r\n                \"restriction\": true,\r\n                \"internet\": true,\r\n                 \"kbRequest\": {\r\n                     \"min\":100,\r\n                     \"max\":100\r\n                 },\r\n                  \"kbResponse\": {\r\n                       \"min\": 10,\r\n                       \"max\": 100\r\n                  },\r\n                   \"onlineRps\": {\r\n                       \"min\": 1,\r\n                       \"max\":1\r\n                   },\r\n                    \"reqMonth\": {\r\n                        \"min\":500000,\r\n                        \"max\":700000\r\n                    },\r\n                \"storedRatio\": {\r\n                    \"min\":0,\r\n                    \"max\":0     \r\n                },\r\n                \"endpointTitle\": {\r\n                    \"en\": \"External CRM System\",\r\n                    \"ja\": \"外部CRMシステム\"\r\n                },\r\n                \"start\": {\r\n                    \"$ref\": \"awsTemplate.json#/resources/WebServerGroup\"\r\n                },\r\n                \"end\":[\r\n                    {\r\n                        \"$ref\": \"#/actors/extermalCRMSystem\"\r\n                    }\r\n                ]\r\n            },\r\n            \"traffics\":{\r\n                \r\n            }\r\n        }\r\n    },\r\n    \"components\": {\r\n        \"actors\": {\r\n            \"externalAPIofCRM\": {\r\n                \"type\": \"externalSystem\",\r\n                \"title\": {\r\n                    \"en\": \"API of CRM System\",\r\n                    \"ja\": \"顧客管理システムのAPI\"\r\n                },\r\n                \"description\": {\r\n                    \"en\": \"API of the CRM System managing contacts information with customers.\",\r\n                    \"ja\": \"顧客との接触情報を管理するCRMシステムのAPI\"\r\n                },\r\n                \"sourceIdentification\": true,\r\n                \"identificationGroup\": \"ipAddressesOfCRM\"\r\n            }\r\n        },\r\n        \"markets\": {\r\n            \"petMarketOfUS2019\": {\r\n                \"num\": 829600,\r\n                \"title\": {\r\n                    \"en\": \"New households with pet US2019\",\r\n                    \"ja\": \"米国のペットあり新世帯数2019\"\r\n                },\r\n                \"description\": {\r\n                    \"en\": \"68% US households own pets in 2018 (by APPA) * 12.2M households increasing prediction in the next decade (by Harvard JCHS) /10\",\r\n                    \"ja\": \"米国世帯の2018年ペット所有率68% (APPA調べ) × 向こう10年の世帯数増加数12.2百万（JCHS調べ）/ 10\"\r\n                },\r\n                \"estimatedAt\": 1559880777,\r\n                \"estimatedBy\": \"Reindeer original\"\r\n            }\r\n        },\r\n        \"infoTypes\": {\r\n            \"classA\": {\r\n                \"title\": {\r\n                    \"en\": \"ClassA\",\r\n                    \"ja\": \"クラスA\"\r\n                },\r\n                \"description\": {\r\n                    \"en\": \"Secret information type including privacy data.\",\r\n                    \"ja\": \"個人情報を含む機密情報\"\r\n                },\r\n                \"privacy\": true,\r\n                \"confidential\": true,\r\n                \"definedAt\": 1514732400,\r\n                \"definedBy\": \"Reindeer Technology\"\r\n            },\r\n            \"classB\": {\r\n                \"title\": {\r\n                    \"en\": \"ClassB\",\r\n                    \"ja\": \"クラスB\"\r\n                },\r\n                \"description\": {\r\n                    \"en\": \"Marketing information type without personal data.\",\r\n                    \"ja\": \"個人情報を含まない統計情報\"\r\n                },\r\n                \"privacy\": false,\r\n                \"confidential\": true,\r\n                \"definedAt\": 1514732400,\r\n                \"definedBy\": \"Reindeer Technology\"\r\n            },\r\n            \"classC\": {\r\n                \"title\": {\r\n                    \"en\": \"ClassC\",\r\n                    \"ja\": \"クラスC\"\r\n                },\r\n                \"description\": {\r\n                    \"en\": \"Public information.\",\r\n                    \"ja\": \"一般に公開されている情報\"\r\n                },\r\n                \"privacy\": false,\r\n                \"confidential\": false,\r\n                \"definedAt\": 1514732400,\r\n                \"definedBy\": \"Reindeer Technology\"\r\n            }\r\n        }\r\n    }\r\n}","isUsed":true,"isValid":true,"dataObject":{"reindeer":"1.1.0","self":"cloudDesing.json","info":{"title":{"en":"Cloud Design Petstore","ja":"クラウドデザインペットストア"},"description":{"en":"This is a sample definition of the cloud design. ","ja":"これはクラウドデザインのサンプルドキュメントです。"},"version":"1.0.0","license":{"type":"CC0"},"status":"draft","designedAt":1552999163,"authors":{"ShintaroHara":{"roles":["designer"],"joinedAt":1552299161,"leavedAt":1552999163,"name":"ShintaroHara"}}},"actors":{"customer":{"type":"market","title":{"en":"Customers of the petstore site","ja":"ペットストアサイトの顧客"},"description":{"en":"Prospected cutomers at 2019 in U.S.","ja":"米国における2019年の見込み顧客"},"sourceIdentification":false,"market":{"$ref":"#/components/markets/petMarketOfUS2019"},"marketShare":0.2},"operator":{"type":"persons","title":{"en":"Operator of the petstore site","ja":"ペットストアサイトの運用担当者"},"description":{"en":"Operators administrating inventory and customer's order information.","ja":"商品在庫や顧客の注文情報を管理する運用担当者"},"sourceIdentification":true,"num":3},"extermalCRMSystem":{"$ref":"#/components/actors/externalAPIofCRM"}},"resources":[{"$ref":"awsTemplate.json","type":"acf"},{"$ref":"gcpTemplate.yaml","type":"gdm"}],"contexts":{"customerWebAccess":{"title":{"en":"Website usage by customers","ja":"顧客によるウェブサイト利用"},"description":{"en":"Customer's web access to the petstore site. Providing dynamic contents of our inventory and receiving purchase order.","ja":"顧客によるペットストアサイトへのWebアクセス。動的コンテンツを提供し、受注を受け付ける。"},"trigger":{"type":"webAccess","description":{"en":"Customer's web access to the petstore.","ja":"ペットストアに対する顧客のWEBアクセス"},"infoType":{"$ref":"#/components/infoTypes/classA"},"ports":[443],"restriction":false,"internet":true,"pagesVisit":{"min":5,"max":5},"reqPage":{"min":100,"max":100},"kbPage":{"min":500,"max":500},"postsVisit":{"min":0.05,"max":0.1},"kbPost":{"min":50,"max":100},"busyHours":{"min":8,"max":8},"dau":{"min":0.05,"max":0.1},"storedRatio":{"min":0,"max":0},"endpointTitle":{"en":"Load balancer (Redundant)","ja":"ロードバランサー（冗長構成）"},"start":{"$ref":"#/actors/customer"},"end":[{"$ref":"awsTemplate.json#/resources/ApplicationLoadBalancer"},{"$ref":"awsTemplate.json#/resources/ALBListener"}],"infoTypeObj":{"obj":{"title":{"en":"ClassA","ja":"クラスA"},"description":{"en":"Secret information type including privacy data.","ja":"個人情報を含む機密情報"},"privacy":true,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classA"}},"traffics":{"dynamicContents":{"type":"passThroughRatio","internet":false,"description":{"en":"Request dynamic contents and posting user data.","ja":"動的コンテンツの要求とユーザーデータの送信"},"infoType":{"$ref":"#/components/infoTypes/classA"},"ports":[80],"restriction":true,"source":{"$ref":"#/contexts/customerWebAccess/trigger"},"end":[{"$ref":"awsTemplate.json#/resources/ALBTargetGroup"},{"$ref":"awsTemplate.json#/resources/WebServerGroup"},{"$ref":"awsTemplate.json#/resources/LaunchConfig"}],"passThroughReqRatio":{"max":1,"min":1},"compositResRatio":{"max":1,"min":1},"endpointTitle":{"en":"Web servers x 2~5 (Redundant)","ja":"Webサーバ x 2~5（冗長構成）"},"storedRatio":{"min":0.5,"max":1},"storedInfoType":{"$ref":"#/components/infoTypes/classB"},"storageDescription":{"en":"Access log of the web application.","ja":"WEBアプリケーションのログ"},"infoTypeObj":{"obj":{"title":{"en":"ClassA","ja":"クラスA"},"description":{"en":"Secret information type including privacy data.","ja":"個人情報を含む機密情報"},"privacy":true,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classA"},"storageInfoTypeObj":{"obj":{"title":{"en":"ClassB","ja":"クラスB"},"description":{"en":"Marketing information type without personal data.","ja":"個人情報を含まない統計情報"},"privacy":false,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classB"}},"storeAuditLogs":{"type":"passThroughRatio","internet":true,"description":{"en":"Store logs aiming to detect security violation","ja":"セキュリティ違反の検出を目的としたログを保存"},"infoType":{"$ref":"#/components/infoTypes/classB"},"ports":[443],"restriction":true,"source":{"$ref":"#/contexts/customerWebAccess/traffics/dynamicContents"},"end":[{"$ref":"gcpTemplate.yaml#/resources/quickstart-deployment-vm"}],"passThroughReqRatio":{"min":0.1,"max":0.2},"compositResRatio":{"min":0,"max":0},"endpointTitle":{"en":"Audit log processing","ja":"セキュリティ監査ログ処理"},"storedRatio":{"min":1,"max":1},"storedInfoType":{"$ref":"#/components/infoTypes/classB"},"storageDescription":{"en":"Logs aiming to detect security violation","ja":"セキュリティ監査用ログを格納"},"infoTypeObj":{"obj":{"title":{"en":"ClassB","ja":"クラスB"},"description":{"en":"Marketing information type without personal data.","ja":"個人情報を含まない統計情報"},"privacy":false,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classB"},"storageInfoTypeObj":{"obj":{"title":{"en":"ClassB","ja":"クラスB"},"description":{"en":"Marketing information type without personal data.","ja":"個人情報を含まない統計情報"},"privacy":false,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classB"}},"storeCustomerData":{"type":"passThroughRatio","internet":false,"description":{"en":"Request and post persistent data to database system.","ja":"データベースシステムへの永続データの送受信"},"infoType":{"$ref":"#/components/infoTypes/classA"},"ports":[3306],"restriction":true,"source":{"$ref":"#/contexts/customerWebAccess/traffics/dynamicContents"},"end":[{"$ref":"awsTemplate.json#/resources/DBInstance"}],"passThroughReqRatio":{"min":0.1,"max":0.5},"compositResRatio":{"min":0.05,"max":0.1},"endpointTitle":{"en":"DB servers x 2 (Redundant)","ja":"DBサーバ x 2（冗長構成）"},"storedRatio":{"min":1,"max":1},"storedInfoType":{"$ref":"#/components/infoTypes/classA"},"storageDescription":{"en":"Customer, order and inventory information and so on.","ja":"顧客、受注、商品在庫などの情報を格納"},"infoTypeObj":{"obj":{"title":{"en":"ClassA","ja":"クラスA"},"description":{"en":"Secret information type including privacy data.","ja":"個人情報を含む機密情報"},"privacy":true,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classA"},"storageInfoTypeObj":{"obj":{"title":{"en":"ClassA","ja":"クラスA"},"description":{"en":"Secret information type including privacy data.","ja":"個人情報を含む機密情報"},"privacy":true,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classA"}},"confirmationMail":{"type":"passThroughRatio","internet":true,"description":{"en":"Sending order confirmation e-mail.","ja":"受注確認メールの送信"},"infoType":{"$ref":"#/components/infoTypes/classA"},"ports":[25,587],"restriction":true,"source":{"$ref":"#/contexts/customerWebAccess/traffics/dynamicContents"},"end":[{"$ref":"#/actors/customer"}],"passThroughReqRatio":{"min":0.01,"max":0.05},"compositResRatio":{"min":0.005,"max":0.01},"endpointTitle":{"en":"Customers of the petstore site","ja":"ペットストアサイトの利用者"},"storedRatio":{"min":0,"max":0},"infoTypeObj":{"obj":{"title":{"en":"ClassA","ja":"クラスA"},"description":{"en":"Secret information type including privacy data.","ja":"個人情報を含む機密情報"},"privacy":true,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classA"}}}},"operatorWebAccess":{"title":{"en":"Console usage by operators","ja":"運用者の管理画面利用"},"description":{"en":"Operator's web access to the console pages. Managing inventory, purchase order and contents publishing.","ja":"運用者による管理画面へのWebアクセス。商品在庫と注文、配信コンテンツの管理を行う。"},"trigger":{"type":"webAccess","description":{"en":"Operator's web access to the console pages.","ja":"運用者による管理画面へのWEBアクセス"},"infoType":{"$ref":"#/components/infoTypes/classA"},"ports":[443],"restriction":true,"internet":true,"pagesVisit":{"min":10,"max":10},"reqPage":{"min":100,"max":100},"kbPage":{"min":300,"max":500},"postsVisit":{"min":0.5,"max":1},"kbPost":{"min":800,"max":1024},"busyHours":{"min":2,"max":3},"dau":{"min":0.8,"max":1},"storedRatio":{"min":0,"max":0},"endpointTitle":{"en":"Load balancer (Redundant)","ja":"ロードバランサー（冗長構成）"},"start":{"$ref":"#/actors/operator"},"end":[{"$ref":"awsTemplate.json#/resources/ApplicationLoadBalancer"},{"$ref":"awsTemplate.json#/resources/ALBListener"}],"infoTypeObj":{"obj":{"title":{"en":"ClassA","ja":"クラスA"},"description":{"en":"Secret information type including privacy data.","ja":"個人情報を含む機密情報"},"privacy":true,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classA"}},"traffics":{"dynamicContents":{"type":"passThroughRatio","internet":false,"description":{"en":"Request dynamic contents and posting user data.","ja":"動的コンテンツの要求とユーザーデータの送信"},"infoType":{"$ref":"#/components/infoTypes/classA"},"ports":[80],"restriction":true,"source":{"$ref":"#/contexts/operatorWebAccess/trigger"},"end":[{"$ref":"awsTemplate.json#/resources/ALBTargetGroup"},{"$ref":"awsTemplate.json#/resources/WebServerGroup"},{"$ref":"awsTemplate.json#/resources/LaunchConfig"}],"passThroughReqRatio":{"max":1,"min":1},"compositResRatio":{"max":1,"min":1},"endpointTitle":{"en":"Web servers x 2~5 (Redundant)","ja":"Webサーバ x 2~5（冗長構成）"},"storedRatio":{"min":0.5,"max":1},"storedInfoType":{"$ref":"#/components/infoTypes/classB"},"storageDescription":{"en":"Access log of the web application.","ja":"WEBアプリケーションのログ"},"infoTypeObj":{"obj":{"title":{"en":"ClassA","ja":"クラスA"},"description":{"en":"Secret information type including privacy data.","ja":"個人情報を含む機密情報"},"privacy":true,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classA"},"storageInfoTypeObj":{"obj":{"title":{"en":"ClassB","ja":"クラスB"},"description":{"en":"Marketing information type without personal data.","ja":"個人情報を含まない統計情報"},"privacy":false,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classB"}},"storeCustomerData":{"type":"passThroughRatio","internet":false,"description":{"en":"Request and post persistent data to database system.","ja":"データベースシステムへの永続データの要求と送信"},"infoType":{"$ref":"#/components/infoTypes/classA"},"ports":[80],"restriction":true,"source":{"$ref":"#/contexts/operatorWebAccess/traffics/dynamicContents"},"end":[{"$ref":"awsTemplate.json#/resources/DBInstance"}],"passThroughReqRatio":{"min":0.8,"max":1},"compositResRatio":{"min":0.5,"max":0.8},"endpointTitle":{"en":"DB servers x 2 (Redundant)","ja":"DBサーバ x 2（冗長構成）"},"storedRatio":{"min":1,"max":1},"storedInfoType":{"$ref":"#/components/infoTypes/classA"},"storageDescription":{"en":"Customer, order and inventory information and so on.","ja":"顧客、受注、商品在庫などの情報を格納"},"infoTypeObj":{"obj":{"title":{"en":"ClassA","ja":"クラスA"},"description":{"en":"Secret information type including privacy data.","ja":"個人情報を含む機密情報"},"privacy":true,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classA"},"storageInfoTypeObj":{"obj":{"title":{"en":"ClassA","ja":"クラスA"},"description":{"en":"Secret information type including privacy data.","ja":"個人情報を含む機密情報"},"privacy":true,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classA"}}}},"crmAPIcall":{"title":{"en":"Transfer customer data to CRM","ja":"CRMシステムへの顧客データ送信"},"description":{"en":"Sending customer contact history to the external CRM System.","ja":"顧客との接触履歴を外部のCRMシステムに送信する。"},"trigger":{"type":"timedAction","description":{"en":"Sending customer contact history periodically.","ja":"顧客との接触履歴を定期的に送信"},"infoType":{"$ref":"#/components/infoTypes/classA"},"ports":[443],"restriction":true,"internet":true,"kbRequest":{"min":100,"max":100},"kbResponse":{"min":10,"max":100},"onlineRps":{"min":1,"max":1},"reqMonth":{"min":500000,"max":700000},"storedRatio":{"min":0,"max":0},"endpointTitle":{"en":"External CRM System","ja":"外部CRMシステム"},"start":{"$ref":"awsTemplate.json#/resources/WebServerGroup"},"end":[{"$ref":"#/actors/extermalCRMSystem"}],"infoTypeObj":{"obj":{"title":{"en":"ClassA","ja":"クラスA"},"description":{"en":"Secret information type including privacy data.","ja":"個人情報を含む機密情報"},"privacy":true,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"uri":"#/components/infoTypes/classA"}},"traffics":{}}},"components":{"actors":{"externalAPIofCRM":{"type":"externalSystem","title":{"en":"API of CRM System","ja":"顧客管理システムのAPI"},"description":{"en":"API of the CRM System managing contacts information with customers.","ja":"顧客との接触情報を管理するCRMシステムのAPI"},"sourceIdentification":true,"identificationGroup":"ipAddressesOfCRM"}},"markets":{"petMarketOfUS2019":{"num":829600,"title":{"en":"New households with pet US2019","ja":"米国のペットあり新世帯数2019"},"description":{"en":"68% US households own pets in 2018 (by APPA) * 12.2M households increasing prediction in the next decade (by Harvard JCHS) /10","ja":"米国世帯の2018年ペット所有率68% (APPA調べ) × 向こう10年の世帯数増加数12.2百万（JCHS調べ）/ 10"},"estimatedAt":1559880777,"estimatedBy":"Reindeer original"}},"infoTypes":{"classA":{"title":{"en":"ClassA","ja":"クラスA"},"description":{"en":"Secret information type including privacy data.","ja":"個人情報を含む機密情報"},"privacy":true,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"classB":{"title":{"en":"ClassB","ja":"クラスB"},"description":{"en":"Marketing information type without personal data.","ja":"個人情報を含まない統計情報"},"privacy":false,"confidential":true,"definedAt":1514732400,"definedBy":"Reindeer Technology"},"classC":{"title":{"en":"ClassC","ja":"クラスC"},"description":{"en":"Public information.","ja":"一般に公開されている情報"},"privacy":false,"confidential":false,"definedAt":1514732400,"definedBy":"Reindeer Technology"}}}},"codeErrors":[{"message":"HOME","startColumn":0,"startLineNumber":0,"endColumn":0,"endLineNumber":0}]},{"id":"awsTemplate.json","isRoot":false,"fmt":"json","lang":"acf","data":"{\r\n  \"AWSTemplateFormatVersion\" : \"2010-09-09\",\r\n\r\n  \"Description\" : \"AWS CloudFormation Sample Template WordPress_Multi_AZ: WordPress is web software you can use to create a beautiful website or blog. This template installs a highly-available, scalable WordPress deployment using a multi-az Amazon RDS database instance for storage. It demonstrates using the AWS CloudFormation bootstrap scripts to deploy WordPress. **WARNING** This template creates an Amazon EC2 instance, an Application Load Balancer and an Amazon RDS database instance. You will be billed for the AWS resources used if you create a stack from this template.\",\r\n\r\n  \"Parameters\" : {\r\n    \"VpcId\" : {\r\n      \"Type\" : \"AWS::EC2::VPC::Id\",\r\n      \"Description\" : \"VpcId of your existing Virtual Private Cloud (VPC)\",\r\n      \"ConstraintDescription\" : \"must be the VPC Id of an existing Virtual Private Cloud.\"\r\n    },\r\n\r\n    \"Subnets\" : {\r\n      \"Type\" : \"List<AWS::EC2::Subnet::Id>\",\r\n      \"Description\" : \"The list of SubnetIds in your Virtual Private Cloud (VPC)\",\r\n      \"ConstraintDescription\" : \"must be a list of at least two existing subnets associated with at least two different availability zones. They should be residing in the selected Virtual Private Cloud.\"\r\n    },\r\n\r\n    \"KeyName\": {\r\n      \"Description\" : \"Name of an existing EC2 KeyPair to enable SSH access to the instances\",\r\n      \"Type\": \"AWS::EC2::KeyPair::KeyName\",\r\n      \"ConstraintDescription\" : \"must be the name of an existing EC2 KeyPair.\"\r\n    },\r\n\r\n    \"InstanceType\" : {\r\n      \"Description\" : \"WebServer EC2 instance type\",\r\n      \"Type\" : \"String\",\r\n      \"Default\" : \"t2.small\",\r\n      \"AllowedValues\" : [ \"t1.micro\", \"t2.nano\", \"t2.micro\", \"t2.small\", \"t2.medium\", \"t2.large\", \"m1.small\", \"m1.medium\", \"m1.large\", \"m1.xlarge\", \"m2.xlarge\", \"m2.2xlarge\", \"m2.4xlarge\", \"m3.medium\", \"m3.large\", \"m3.xlarge\", \"m3.2xlarge\", \"m4.large\", \"m4.xlarge\", \"m4.2xlarge\", \"m4.4xlarge\", \"m4.10xlarge\", \"c1.medium\", \"c1.xlarge\", \"c3.large\", \"c3.xlarge\", \"c3.2xlarge\", \"c3.4xlarge\", \"c3.8xlarge\", \"c4.large\", \"c4.xlarge\", \"c4.2xlarge\", \"c4.4xlarge\", \"c4.8xlarge\", \"g2.2xlarge\", \"g2.8xlarge\", \"r3.large\", \"r3.xlarge\", \"r3.2xlarge\", \"r3.4xlarge\", \"r3.8xlarge\", \"i2.xlarge\", \"i2.2xlarge\", \"i2.4xlarge\", \"i2.8xlarge\", \"d2.xlarge\", \"d2.2xlarge\", \"d2.4xlarge\", \"d2.8xlarge\", \"hi1.4xlarge\", \"hs1.8xlarge\", \"cr1.8xlarge\", \"cc2.8xlarge\", \"cg1.4xlarge\"]\r\n,\r\n      \"ConstraintDescription\" : \"must be a valid EC2 instance type.\"\r\n    },\r\n\r\n    \"SSHLocation\": {\r\n      \"Description\": \"The IP address range that can be used to SSH to the EC2 instances\",\r\n      \"Type\": \"String\",\r\n      \"MinLength\": \"9\",\r\n      \"MaxLength\": \"18\",\r\n      \"Default\": \"0.0.0.0/0\",\r\n      \"AllowedPattern\": \"(\\\\d{1,3})\\\\.(\\\\d{1,3})\\\\.(\\\\d{1,3})\\\\.(\\\\d{1,3})/(\\\\d{1,2})\",\r\n      \"ConstraintDescription\": \"must be a valid IP CIDR range of the form x.x.x.x/x.\"\r\n    },\r\n\r\n    \"DBClass\" : {\r\n      \"Description\" : \"Database instance class\",\r\n      \"Type\" : \"String\",\r\n      \"Default\" : \"db.t2.small\",\r\n      \"AllowedValues\" : [ \"db.t1.micro\", \"db.m1.small\", \"db.m1.medium\", \"db.m1.large\", \"db.m1.xlarge\", \"db.m2.xlarge\", \"db.m2.2xlarge\", \"db.m2.4xlarge\", \"db.m3.medium\", \"db.m3.large\", \"db.m3.xlarge\", \"db.m3.2xlarge\", \"db.m4.large\", \"db.m4.xlarge\", \"db.m4.2xlarge\", \"db.m4.4xlarge\", \"db.m4.10xlarge\", \"db.r3.large\", \"db.r3.xlarge\", \"db.r3.2xlarge\", \"db.r3.4xlarge\", \"db.r3.8xlarge\", \"db.m2.xlarge\", \"db.m2.2xlarge\", \"db.m2.4xlarge\", \"db.cr1.8xlarge\", \"db.t2.micro\", \"db.t2.small\", \"db.t2.medium\", \"db.t2.large\"]\r\n,\r\n      \"ConstraintDescription\" : \"must select a valid database instance type.\"\r\n    },\r\n\r\n    \"DBName\" : {\r\n      \"Default\": \"wordpressdb\",\r\n      \"Description\" : \"The WordPress database name\",\r\n      \"Type\": \"String\",\r\n      \"MinLength\": \"1\",\r\n      \"MaxLength\": \"64\",\r\n      \"AllowedPattern\" : \"[a-zA-Z][a-zA-Z0-9]*\",\r\n      \"ConstraintDescription\" : \"must begin with a letter and contain only alphanumeric characters.\"\r\n    },\r\n\r\n    \"DBUser\" : {\r\n      \"NoEcho\": \"true\",\r\n      \"Description\" : \"The WordPress database admin account username\",\r\n      \"Type\": \"String\",\r\n      \"MinLength\": \"1\",\r\n      \"MaxLength\": \"16\",\r\n      \"AllowedPattern\" : \"[a-zA-Z][a-zA-Z0-9]*\",\r\n      \"ConstraintDescription\" : \"must begin with a letter and contain only alphanumeric characters.\"\r\n    },\r\n\r\n    \"DBPassword\" : {\r\n      \"NoEcho\": \"true\",\r\n      \"Description\" : \"The WordPress database admin account password\",\r\n      \"Type\": \"String\",\r\n      \"MinLength\": \"8\",\r\n      \"MaxLength\": \"41\",\r\n      \"AllowedPattern\" : \"[a-zA-Z0-9]*\",\r\n      \"ConstraintDescription\" : \"must contain only alphanumeric characters.\"\r\n    },\r\n\r\n    \"MultiAZDatabase\": {\r\n      \"Default\": \"false\",\r\n      \"Description\" : \"Create a Multi-AZ MySQL Amazon RDS database instance\",\r\n      \"Type\": \"String\",\r\n      \"AllowedValues\" : [ \"true\", \"false\" ],\r\n      \"ConstraintDescription\" : \"must be either true or false.\"\r\n    },\r\n\r\n    \"WebServerCapacity\": {\r\n      \"Default\": \"1\",\r\n      \"Description\" : \"The initial number of WebServer instances\",\r\n      \"Type\": \"Number\",\r\n      \"MinValue\": \"1\",\r\n      \"MaxValue\": \"5\",\r\n      \"ConstraintDescription\" : \"must be between 1 and 5 EC2 instances.\"\r\n    },\r\n\r\n    \"DBAllocatedStorage\" : {\r\n      \"Default\": \"5\",\r\n      \"Description\" : \"The size of the database (Gb)\",\r\n      \"Type\": \"Number\",\r\n      \"MinValue\": \"5\",\r\n      \"MaxValue\": \"1024\",\r\n      \"ConstraintDescription\" : \"must be between 5 and 1024Gb.\"\r\n    }\r\n  },\r\n\r\n  \"Mappings\" : {\r\n    \"AWSInstanceType2Arch\" : {\r\n      \"t1.micro\"    : { \"Arch\" : \"HVM64\"  },\r\n      \"t2.nano\"     : { \"Arch\" : \"HVM64\"  },\r\n      \"t2.micro\"    : { \"Arch\" : \"HVM64\"  },\r\n      \"t2.small\"    : { \"Arch\" : \"HVM64\"  },\r\n      \"t2.medium\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"t2.large\"    : { \"Arch\" : \"HVM64\"  },\r\n      \"m1.small\"    : { \"Arch\" : \"HVM64\"  },\r\n      \"m1.medium\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"m1.large\"    : { \"Arch\" : \"HVM64\"  },\r\n      \"m1.xlarge\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"m2.xlarge\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"m2.2xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"m2.4xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"m3.medium\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"m3.large\"    : { \"Arch\" : \"HVM64\"  },\r\n      \"m3.xlarge\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"m3.2xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"m4.large\"    : { \"Arch\" : \"HVM64\"  },\r\n      \"m4.xlarge\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"m4.2xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"m4.4xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"m4.10xlarge\" : { \"Arch\" : \"HVM64\"  },\r\n      \"c1.medium\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"c1.xlarge\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"c3.large\"    : { \"Arch\" : \"HVM64\"  },\r\n      \"c3.xlarge\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"c3.2xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"c3.4xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"c3.8xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"c4.large\"    : { \"Arch\" : \"HVM64\"  },\r\n      \"c4.xlarge\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"c4.2xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"c4.4xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"c4.8xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"g2.2xlarge\"  : { \"Arch\" : \"HVMG2\"  },\r\n      \"g2.8xlarge\"  : { \"Arch\" : \"HVMG2\"  },\r\n      \"r3.large\"    : { \"Arch\" : \"HVM64\"  },\r\n      \"r3.xlarge\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"r3.2xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"r3.4xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"r3.8xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"i2.xlarge\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"i2.2xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"i2.4xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"i2.8xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"d2.xlarge\"   : { \"Arch\" : \"HVM64\"  },\r\n      \"d2.2xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"d2.4xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"d2.8xlarge\"  : { \"Arch\" : \"HVM64\"  },\r\n      \"hi1.4xlarge\" : { \"Arch\" : \"HVM64\"  },\r\n      \"hs1.8xlarge\" : { \"Arch\" : \"HVM64\"  },\r\n      \"cr1.8xlarge\" : { \"Arch\" : \"HVM64\"  },\r\n      \"cc2.8xlarge\" : { \"Arch\" : \"HVM64\"  }\r\n    },\r\n\r\n    \"AWSInstanceType2NATArch\" : {\r\n      \"t1.micro\"    : { \"Arch\" : \"NATHVM64\"  },\r\n      \"t2.nano\"     : { \"Arch\" : \"NATHVM64\"  },\r\n      \"t2.micro\"    : { \"Arch\" : \"NATHVM64\"  },\r\n      \"t2.small\"    : { \"Arch\" : \"NATHVM64\"  },\r\n      \"t2.medium\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"t2.large\"    : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m1.small\"    : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m1.medium\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m1.large\"    : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m1.xlarge\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m2.xlarge\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m2.2xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m2.4xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m3.medium\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m3.large\"    : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m3.xlarge\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m3.2xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m4.large\"    : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m4.xlarge\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m4.2xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m4.4xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"m4.10xlarge\" : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c1.medium\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c1.xlarge\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c3.large\"    : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c3.xlarge\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c3.2xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c3.4xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c3.8xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c4.large\"    : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c4.xlarge\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c4.2xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c4.4xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"c4.8xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"g2.2xlarge\"  : { \"Arch\" : \"NATHVMG2\"  },\r\n      \"g2.8xlarge\"  : { \"Arch\" : \"NATHVMG2\"  },\r\n      \"r3.large\"    : { \"Arch\" : \"NATHVM64\"  },\r\n      \"r3.xlarge\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"r3.2xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"r3.4xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"r3.8xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"i2.xlarge\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"i2.2xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"i2.4xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"i2.8xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"d2.xlarge\"   : { \"Arch\" : \"NATHVM64\"  },\r\n      \"d2.2xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"d2.4xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"d2.8xlarge\"  : { \"Arch\" : \"NATHVM64\"  },\r\n      \"hi1.4xlarge\" : { \"Arch\" : \"NATHVM64\"  },\r\n      \"hs1.8xlarge\" : { \"Arch\" : \"NATHVM64\"  },\r\n      \"cr1.8xlarge\" : { \"Arch\" : \"NATHVM64\"  },\r\n      \"cc2.8xlarge\" : { \"Arch\" : \"NATHVM64\"  }\r\n    }\r\n,\r\n    \"AWSRegionArch2AMI\" : {\r\n      \"us-east-1\"        : {\"HVM64\" : \"ami-0080e4c5bc078760e\", \"HVMG2\" : \"ami-0aeb704d503081ea6\"},\r\n      \"us-west-2\"        : {\"HVM64\" : \"ami-01e24be29428c15b2\", \"HVMG2\" : \"ami-0fe84a5b4563d8f27\"},\r\n      \"us-west-1\"        : {\"HVM64\" : \"ami-0ec6517f6edbf8044\", \"HVMG2\" : \"ami-0a7fc72dc0e51aa77\"},\r\n      \"eu-west-1\"        : {\"HVM64\" : \"ami-08935252a36e25f85\", \"HVMG2\" : \"ami-0d5299b1c6112c3c7\"},\r\n      \"eu-west-2\"        : {\"HVM64\" : \"ami-01419b804382064e4\", \"HVMG2\" : \"NOT_SUPPORTED\"},\r\n      \"eu-west-3\"        : {\"HVM64\" : \"ami-0dd7e7ed60da8fb83\", \"HVMG2\" : \"NOT_SUPPORTED\"},\r\n      \"eu-central-1\"     : {\"HVM64\" : \"ami-0cfbf4f6db41068ac\", \"HVMG2\" : \"ami-0aa1822e3eb913a11\"},\r\n      \"eu-north-1\"       : {\"HVM64\" : \"ami-86fe70f8\", \"HVMG2\" : \"ami-32d55b4c\"},\r\n      \"ap-northeast-1\"   : {\"HVM64\" : \"ami-00a5245b4816c38e6\", \"HVMG2\" : \"ami-09d0e0e099ecabba2\"},\r\n      \"ap-northeast-2\"   : {\"HVM64\" : \"ami-00dc207f8ba6dc919\", \"HVMG2\" : \"NOT_SUPPORTED\"},\r\n      \"ap-northeast-3\"   : {\"HVM64\" : \"ami-0b65f69a5c11f3522\", \"HVMG2\" : \"NOT_SUPPORTED\"},\r\n      \"ap-southeast-1\"   : {\"HVM64\" : \"ami-05b3bcf7f311194b3\", \"HVMG2\" : \"ami-0e46ce0d6a87dc979\"},\r\n      \"ap-southeast-2\"   : {\"HVM64\" : \"ami-02fd0b06f06d93dfc\", \"HVMG2\" : \"ami-0c0ab057a101d8ff2\"},\r\n      \"ap-south-1\"       : {\"HVM64\" : \"ami-0ad42f4f66f6c1cc9\", \"HVMG2\" : \"ami-0244c1d42815af84a\"},\r\n      \"us-east-2\"        : {\"HVM64\" : \"ami-0cd3dfa4e37921605\", \"HVMG2\" : \"NOT_SUPPORTED\"},\r\n      \"ca-central-1\"     : {\"HVM64\" : \"ami-07423fb63ea0a0930\", \"HVMG2\" : \"NOT_SUPPORTED\"},\r\n      \"sa-east-1\"        : {\"HVM64\" : \"ami-05145e0b28ad8e0b2\", \"HVMG2\" : \"NOT_SUPPORTED\"},\r\n      \"cn-north-1\"       : {\"HVM64\" : \"ami-053617c9d818c1189\", \"HVMG2\" : \"NOT_SUPPORTED\"},\r\n      \"cn-northwest-1\"   : {\"HVM64\" : \"ami-0f7937761741dc640\", \"HVMG2\" : \"NOT_SUPPORTED\"}\r\n    }\r\n\r\n  },\r\n\r\n  \"Resources\" : {\r\n\r\n    \"ApplicationLoadBalancer\" : {\r\n      \"Type\" : \"AWS::ElasticLoadBalancingV2::LoadBalancer\",\r\n      \"Properties\" : {\r\n        \"Subnets\" : { \"Ref\" : \"Subnets\"}\r\n      }\r\n    },\r\n\r\n    \"ALBListener\" : {\r\n      \"Type\" : \"AWS::ElasticLoadBalancingV2::Listener\",\r\n      \"Properties\" : {\r\n        \"DefaultActions\" : [{\r\n          \"Type\" : \"forward\",\r\n          \"TargetGroupArn\" : { \"Ref\" : \"ALBTargetGroup\" }\r\n        }],\r\n        \"LoadBalancerArn\" : { \"Ref\" : \"ApplicationLoadBalancer\" },\r\n        \"Port\" : \"80\",\r\n        \"Protocol\" : \"HTTP\"\r\n      }\r\n    },\r\n\r\n    \"ALBTargetGroup\" : {\r\n      \"Type\" : \"AWS::ElasticLoadBalancingV2::TargetGroup\",\r\n      \"Properties\" : {\r\n        \"HealthCheckPath\" : \"/wordpress/wp-admin/install.php\",  \r\n        \"HealthCheckIntervalSeconds\" : 10,\r\n        \"HealthCheckTimeoutSeconds\" : 5,\r\n        \"HealthyThresholdCount\" : 2,\r\n        \"Port\" : 80,\r\n        \"Protocol\" : \"HTTP\",\r\n        \"UnhealthyThresholdCount\" : 5,\r\n        \"VpcId\" : {\"Ref\" : \"VpcId\"},       \r\n        \"TargetGroupAttributes\" :\r\n          [ { \"Key\" : \"stickiness.enabled\", \"Value\" : \"true\" },\r\n            { \"Key\" : \"stickiness.type\", \"Value\" : \"lb_cookie\" },\r\n            { \"Key\" : \"stickiness.lb_cookie.duration_seconds\", \"Value\" : \"30\" }\r\n        ]\r\n      }\r\n    },\r\n   \r\n    \"WebServerSecurityGroup\" : {\r\n      \"Type\" : \"AWS::EC2::SecurityGroup\",\r\n      \"Properties\" : {\r\n        \"GroupDescription\" : \"Enable HTTP access via port 80 locked down to the load balancer + SSH access\",\r\n        \"SecurityGroupIngress\" : [\r\n          {\"IpProtocol\" : \"tcp\", \"FromPort\" : \"80\", \"ToPort\" : \"80\", \"SourceSecurityGroupId\" : {\"Fn::Select\" : [0, {\"Fn::GetAtt\" : [\"ApplicationLoadBalancer\", \"SecurityGroups\"]}]}},\r\n          {\"IpProtocol\" : \"tcp\", \"FromPort\" : \"22\", \"ToPort\" : \"22\", \"CidrIp\" : { \"Ref\" : \"SSHLocation\"}}\r\n        ],\r\n        \"VpcId\" : { \"Ref\" : \"VpcId\" }\r\n      }\r\n    },\r\n\r\n    \"WebServerGroup\" : {\r\n      \"Type\" : \"AWS::AutoScaling::AutoScalingGroup\",\r\n      \"Properties\" : {\r\n        \"VPCZoneIdentifier\" : { \"Ref\" : \"Subnets\" },\r\n        \"LaunchConfigurationName\" : { \"Ref\" : \"LaunchConfig\" },\r\n        \"MinSize\" : \"1\",\r\n        \"MaxSize\" : \"5\",\r\n        \"DesiredCapacity\" : { \"Ref\" : \"WebServerCapacity\" },\r\n        \"TargetGroupARNs\" : [ { \"Ref\" : \"ALBTargetGroup\" } ]\r\n      },\r\n      \"CreationPolicy\" : {\r\n        \"ResourceSignal\" : {\r\n          \"Timeout\" : \"PT15M\"\r\n        }\r\n      },\r\n      \"UpdatePolicy\": {\r\n        \"AutoScalingRollingUpdate\": {\r\n          \"MinInstancesInService\": \"1\",\r\n          \"MaxBatchSize\": \"1\",\r\n          \"PauseTime\" : \"PT15M\",\r\n          \"WaitOnResourceSignals\": \"true\"\r\n        }\r\n      }\r\n    },\r\n\r\n    \"LaunchConfig\": {\r\n      \"Type\" : \"AWS::AutoScaling::LaunchConfiguration\",\r\n      \"Metadata\" : {\r\n        \"AWS::CloudFormation::Init\" : {\r\n          \"configSets\" : {\r\n            \"wordpress_install\" : [\"install_cfn\", \"install_wordpress\" ]\r\n          },\r\n          \"install_cfn\" : {\r\n            \"files\": {\r\n              \"/etc/cfn/cfn-hup.conf\": {\r\n                \"content\": { \"Fn::Join\": [ \"\", [\r\n                  \"[main]\\n\",\r\n                  \"stack=\", { \"Ref\": \"AWS::StackId\" }, \"\\n\",\r\n                  \"region=\", { \"Ref\": \"AWS::Region\" }, \"\\n\"\r\n                ]]},\r\n                \"mode\"  : \"000400\",\r\n                \"owner\" : \"root\",\r\n                \"group\" : \"root\"\r\n              },\r\n              \"/etc/cfn/hooks.d/cfn-auto-reloader.conf\": {\r\n                \"content\": { \"Fn::Join\": [ \"\", [\r\n                  \"[cfn-auto-reloader-hook]\\n\",\r\n                  \"triggers=post.update\\n\",\r\n                  \"path=Resources.LaunchConfig.Metadata.AWS::CloudFormation::Init\\n\",\r\n                  \"action=/opt/aws/bin/cfn-init -v \",\r\n                          \"         --stack \", { \"Ref\" : \"AWS::StackName\" },\r\n                          \"         --resource LaunchConfig \",\r\n                          \"         --configsets wordpress_install \",\r\n                          \"         --region \", { \"Ref\" : \"AWS::Region\" }, \"\\n\"\r\n                ]]},          \r\n                \"mode\"  : \"000400\",\r\n                \"owner\" : \"root\",\r\n                \"group\" : \"root\"\r\n              }\r\n            },\r\n            \"services\" : {\r\n              \"sysvinit\" : {\r\n                \"cfn-hup\" : { \"enabled\" : \"true\", \"ensureRunning\" : \"true\",\r\n                              \"files\" : [\"/etc/cfn/cfn-hup.conf\", \"/etc/cfn/hooks.d/cfn-auto-reloader.conf\"]}\r\n              }\r\n            }\r\n          },\r\n\r\n          \"install_wordpress\" : {\r\n            \"packages\" : {\r\n              \"yum\" : {\r\n                \"php\"       : [],\r\n                \"php-mysql\" : [],\r\n                \"mysql\"     : [],\r\n                \"httpd\"     : []\r\n              }\r\n            },\r\n            \"sources\" : {\r\n              \"/var/www/html\" : \"http://wordpress.org/latest.tar.gz\"\r\n            },\r\n            \"files\" : {\r\n              \"/tmp/create-wp-config\" : {\r\n                \"content\" : { \"Fn::Join\" : [ \"\", [\r\n                  \"#!/bin/bash\\n\",\r\n                  \"cp /var/www/html/wordpress/wp-config-sample.php /var/www/html/wordpress/wp-config.php\\n\",\r\n                  \"sed -i \\\"s/'database_name_here'/'\",{ \"Ref\" : \"DBName\" }, \"'/g\\\" wp-config.php\\n\",\r\n                  \"sed -i \\\"s/'username_here'/'\",{ \"Ref\" : \"DBUser\" }, \"'/g\\\" wp-config.php\\n\",\r\n                  \"sed -i \\\"s/'password_here'/'\",{ \"Ref\" : \"DBPassword\" }, \"'/g\\\" wp-config.php\\n\",\r\n                  \"sed -i \\\"s/'localhost'/'\",{ \"Fn::GetAtt\" : [ \"DBInstance\", \"Endpoint.Address\" ] }, \"'/g\\\" wp-config.php\\n\"\r\n                ]]},\r\n                \"mode\" : \"000500\",\r\n                \"owner\" : \"root\",\r\n                \"group\" : \"root\"\r\n              }\r\n            },\r\n            \"commands\" : {\r\n              \"01_configure_wordpress\" : {\r\n                \"command\" : \"/tmp/create-wp-config\",\r\n                \"cwd\" : \"/var/www/html/wordpress\"\r\n              }\r\n            },\r\n            \"services\" : {\r\n              \"sysvinit\" : {\r\n                \"httpd\" : { \"enabled\" : \"true\", \"ensureRunning\" : \"true\" }\r\n              }\r\n            }\r\n          }\r\n        }\r\n      },\r\n      \"Properties\": {\r\n        \"ImageId\" : { \"Fn::FindInMap\" : [ \"AWSRegionArch2AMI\", { \"Ref\" : \"AWS::Region\" },\r\n                          { \"Fn::FindInMap\" : [ \"AWSInstanceType2Arch\", { \"Ref\" : \"InstanceType\" }, \"Arch\" ] } ] },\r\n        \"InstanceType\"   : { \"Ref\" : \"InstanceType\" },\r\n        \"SecurityGroups\" : [ {\"Ref\" : \"WebServerSecurityGroup\"} ],\r\n        \"KeyName\"        : { \"Ref\" : \"KeyName\" },\r\n        \"UserData\" : { \"Fn::Base64\" : { \"Fn::Join\" : [\"\", [\r\n                       \"#!/bin/bash -xe\\n\",\r\n                       \"yum update -y aws-cfn-bootstrap\\n\",\r\n\r\n                       \"/opt/aws/bin/cfn-init -v \",\r\n                       \"         --stack \", { \"Ref\" : \"AWS::StackName\" },\r\n                       \"         --resource LaunchConfig \",\r\n                       \"         --configsets wordpress_install \",\r\n                       \"         --region \", { \"Ref\" : \"AWS::Region\" }, \"\\n\",\r\n\r\n                       \"/opt/aws/bin/cfn-signal -e $? \",\r\n                       \"         --stack \", { \"Ref\" : \"AWS::StackName\" },\r\n                       \"         --resource WebServerGroup \",\r\n                       \"         --region \", { \"Ref\" : \"AWS::Region\" }, \"\\n\"\r\n        ]]}}\r\n      }\r\n    },\r\n\r\n    \"DBEC2SecurityGroup\": {\r\n      \"Type\": \"AWS::EC2::SecurityGroup\",\r\n      \"Properties\" : {\r\n        \"GroupDescription\": \"Open database for access\",\r\n        \"SecurityGroupIngress\" : [{\r\n        \"IpProtocol\" : \"tcp\",\r\n        \"FromPort\" : \"3306\",\r\n        \"ToPort\" : \"3306\",\r\n        \"SourceSecurityGroupId\" : { \"Ref\" : \"WebServerSecurityGroup\" }\r\n        }],\r\n        \"VpcId\" : { \"Ref\" : \"VpcId\" }\r\n      }\r\n    },\r\n\r\n    \"DBInstance\" : {\r\n      \"Type\": \"AWS::RDS::DBInstance\",\r\n      \"Properties\": {\r\n        \"DBName\"            : { \"Ref\" : \"DBName\" },\r\n        \"Engine\"            : \"MySQL\",\r\n        \"MultiAZ\"           : { \"Ref\": \"MultiAZDatabase\" },\r\n        \"MasterUsername\"    : { \"Ref\" : \"DBUser\" },\r\n        \"MasterUserPassword\": { \"Ref\" : \"DBPassword\" },\r\n        \"DBInstanceClass\"   : { \"Ref\" : \"DBClass\" },\r\n        \"AllocatedStorage\"  : { \"Ref\" : \"DBAllocatedStorage\" },\r\n        \"VPCSecurityGroups\" : [{ \"Fn::GetAtt\": [ \"DBEC2SecurityGroup\", \"GroupId\" ]}]\r\n      }\r\n    }\r\n  },\r\n\r\n  \"Outputs\" : {\r\n    \"WebsiteURL\" : {\r\n      \"Value\" : { \"Fn::Join\" : [\"\", [\"http://\", { \"Fn::GetAtt\" : [ \"ApplicationLoadBalancer\", \"DNSName\" ]}, \"/wordpress\" ]]},\r\n      \"Description\" : \"WordPress Website\"\r\n    }\r\n  }\r\n}","isUsed":true,"isValid":false,"dataObject":{"AWSTemplateFormatVersion":"2010-09-09","Description":"AWS CloudFormation Sample Template WordPress_Multi_AZ: WordPress is web software you can use to create a beautiful website or blog. This template installs a highly-available, scalable WordPress deployment using a multi-az Amazon RDS database instance for storage. It demonstrates using the AWS CloudFormation bootstrap scripts to deploy WordPress. **WARNING** This template creates an Amazon EC2 instance, an Application Load Balancer and an Amazon RDS database instance. You will be billed for the AWS resources used if you create a stack from this template.","Parameters":{"VpcId":{"Type":"AWS::EC2::VPC::Id","Description":"VpcId of your existing Virtual Private Cloud (VPC)","ConstraintDescription":"must be the VPC Id of an existing Virtual Private Cloud."},"Subnets":{"Type":"List<AWS::EC2::Subnet::Id>","Description":"The list of SubnetIds in your Virtual Private Cloud (VPC)","ConstraintDescription":"must be a list of at least two existing subnets associated with at least two different availability zones. They should be residing in the selected Virtual Private Cloud."},"KeyName":{"Description":"Name of an existing EC2 KeyPair to enable SSH access to the instances","Type":"AWS::EC2::KeyPair::KeyName","ConstraintDescription":"must be the name of an existing EC2 KeyPair."},"InstanceType":{"Description":"WebServer EC2 instance type","Type":"String","Default":"t2.small","AllowedValues":["t1.micro","t2.nano","t2.micro","t2.small","t2.medium","t2.large","m1.small","m1.medium","m1.large","m1.xlarge","m2.xlarge","m2.2xlarge","m2.4xlarge","m3.medium","m3.large","m3.xlarge","m3.2xlarge","m4.large","m4.xlarge","m4.2xlarge","m4.4xlarge","m4.10xlarge","c1.medium","c1.xlarge","c3.large","c3.xlarge","c3.2xlarge","c3.4xlarge","c3.8xlarge","c4.large","c4.xlarge","c4.2xlarge","c4.4xlarge","c4.8xlarge","g2.2xlarge","g2.8xlarge","r3.large","r3.xlarge","r3.2xlarge","r3.4xlarge","r3.8xlarge","i2.xlarge","i2.2xlarge","i2.4xlarge","i2.8xlarge","d2.xlarge","d2.2xlarge","d2.4xlarge","d2.8xlarge","hi1.4xlarge","hs1.8xlarge","cr1.8xlarge","cc2.8xlarge","cg1.4xlarge"],"ConstraintDescription":"must be a valid EC2 instance type."},"SSHLocation":{"Description":"The IP address range that can be used to SSH to the EC2 instances","Type":"String","MinLength":"9","MaxLength":"18","Default":"0.0.0.0/0","AllowedPattern":"(\\d{1,3})\\.(\\d{1,3})\\.(\\d{1,3})\\.(\\d{1,3})/(\\d{1,2})","ConstraintDescription":"must be a valid IP CIDR range of the form x.x.x.x/x."},"DBClass":{"Description":"Database instance class","Type":"String","Default":"db.t2.small","AllowedValues":["db.t1.micro","db.m1.small","db.m1.medium","db.m1.large","db.m1.xlarge","db.m2.xlarge","db.m2.2xlarge","db.m2.4xlarge","db.m3.medium","db.m3.large","db.m3.xlarge","db.m3.2xlarge","db.m4.large","db.m4.xlarge","db.m4.2xlarge","db.m4.4xlarge","db.m4.10xlarge","db.r3.large","db.r3.xlarge","db.r3.2xlarge","db.r3.4xlarge","db.r3.8xlarge","db.m2.xlarge","db.m2.2xlarge","db.m2.4xlarge","db.cr1.8xlarge","db.t2.micro","db.t2.small","db.t2.medium","db.t2.large"],"ConstraintDescription":"must select a valid database instance type."},"DBName":{"Default":"wordpressdb","Description":"The WordPress database name","Type":"String","MinLength":"1","MaxLength":"64","AllowedPattern":"[a-zA-Z][a-zA-Z0-9]*","ConstraintDescription":"must begin with a letter and contain only alphanumeric characters."},"DBUser":{"NoEcho":"true","Description":"The WordPress database admin account username","Type":"String","MinLength":"1","MaxLength":"16","AllowedPattern":"[a-zA-Z][a-zA-Z0-9]*","ConstraintDescription":"must begin with a letter and contain only alphanumeric characters."},"DBPassword":{"NoEcho":"true","Description":"The WordPress database admin account password","Type":"String","MinLength":"8","MaxLength":"41","AllowedPattern":"[a-zA-Z0-9]*","ConstraintDescription":"must contain only alphanumeric characters."},"MultiAZDatabase":{"Default":"false","Description":"Create a Multi-AZ MySQL Amazon RDS database instance","Type":"String","AllowedValues":["true","false"],"ConstraintDescription":"must be either true or false."},"WebServerCapacity":{"Default":"1","Description":"The initial number of WebServer instances","Type":"Number","MinValue":"1","MaxValue":"5","ConstraintDescription":"must be between 1 and 5 EC2 instances."},"DBAllocatedStorage":{"Default":"5","Description":"The size of the database (Gb)","Type":"Number","MinValue":"5","MaxValue":"1024","ConstraintDescription":"must be between 5 and 1024Gb."}},"Mappings":{"AWSInstanceType2Arch":{"t1.micro":{"Arch":"HVM64"},"t2.nano":{"Arch":"HVM64"},"t2.micro":{"Arch":"HVM64"},"t2.small":{"Arch":"HVM64"},"t2.medium":{"Arch":"HVM64"},"t2.large":{"Arch":"HVM64"},"m1.small":{"Arch":"HVM64"},"m1.medium":{"Arch":"HVM64"},"m1.large":{"Arch":"HVM64"},"m1.xlarge":{"Arch":"HVM64"},"m2.xlarge":{"Arch":"HVM64"},"m2.2xlarge":{"Arch":"HVM64"},"m2.4xlarge":{"Arch":"HVM64"},"m3.medium":{"Arch":"HVM64"},"m3.large":{"Arch":"HVM64"},"m3.xlarge":{"Arch":"HVM64"},"m3.2xlarge":{"Arch":"HVM64"},"m4.large":{"Arch":"HVM64"},"m4.xlarge":{"Arch":"HVM64"},"m4.2xlarge":{"Arch":"HVM64"},"m4.4xlarge":{"Arch":"HVM64"},"m4.10xlarge":{"Arch":"HVM64"},"c1.medium":{"Arch":"HVM64"},"c1.xlarge":{"Arch":"HVM64"},"c3.large":{"Arch":"HVM64"},"c3.xlarge":{"Arch":"HVM64"},"c3.2xlarge":{"Arch":"HVM64"},"c3.4xlarge":{"Arch":"HVM64"},"c3.8xlarge":{"Arch":"HVM64"},"c4.large":{"Arch":"HVM64"},"c4.xlarge":{"Arch":"HVM64"},"c4.2xlarge":{"Arch":"HVM64"},"c4.4xlarge":{"Arch":"HVM64"},"c4.8xlarge":{"Arch":"HVM64"},"g2.2xlarge":{"Arch":"HVMG2"},"g2.8xlarge":{"Arch":"HVMG2"},"r3.large":{"Arch":"HVM64"},"r3.xlarge":{"Arch":"HVM64"},"r3.2xlarge":{"Arch":"HVM64"},"r3.4xlarge":{"Arch":"HVM64"},"r3.8xlarge":{"Arch":"HVM64"},"i2.xlarge":{"Arch":"HVM64"},"i2.2xlarge":{"Arch":"HVM64"},"i2.4xlarge":{"Arch":"HVM64"},"i2.8xlarge":{"Arch":"HVM64"},"d2.xlarge":{"Arch":"HVM64"},"d2.2xlarge":{"Arch":"HVM64"},"d2.4xlarge":{"Arch":"HVM64"},"d2.8xlarge":{"Arch":"HVM64"},"hi1.4xlarge":{"Arch":"HVM64"},"hs1.8xlarge":{"Arch":"HVM64"},"cr1.8xlarge":{"Arch":"HVM64"},"cc2.8xlarge":{"Arch":"HVM64"}},"AWSInstanceType2NATArch":{"t1.micro":{"Arch":"NATHVM64"},"t2.nano":{"Arch":"NATHVM64"},"t2.micro":{"Arch":"NATHVM64"},"t2.small":{"Arch":"NATHVM64"},"t2.medium":{"Arch":"NATHVM64"},"t2.large":{"Arch":"NATHVM64"},"m1.small":{"Arch":"NATHVM64"},"m1.medium":{"Arch":"NATHVM64"},"m1.large":{"Arch":"NATHVM64"},"m1.xlarge":{"Arch":"NATHVM64"},"m2.xlarge":{"Arch":"NATHVM64"},"m2.2xlarge":{"Arch":"NATHVM64"},"m2.4xlarge":{"Arch":"NATHVM64"},"m3.medium":{"Arch":"NATHVM64"},"m3.large":{"Arch":"NATHVM64"},"m3.xlarge":{"Arch":"NATHVM64"},"m3.2xlarge":{"Arch":"NATHVM64"},"m4.large":{"Arch":"NATHVM64"},"m4.xlarge":{"Arch":"NATHVM64"},"m4.2xlarge":{"Arch":"NATHVM64"},"m4.4xlarge":{"Arch":"NATHVM64"},"m4.10xlarge":{"Arch":"NATHVM64"},"c1.medium":{"Arch":"NATHVM64"},"c1.xlarge":{"Arch":"NATHVM64"},"c3.large":{"Arch":"NATHVM64"},"c3.xlarge":{"Arch":"NATHVM64"},"c3.2xlarge":{"Arch":"NATHVM64"},"c3.4xlarge":{"Arch":"NATHVM64"},"c3.8xlarge":{"Arch":"NATHVM64"},"c4.large":{"Arch":"NATHVM64"},"c4.xlarge":{"Arch":"NATHVM64"},"c4.2xlarge":{"Arch":"NATHVM64"},"c4.4xlarge":{"Arch":"NATHVM64"},"c4.8xlarge":{"Arch":"NATHVM64"},"g2.2xlarge":{"Arch":"NATHVMG2"},"g2.8xlarge":{"Arch":"NATHVMG2"},"r3.large":{"Arch":"NATHVM64"},"r3.xlarge":{"Arch":"NATHVM64"},"r3.2xlarge":{"Arch":"NATHVM64"},"r3.4xlarge":{"Arch":"NATHVM64"},"r3.8xlarge":{"Arch":"NATHVM64"},"i2.xlarge":{"Arch":"NATHVM64"},"i2.2xlarge":{"Arch":"NATHVM64"},"i2.4xlarge":{"Arch":"NATHVM64"},"i2.8xlarge":{"Arch":"NATHVM64"},"d2.xlarge":{"Arch":"NATHVM64"},"d2.2xlarge":{"Arch":"NATHVM64"},"d2.4xlarge":{"Arch":"NATHVM64"},"d2.8xlarge":{"Arch":"NATHVM64"},"hi1.4xlarge":{"Arch":"NATHVM64"},"hs1.8xlarge":{"Arch":"NATHVM64"},"cr1.8xlarge":{"Arch":"NATHVM64"},"cc2.8xlarge":{"Arch":"NATHVM64"}},"AWSRegionArch2AMI":{"us-east-1":{"HVM64":"ami-0080e4c5bc078760e","HVMG2":"ami-0aeb704d503081ea6"},"us-west-2":{"HVM64":"ami-01e24be29428c15b2","HVMG2":"ami-0fe84a5b4563d8f27"},"us-west-1":{"HVM64":"ami-0ec6517f6edbf8044","HVMG2":"ami-0a7fc72dc0e51aa77"},"eu-west-1":{"HVM64":"ami-08935252a36e25f85","HVMG2":"ami-0d5299b1c6112c3c7"},"eu-west-2":{"HVM64":"ami-01419b804382064e4","HVMG2":"NOT_SUPPORTED"},"eu-west-3":{"HVM64":"ami-0dd7e7ed60da8fb83","HVMG2":"NOT_SUPPORTED"},"eu-central-1":{"HVM64":"ami-0cfbf4f6db41068ac","HVMG2":"ami-0aa1822e3eb913a11"},"eu-north-1":{"HVM64":"ami-86fe70f8","HVMG2":"ami-32d55b4c"},"ap-northeast-1":{"HVM64":"ami-00a5245b4816c38e6","HVMG2":"ami-09d0e0e099ecabba2"},"ap-northeast-2":{"HVM64":"ami-00dc207f8ba6dc919","HVMG2":"NOT_SUPPORTED"},"ap-northeast-3":{"HVM64":"ami-0b65f69a5c11f3522","HVMG2":"NOT_SUPPORTED"},"ap-southeast-1":{"HVM64":"ami-05b3bcf7f311194b3","HVMG2":"ami-0e46ce0d6a87dc979"},"ap-southeast-2":{"HVM64":"ami-02fd0b06f06d93dfc","HVMG2":"ami-0c0ab057a101d8ff2"},"ap-south-1":{"HVM64":"ami-0ad42f4f66f6c1cc9","HVMG2":"ami-0244c1d42815af84a"},"us-east-2":{"HVM64":"ami-0cd3dfa4e37921605","HVMG2":"NOT_SUPPORTED"},"ca-central-1":{"HVM64":"ami-07423fb63ea0a0930","HVMG2":"NOT_SUPPORTED"},"sa-east-1":{"HVM64":"ami-05145e0b28ad8e0b2","HVMG2":"NOT_SUPPORTED"},"cn-north-1":{"HVM64":"ami-053617c9d818c1189","HVMG2":"NOT_SUPPORTED"},"cn-northwest-1":{"HVM64":"ami-0f7937761741dc640","HVMG2":"NOT_SUPPORTED"}}},"Resources":{"ApplicationLoadBalancer":{"Type":"AWS::ElasticLoadBalancingV2::LoadBalancer","Properties":{"Subnets":{"Ref":"Subnets"}}},"ALBListener":{"Type":"AWS::ElasticLoadBalancingV2::Listener","Properties":{"DefaultActions":[{"Type":"forward","TargetGroupArn":{"Ref":"ALBTargetGroup"}}],"LoadBalancerArn":{"Ref":"ApplicationLoadBalancer"},"Port":"80","Protocol":"HTTP"}},"ALBTargetGroup":{"Type":"AWS::ElasticLoadBalancingV2::TargetGroup","Properties":{"HealthCheckPath":"/wordpress/wp-admin/install.php","HealthCheckIntervalSeconds":10,"HealthCheckTimeoutSeconds":5,"HealthyThresholdCount":2,"Port":80,"Protocol":"HTTP","UnhealthyThresholdCount":5,"VpcId":{"Ref":"VpcId"},"TargetGroupAttributes":[{"Key":"stickiness.enabled","Value":"true"},{"Key":"stickiness.type","Value":"lb_cookie"},{"Key":"stickiness.lb_cookie.duration_seconds","Value":"30"}]}},"WebServerSecurityGroup":{"Type":"AWS::EC2::SecurityGroup","Properties":{"GroupDescription":"Enable HTTP access via port 80 locked down to the load balancer + SSH access","SecurityGroupIngress":[{"IpProtocol":"tcp","FromPort":"80","ToPort":"80","SourceSecurityGroupId":{"Fn::Select":[0,{"Fn::GetAtt":["ApplicationLoadBalancer","SecurityGroups"]}]}},{"IpProtocol":"tcp","FromPort":"22","ToPort":"22","CidrIp":{"Ref":"SSHLocation"}}],"VpcId":{"Ref":"VpcId"}}},"WebServerGroup":{"Type":"AWS::AutoScaling::AutoScalingGroup","Properties":{"VPCZoneIdentifier":{"Ref":"Subnets"},"LaunchConfigurationName":{"Ref":"LaunchConfig"},"MinSize":"1","MaxSize":"5","DesiredCapacity":{"Ref":"WebServerCapacity"},"TargetGroupARNs":[{"Ref":"ALBTargetGroup"}]},"CreationPolicy":{"ResourceSignal":{"Timeout":"PT15M"}},"UpdatePolicy":{"AutoScalingRollingUpdate":{"MinInstancesInService":"1","MaxBatchSize":"1","PauseTime":"PT15M","WaitOnResourceSignals":"true"}}},"LaunchConfig":{"Type":"AWS::AutoScaling::LaunchConfiguration","Metadata":{"AWS::CloudFormation::Init":{"configSets":{"wordpress_install":["install_cfn","install_wordpress"]},"install_cfn":{"files":{"/etc/cfn/cfn-hup.conf":{"content":{"Fn::Join":["",["[main]\n","stack=",{"Ref":"AWS::StackId"},"\n","region=",{"Ref":"AWS::Region"},"\n"]]},"mode":"000400","owner":"root","group":"root"},"/etc/cfn/hooks.d/cfn-auto-reloader.conf":{"content":{"Fn::Join":["",["[cfn-auto-reloader-hook]\n","triggers=post.update\n","path=Resources.LaunchConfig.Metadata.AWS::CloudFormation::Init\n","action=/opt/aws/bin/cfn-init -v ","         --stack ",{"Ref":"AWS::StackName"},"         --resource LaunchConfig ","         --configsets wordpress_install ","         --region ",{"Ref":"AWS::Region"},"\n"]]},"mode":"000400","owner":"root","group":"root"}},"services":{"sysvinit":{"cfn-hup":{"enabled":"true","ensureRunning":"true","files":["/etc/cfn/cfn-hup.conf","/etc/cfn/hooks.d/cfn-auto-reloader.conf"]}}}},"install_wordpress":{"packages":{"yum":{"php":[],"php-mysql":[],"mysql":[],"httpd":[]}},"sources":{"/var/www/html":"http://wordpress.org/latest.tar.gz"},"files":{"/tmp/create-wp-config":{"content":{"Fn::Join":["",["#!/bin/bash\n","cp /var/www/html/wordpress/wp-config-sample.php /var/www/html/wordpress/wp-config.php\n","sed -i \"s/'database_name_here'/'",{"Ref":"DBName"},"'/g\" wp-config.php\n","sed -i \"s/'username_here'/'",{"Ref":"DBUser"},"'/g\" wp-config.php\n","sed -i \"s/'password_here'/'",{"Ref":"DBPassword"},"'/g\" wp-config.php\n","sed -i \"s/'localhost'/'",{"Fn::GetAtt":["DBInstance","Endpoint.Address"]},"'/g\" wp-config.php\n"]]},"mode":"000500","owner":"root","group":"root"}},"commands":{"01_configure_wordpress":{"command":"/tmp/create-wp-config","cwd":"/var/www/html/wordpress"}},"services":{"sysvinit":{"httpd":{"enabled":"true","ensureRunning":"true"}}}}}},"Properties":{"ImageId":{"Fn::FindInMap":["AWSRegionArch2AMI",{"Ref":"AWS::Region"},{"Fn::FindInMap":["AWSInstanceType2Arch",{"Ref":"InstanceType"},"Arch"]}]},"InstanceType":{"Ref":"InstanceType"},"SecurityGroups":[{"Ref":"WebServerSecurityGroup"}],"KeyName":{"Ref":"KeyName"},"UserData":{"Fn::Base64":{"Fn::Join":["",["#!/bin/bash -xe\n","yum update -y aws-cfn-bootstrap\n","/opt/aws/bin/cfn-init -v ","         --stack ",{"Ref":"AWS::StackName"},"         --resource LaunchConfig ","         --configsets wordpress_install ","         --region ",{"Ref":"AWS::Region"},"\n","/opt/aws/bin/cfn-signal -e $? ","         --stack ",{"Ref":"AWS::StackName"},"         --resource WebServerGroup ","         --region ",{"Ref":"AWS::Region"},"\n"]]}}}},"DBEC2SecurityGroup":{"Type":"AWS::EC2::SecurityGroup","Properties":{"GroupDescription":"Open database for access","SecurityGroupIngress":[{"IpProtocol":"tcp","FromPort":"3306","ToPort":"3306","SourceSecurityGroupId":{"Ref":"WebServerSecurityGroup"}}],"VpcId":{"Ref":"VpcId"}}},"DBInstance":{"Type":"AWS::RDS::DBInstance","Properties":{"DBName":{"Ref":"DBName"},"Engine":"MySQL","MultiAZ":{"Ref":"MultiAZDatabase"},"MasterUsername":{"Ref":"DBUser"},"MasterUserPassword":{"Ref":"DBPassword"},"DBInstanceClass":{"Ref":"DBClass"},"AllocatedStorage":{"Ref":"DBAllocatedStorage"},"VPCSecurityGroups":[{"Fn::GetAtt":["DBEC2SecurityGroup","GroupId"]}]}}},"Outputs":{"WebsiteURL":{"Value":{"Fn::Join":["",["http://",{"Fn::GetAtt":["ApplicationLoadBalancer","DNSName"]},"/wordpress"]]},"Description":"WordPress Website"}}},"codeErrors":[{"resource":"https://reindeer.tech/cdd-schema/default.json","owner":"json","severity":4,"message":"Missing property \"components\".","startLineNumber":1,"startColumn":1,"endLineNumber":1,"endColumn":2},{"resource":"https://reindeer.tech/cdd-schema/default.json","owner":"json","severity":4,"message":"Property AWSTemplateFormatVersion is not allowed.","startLineNumber":2,"startColumn":3,"endLineNumber":2,"endColumn":29},{"resource":"https://reindeer.tech/cdd-schema/default.json","owner":"json","severity":4,"message":"Property Description is not allowed.","startLineNumber":3,"startColumn":3,"endLineNumber":3,"endColumn":16},{"resource":"https://reindeer.tech/cdd-schema/default.json","owner":"json","severity":4,"message":"Property Parameters is not allowed.","startLineNumber":4,"startColumn":3,"endLineNumber":4,"endColumn":15},{"resource":"https://reindeer.tech/cdd-schema/default.json","owner":"json","severity":4,"message":"Property Mappings is not allowed.","startLineNumber":51,"startColumn":3,"endLineNumber":51,"endColumn":13},{"resource":"https://reindeer.tech/cdd-schema/default.json","owner":"json","severity":4,"message":"Property Resources is not allowed.","startLineNumber":210,"startColumn":3,"endLineNumber":210,"endColumn":14},{"resource":"https://reindeer.tech/cdd-schema/default.json","owner":"json","severity":4,"message":"Property Outputs is not allowed.","startLineNumber":450,"startColumn":3,"endLineNumber":450,"endColumn":12}]},{"id":"gcpTemplate.yaml","isRoot":false,"fmt":"yaml","lang":"gdm","data":"# Copyright 2016 Google Inc. All rights reserved.\r\n#\r\n# Licensed under the Apache License, Version 2.0 (the \"License\");\r\n# you may not use this file except in compliance with the License.\r\n# You may obtain a copy of the License at\r\n#\r\n#     http://www.apache.org/licenses/LICENSE-2.0\r\n#\r\n# Unless required by applicable law or agreed to in writing, software\r\n# distributed under the License is distributed on an \"AS IS\" BASIS,\r\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n# See the License for the specific language governing permissions and\r\n# limitations under the License.\r\n\r\n\r\n# Put all your resources under `resources:`. For each resource, you need:\r\n# - The type of resource. In this example, the type is a Compute VM instance.\r\n# - An internal name for the resource.\r\n# - The properties for the resource. In this example, for VM instances, you add\r\n#   the machine type, a boot disk, network information, and so on.\r\n#\r\n# For a list of supported resources,\r\n# see https://cloud.google.com/deployment-manager/docs/configuration/supported-resource-types.\r\nresources:\r\n- type: compute.v1.instance\r\n  name: quickstart-deployment-vm\r\n  properties:\r\n    # The properties of the resource depend on the type of resource. For a list\r\n    # of properties, see the API reference for the resource.\r\n    zone: us-central1-f\r\n    # Replace [MY_PROJECT] with your project ID\r\n    machineType: https://www.googleapis.com/compute/v1/projects/[MY_PROJECT]/zones/us-central1-f/machineTypes/f1-micro\r\n    disks:\r\n    - deviceName: boot\r\n      type: PERSISTENT\r\n      boot: true\r\n      autoDelete: true\r\n      initializeParams:\r\n        # See a full list of image families at https://cloud.google.com/compute/docs/images#os-compute-support\r\n        # The format of the sourceImage URL is: https://www.googleapis.com/compute/v1/projects/[IMAGE_PROJECT]/global/images/family/[FAMILY_NAME]\r\n        sourceImage: https://www.googleapis.com/compute/v1/projects/debian-cloud/global/images/family/debian-9\r\n    # Replace [MY_PROJECT] with your project ID\r\n    networkInterfaces:\r\n    - network: https://www.googleapis.com/compute/v1/projects/[MY_PROJECT]/global/networks/default\r\n      # Access Config required to give the instance a public IP address\r\n      accessConfigs:\r\n      - name: External NAT\r\n        type: ONE_TO_ONE_NAT","isUsed":true,"isValid":false,"dataObject":{"resources":[{"type":"compute.v1.instance","name":"quickstart-deployment-vm","properties":{"zone":"us-central1-f","machineType":"https://www.googleapis.com/compute/v1/projects/[MY_PROJECT]/zones/us-central1-f/machineTypes/f1-micro","disks":[{"deviceName":"boot","type":"PERSISTENT","boot":true,"autoDelete":true,"initializeParams":{"sourceImage":"https://www.googleapis.com/compute/v1/projects/debian-cloud/global/images/family/debian-9"}}],"networkInterfaces":[{"network":"https://www.googleapis.com/compute/v1/projects/[MY_PROJECT]/global/networks/default","accessConfigs":[{"name":"External NAT","type":"ONE_TO_ONE_NAT"}]}]}}]},"codeErrors":[{"message":"HOME","startColumn":0,"startLineNumber":0,"endColumn":0,"endLineNumber":0}]}]
  })
  
  export const getters = {
      listRoots (state) {
          return state.list.filter((v) => v.isRoot === true && v.isUsed === true);
      },
      listRefs (state) {
          return state.list.filter((v) => v.isRoot === false && v.isUsed === true);
      },
      listAll (state) {
          return state.list;
      },
      listCDD (state) {
          return state.list.filter((v) => v.lang === "cdd" ||  v.lang === "cddSnippet");
      },
      listUnused (state) {
          return state.list.filter((v) => v.isUsed === false);
      },
      listItem: (state) => (id) => {
          return state.list.filter((v) => v.id === id);
      },
      typeItem: (state) => (type) => {
          return [
          {"lang":"cdd","fmt":"unknown","avatar":"icon iconReindeer icon-reindeer","title":"Cloud Design","support":"full","icon":"sentiment_very_satisfied","tips":"fmtTypeUnknown"},
          {"lang":"cddSnippet","fmt":"unknown","avatar":"notes","title":"Cloud Design (Snippet)","support":"full","icon":"sentiment_very_satisfied","tips":"fmtTypeUnknown"},
          {"lang":"acf","fmt":"unknown","avatar":"icon iconReindeer icon-aws","title":"AWS CloudFormation","support":"normal","icon":"sentiment_satisfied","tips":"fmtTypeUnknown"},
          {"lang":"arm","fmt":"unknown","avatar":"icon iconReindeer icon-azure","title":"Azure Resource Manager","support":"thin","icon":"sentiment_dissatisfied","tips":"fmtTypeUnknown"},
          {"lang":"gdm","fmt":"unknown","avatar":"icon iconReindeer icon-gcp","title":"Google Cloud Deployment Manager","support":"thin","icon":"sentiment_dissatisfied","tips":"fmtTypeUnknown"},
          {"lang":"aro","fmt":"unknown","avatar":"icon iconReindeer icon-general","title":"Alibaba Cloud Resource Orchestration","support":"thin","icon":"sentiment_dissatisfied","tips":"fmtTypeUnknown"},
          {"lang":"tfm","fmt":"unknown","avatar":"icon iconReindeer icon-terafform","title":"Terraform","support":"thin","icon":"sentiment_dissatisfied","tips":"fmtTypeUnknown"},
          {"lang":"slf","fmt":"unknown","avatar":"icon iconReindeer icon-general","title":"ServerlessFramework","support":"thin","icon":"sentiment_dissatisfied","tips":"fmtTypeUnknown"},
          {"lang":"oth","fmt":"unknown","avatar":"icon iconReindeer icon-general","title":"Others","support":"no","icon":"sentiment_very_dissatisfied","tips":"fmtTypeUnknown"},
  
          {"lang":"cdd","fmt":"json","avatar":"icon iconReindeer icon-reindeer","title":"Cloud Design","support":"full","icon":"sentiment_very_satisfied","tips":"fmtTypeFullSupportedJSON"},
          {"lang":"cddSnippet","fmt":"json","avatar":"notes","title":"Cloud Design (Snippet)","support":"full","icon":"sentiment_very_satisfied","tips":"fmtTypeFullSupportedJSON"},
          {"lang":"acf","fmt":"json","avatar":"icon iconReindeer icon-aws","title":"AWS CloudFormation","support":"normal","icon":"sentiment_satisfied","tips":"fmtTypeSupportedJSON"},
          {"lang":"arm","fmt":"json","avatar":"icon iconReindeer icon-azure","title":"Azure Resource Manager","support":"thin","icon":"sentiment_dissatisfied","tips":"fmtTypeSupportedJSON"},
          {"lang":"gdm","fmt":"json","avatar":"icon iconReindeer icon-gcp","title":"Google Cloud Deployment Manager","support":"thin","icon":"sentiment_dissatisfied","tips":"fmtTypeSupportedJSON"},
          {"lang":"aro","fmt":"json","avatar":"icon iconReindeer icon-general","title":"Alibaba Cloud Resource Orchestration","support":"thin","icon":"sentiment_dissatisfied","tips":"fmtTypeSupportedJSON"},
          {"lang":"tfm","fmt":"json","avatar":"icon iconReindeer icon-terafform","title":"Terraform","support":"thin","icon":"sentiment_dissatisfied","tips":"fmtTypeSupportedJSON"},
          {"lang":"slf","fmt":"json","avatar":"icon iconReindeer icon-general","title":"ServerlessFramework","support":"thin","icon":"sentiment_dissatisfied","tips":"fmtTypeSupportedJSON"},
          {"lang":"oth","fmt":"json","avatar":"icon iconReindeer icon-general","title":"Others","support":"no","icon":"sentiment_very_dissatisfied","tips":"fmtTypeUnknown"},
  
          {"lang":"cdd","fmt":"yaml","avatar":"icon iconReindeer icon-reindeer","title":"Cloud Design","support":"thin","icon":"sentiment_very_dissatisfied","tips":""},
          {"lang":"cddSnippet","fmt":"yaml","avatar":"icon iconReindeer icon-reindeer","title":"Cloud Design (Snippet)","support":"thin","icon":"sentiment_very_dissatisfied","tips":"fmtTypeFullSupportedYAML"},
          {"lang":"acf","fmt":"yaml","avatar":"icon iconReindeer icon-aws","title":"AWS CloudFormation","support":"thin","icon":"sentiment_very_dissatisfied","tips":"fmtTypeFullSupportedYAML"},
          {"lang":"arm","fmt":"yaml","avatar":"icon iconReindeer icon-general","title":"Azure Resource Manager","support":"thin","icon":"sentiment_very_dissatisfied","tips":"fmtTypeSupportedYAML"},
          {"lang":"gdm","fmt":"yaml","avatar":"icon iconReindeer icon-gcp","title":"Google Cloud Deployment Manager","support":"thin","icon":"sentiment_very_dissatisfied","tips":"fmtTypeSupportedYAML"},
          {"lang":"aro","fmt":"yaml","avatar":"icon iconReindeer icon-general","title":"Alibaba Cloud Resource Orchestration","support":"thin","icon":"sentiment_very_dissatisfied","tips":"fmtTypeSupportedYAML"},
          {"lang":"tfm","fmt":"yaml","avatar":"icon iconReindeer icon-terraform","title":"Terraform","support":"thin","icon":"sentiment_very_dissatisfied","tips":"fmtTypeSupportedYAML"},
          {"lang":"slf","fmt":"yaml","avatar":"icon iconReindeer icon-general","title":"ServerlessFramework","support":"thin","icon":"sentiment_very_dissatisfied","tips":"fmtTypeSupportedYAML"},
          {"lang":"oth","fmt":"yaml","avatar":"icon iconReindeer icon-general","title":"Others","support":"no","icon":"sentiment_very_dissatisfied","tips":"fmtTypeUnknown"}
  
          ].filter((v) => v.lang === type["lang"] && v.fmt === type["fmt"]);
      },
      typeMasterLangs (state) {
          return ["cdd","cddSnippet","acf","gdm","arm","aro","tfm","slf","oth"];
      },
      typeMasterFmts (state) {
          return ["json","yaml","unknown"];
      }
  }
  
  export const mutations = {
      add (state, obj){
          state.list.push(obj)
      },
      remove (state, id) {
          state.list.splice(state.list.findIndex((v) => v.id === id),1)
      },
      update(state, obj){
          state.list.splice(state.list.findIndex((v) => v.id === obj.id), 1, obj)
      }
  }
    
  export const actions = {
      async add(context, obj){
          context.commit('add', obj)
      },
      async remove(context, id){
          context.commit('remove', id)
      },
      async update(context, obj){
          context.commit('update', obj)
      }
  }