CLI 実行フロー ⚫ Transform Custom CLI を起動後、下記のようなプロンプトを入力。 (プロンプトはサンプル ) ⚫ CDKへの変換ケース ⚫ Terraform への変換ケース ⚫ 現在は、 IaC をサポートしている AWS 提供Transformation リストが無いため、下記のような質問をしてくる。 ※AI エージェントからの問いかけの為、毎回同じ質問とは限らない。 (Transform CLI のバージョンによる違いもありそう。 ) >Please transform from CloudFormation Code to AWS CDK for Python. To create a solid transformation definition, it would be useful to know : 1. What types of CloudFormation resources are most commonly used in your templates (e.g., EC2, S3, Lambda, VPC, IAM, RDS)? 2. Are your CloudFormation templates written in JSON, YAML, or a mix of both? And do they make heavy use of intrinsic functions (like Fn::If, Fn::Sub, Conditions, Mappings)? If you have any migration guides, documentation, or example CloudFormation templates and their desired CDK equivalents, feel free to share file paths and I can use those to build a more precise transformation definition. You can always add these later if you don't have them handy right now. >Please transform from CloudFormation Code to Terraform Code.
CLI 実行フロー ⚫ 前頁のAI エージェントからの質問に、下記のように回答。 (回答はサンプル ) ⚫ AI エージェントがユーザーのホームディレクトリ内にある「 .aws /atx /custom 」ディレクトリ配下に作業日時を含む ディレクトリを作成後、 transformation_definition.md( 今回の要件整理)を作成。ユーザーに確認を求めてくる。 ⚫ 元のCloudFormation コードは実行の順序性があるため、その点を忘れずに AI エージェントに伝える。 ⚫ AI エージェントが summaries.md( 作業概要)、 plan.json (変換作業計画)を作成する。その際、検証用に必要な コマンドは何が良いかを聞いてくるので、今回は以下のように回答。 (ユーザー自身で好きなものを指示する。 ) ⚫ CDKへの変換検証: cdk synth コマンド ⚫ Terraform への変換検証: terraform init コマンド、及び、 terraform validate コマンド >These AWS resources(EC2,VPC,RDS,VPC Lattice,SSM ) are most commomly used in my templates. And my CloudFormation templates is written in YAML and use of intrinsic functions. >My CloudFormation Codes are run on the following sequence (CreateRG -NetWork.yaml -> CreateCS - ServicceNetWork.yaml -> CreateCS -PrivateEC2.yaml -> Create_SSMEndpoint.yaml). These codes are located in /home/testuser/transform -cdk/aws -service -network -foundation .