Google Cloud CLI で既存のリソースを Terraform ファイルにエクスポートするのを試す

これ。まだベータ
Terraform と gcloud CLI を使用した完璧な Google Cloud インフラストラクチャの構築 | Google Cloud Blog

多くの Google Cloud リソースに対応していますが、すべてが対象ではありません。my-project プロジェクト内のエクスポート可能なすべてのリソースタイプを json 形式で一覧表示するには、次のコマンドを実行します。
まだ全てが対象ではないらしい


GCPにおけるフォルダってなんや...?(GCPルーキー)
フォルダ内のすべてのリソースをローカル ディレクトリに Terraform 形式でエクスポートするには、次のコマンドを実行します。
https://cloud.google.com/blog/ja/products/application-development/google-cloud-cli-declarative-export-preview

プロジェクトの上位の概念っぽい。プロジェクト単位でTerraform出力できるかな
フォルダを使用すると、階層内の組織ノードにあるプロジェクトをグループ化できます。
https://cloud.google.com/resource-manager/docs/creating-managing-folders?hl=ja

早速試す
betaコマンドのインストールが必要だった。
❯ gcloud beta resource-config -h
You do not currently have this command group installed. Using it
requires the installation of components: [beta]
Your current Google Cloud CLI version is: 374.0.0
Installing components from version: 374.0.0
┌─────────────────────────────────────────────┐
│ These components will be installed. │
├──────────────────────┬────────────┬─────────┤
│ Name │ Version │ Size │
├──────────────────────┼────────────┼─────────┤
│ gcloud Beta Commands │ 2022.02.22 │ < 1 MiB │
└──────────────────────┴────────────┴─────────┘
For the latest full release notes, please visit:
https://cloud.google.com/sdk/release_notes
Do you want to continue (Y/n)? y
╔════════════════════════════════════════════════════════════╗
╠═ Creating update staging area ═╣
╠════════════════════════════════════════════════════════════╣
╠═ Installing: gcloud Beta Commands ═╣
╠════════════════════════════════════════════════════════════╣
╠═ Creating backup and activating new installation ═╣
╚════════════════════════════════════════════════════════════╝
Performing post processing steps...done.
Update done!
その後元のコマンドを実行してくれた
Restarting command:
$ gcloud beta resource-config -h
Usage: gcloud beta resource-config [optional flags] <group | command>
group may be terraform
command may be bulk-export | list-resource-types
For detailed information on this command and its flags, run:
gcloud beta resource-config --help

オプション見る限りプロジェクト単位で出せそうな気配ある
❯ gcloud beta resource-config bulk-export -h
Usage: gcloud beta resource-config bulk-export [optional flags]
optional flags may be --folder | --help | --on-error | --organization |
--path | --project | --resource-format |
--resource-types | --resource-types-file |
--storage-path
For detailed information on this command and its flags, run:
gcloud beta resource-config bulk-export --help

ドキュメントに載ってる例
$ gcloud beta resource-config bulk-export --folder=12345 \
--resource-format=terraform --path=/path/to/dir/

--folder
はGCPにおけるフォルダ。--organization
か--project
を選べるっぽい。
At most one of these can be specified:
--folder=FOLDER
Folder ID
--organization=ORGANIZATION
Organization ID
--project=PROJECT
Project ID
--resource-format
はエクスポートするフォーマット。Terraformだけかと思いきやKubernetes Resource Model (krm) も選べるらしい。あれってkrmって言うのか。
--resource-format=RESOURCE_FORMAT
Format of the configuration to export. Available configuration formats
are Kubernetes Resource Model (krm) or Terraform HCL (terraform).
Command defaults to "krm". RESOURCE_FORMAT must be one of: krm,
terraform.
どうやらGCPはkrmでリソースを管理できるらしい。
宣言します: Configuration as Data を使用したインフラストラクチャの自動化 | Google Cloud Blog

やってみる
❯ gcloud beta resource-config bulk-export \
--project hoge \
--resource-format=terraform \
--path=./gcp
Pausing command execution:
This command requires the `config-connector` binary to be installed to export GCP
resource configurations. Would you like to install the`config-connector` binary to
continue command execution? (Y/n)?
config-connector
のインストールが求められた。

WARNING: The ARM versions of the following components are not available yet, using x86_64 versions instead: [config-connector].
Your current Google Cloud CLI version is: 374.0.0
Installing components from version: 374.0.0
┌───────────────────────────────────────────────────────────────────────────┐
│ These components will be installed. │
├──────────────────────────────┬─────────────────────┬──────────────────────┤
│ Name │ Version │ Size │
├──────────────────────────────┼─────────────────────┼──────────────────────┤
│ config-connector │ 1.74.0 │ 49.8 MiB │
└──────────────────────────────┴─────────────────────┴──────────────────────┘
For the latest full release notes, please visit:
https://cloud.google.com/sdk/release_notes
Do you want to continue (Y/n)? Y
╔════════════════════════════════════════════════════════════╗
╠═ Creating update staging area ═╣
╠════════════════════════════════════════════════════════════╣
╠═ Installing: config-connector ═╣
╠════════════════════════════════════════════════════════════╣
╠═ Installing: config-connector ═╣
╠════════════════════════════════════════════════════════════╣
╠═ Creating backup and activating new installation ═╣
╚════════════════════════════════════════════════════════════╝
Performing post processing steps...done.
Update done!
ARM向けはまだ無いらしい。(M1 MacBook Pro使用)

うーん、cloudasset.googleapis.com
がプロジェクトで許可されていないので許可してやり直しますか?って言われた。
API [cloudasset.googleapis.com] is required to continue, but is not enabled on
project [hoge]. Would you like to enable and retry (this will take a
few minutes)? (y/N)?
そりゃそうだと思いつつ、実際使ってるプロジェクトなのでちょっと一旦No。
ERROR: (gcloud.beta.resource-config.bulk-export) Aborted by user: API [cloudasset.googleapis.com] must be enabled on project [hoge] to continue.
Nを入力したらエラーで落ちた。

にしてもgcloudコマンド、俺がcloudasset.googleapis.com
を有効にできることをわかってて有効化するかを聞いてきたんだな。よくできてる

ちょっとどうでもいいプロジェクト作って適当なインスタンス立ててやってみる

久々に個人のGCP開くと古のプロジェクトが並んでる。
もう使ってないプロジェクトは課金されないようにインスタンス置いてなかったりするけどIAMユーザとかはいるかも?これらで試してみる

もっかいチャレンジ
❯ gcloud beta resource-config bulk-export \
--project mango-harvester \
--resource-format=terraform \
--path=./gcp
API [cloudasset.googleapis.com] is required to continue, but is not enabled on
project [mango-harvester]. Would you like to enable and retry (this will take a few
minutes)? (y/N)? y
cloudasset.googleapis.com
の有効化について聞かれる。y
Enabling service [cloudasset.googleapis.com] on project [mango-harvester]...
Operation "operations/acat.p2-xxxxxxxxx-xxxxxxxx-xxxxx" finished successfully.
Path ./gcp does not exists. Do you want to create it?
Do you want to continue (Y/n)? y
エクスポート先に指定した./gcp
が無いから作るか聞かれる。y
Exporting resource configurations to [./gcp]...⠧
作成中。まあまあかかるっぽい

終わった!
Exporting resource configurations to [./gcp]...done.
Exported 29 resource configuration(s) to [./gcp].
ほぼ空っぽのプロジェクトで2分強。大規模なプロジェクトやフォルダだとすごい時間かかりそう

長らく放置したほぼ空っぽだと思われたプロジェクトから生成した.tf
ファイルたち。
(<PROJECT_NUMBER>
には mango-harvester プロジェクトのプロジェクトナンバーが入ってた)
❯ tree ./gcp
./gcp
├── <PROJECT_NUMBER>
│ ├── <PROJECT_NUMBER>
│ │ └── Project
│ │ └── LoggingLogSink
│ │ ├── a-default.tf
│ │ └── a-required.tf
│ └── Service
│ ├── bigquery-googleapis-com.tf
│ ├── bigquerystorage-googleapis-com.tf
│ ├── cloudapis-googleapis-com.tf
│ ├── clouddebugger-googleapis-com.tf
│ ├── cloudfunctions-googleapis-com.tf
│ ├── cloudtrace-googleapis-com.tf
│ ├── compute-googleapis-com.tf
│ ├── container-googleapis-com.tf
│ ├── containerregistry-googleapis-com.tf
│ ├── datastore-googleapis-com.tf
│ ├── iam-googleapis-com.tf
│ ├── iamcredentials-googleapis-com.tf
│ ├── logging-googleapis-com.tf
│ ├── monitoring-googleapis-com.tf
│ ├── oslogin-googleapis-com.tf
│ ├── pubsub-googleapis-com.tf
│ ├── servicemanagement-googleapis-com.tf
│ ├── serviceusage-googleapis-com.tf
│ ├── sql-component-googleapis-com.tf
│ ├── storage-api-googleapis-com.tf
│ └── storage-component-googleapis-com.tf
└── projects
└── mango-harvester
├── ComputeFirewall
│ ├── default-allow-icmp.tf
│ ├── default-allow-internal.tf
│ ├── default-allow-rdp.tf
│ └── default-allow-ssh.tf
└── IAMServiceAccount
├── <PROJECT_NUMBER>-compute.tf
└── mango-harvester.tf
9 directories, 29 files

GCPの知見少ないから各リソースが何を表してるのかすぐにはわからない
<PROJECT_NUMBER>
ディレクトリとprojects.mango-harvester
ディレクトリはなぜ別れているのだろうか。
<PROJECT_NUMBER>. Service
下はgoogle_project_service
と言うリソースが並んでいる。APIの許可回りかもしれない。
resource "google_project_service" "containerregistry_googleapis_com" {
project = "<PROJECT_NUMBER>"
service = "containerregistry.googleapis.com"
}
# terraform import google_project_service.containerregistry_googleapis_com <PROJECT_NUMBER>/containerregistry.googleapis.com
ていうかコメントでインポート方法載ってる。至れり尽くせりだ

どうやらバケット生成してそこを一時ファイル置き場としてるみたいだ

フォルダ構造がよくわからん。ベストプラクティスがあるのかな?
あとproject numberなんかはvariableにしてほしい

main.tfの出力は次のコマンド。
$ gcloud alpha resource-config terraform init-provider

❯ gcloud alpha resource-config terraform init-provider
You do not currently have this command group installed. Using it
requires the installation of components: [alpha]
Your current Google Cloud CLI version is: 374.0.0
Installing components from version: 374.0.0
┌──────────────────────────────────────────────┐
│ These components will be installed. │
├───────────────────────┬────────────┬─────────┤
│ Name │ Version │ Size │
├───────────────────────┼────────────┼─────────┤
│ gcloud Alpha Commands │ 2022.02.22 │ < 1 MiB │
└───────────────────────┴────────────┴─────────┘
For the latest full release notes, please visit:
https://cloud.google.com/sdk/release_notes
Do you want to continue (Y/n)? y
こっちは alpha コマンドのインストールが必要。y
╔════════════════════════════════════════════════════════════╗
╠═ Creating update staging area ═╣
╠════════════════════════════════════════════════════════════╣
╠═ Installing: gcloud Alpha Commands ═╣
╠════════════════════════════════════════════════════════════╣
╠═ Creating backup and activating new installation ═╣
╚════════════════════════════════════════════════════════════╝
Performing post processing steps...done.
Update done!
インストール後コマンドが実行される
Restarting command:
$ gcloud alpha resource-config terraform init-provider
Creating Terraform init module...done.
Created Terraform module file ./gcp/main.tf.

main.tfが生まれた。
provider "google" {
project = "mango-harvester"
region = "None"
zone = "None"
}
これだけ。プロジェクト、リージョン、ゾーンはデフォルト値が使われた。

インポートするスクリプトも生成できる。
$ gcloud beta resource-config terraform generate-import \
/path/to/dir/
--output-script-file=import.sh --output-module-file=modules.tf

/path/to/dir/
の部分がさっき生成したフォルダになる。再帰的に見てくれるってことなのかな。
--output-script-file
はスクリプトのファイル名。
--output-module-file
はモジュールのファイル名っぽいけど、モジュール化してくれるってことなのか?よくわからんから試そう

なんか間違ってそう。
❯ gcloud beta resource-config terraform generate-import \
./gcp \
--output-script-file=import.sh \
--output-module-file=modules.tf
ERROR: gcloud crashed (ValueError): Invalid export Path {}. Path should point to an export Terraform(.tf) file or directotry of Terraform files.
Please see `gcloud alpha resource-config bulk-export` for more details.
If you would like to report this issue, please run the following command:
gcloud feedback
To check gcloud for common problems, please run the following command:
gcloud info --run-diagnostics

カレントディレクトリ間違ってたわ。
./gcp
に移動して実行。
❯ gcloud beta resource-config terraform generate-import \
. \
--output-script-file=import.sh \
--output-module-file=modules.tf
WARNING: Error generating imports for the following resource files: ./main.tf
Generating import script....done.
Successfully generated import.sh with imports for 23 resources.
Generating terraform modules....done.
Successfully generated modules.tf with 3 modules.
main.tf
はエラーになったがそれ以外は読み込まれた。

module.tf
。provider "google"
あるな...main.tf要らなくなった。
module化するってわけじゃなくて、既にフォルダで分かれてるからそれをsourceとするmodule
ブロックを作ってくれるってやつだったのね
provider "google" {
project = "mango-harvester"
}
module "projects-mango-harvester-IAMServiceAccount" {
source = "./projects/mango-harvester/IAMServiceAccount"
}
module "gcp-<PROJECT_NUMBER>-Service" {
source = "./<PROJECT_NUMBER>/Service"
}
module "gcp-<PROJECT_NUMBER>-<PROJECT_NUMBER>-Project-LoggingLogSink" {
source = "./<PROJECT_NUMBER>/<PROJECT_NUMBER>/Project/LoggingLogSink"
}

こっちはimport.sh
。めっちゃインポート文書いてくれてる。ありがてえ
#!/bin/sh
# Terraform Import Script generated by gcloud cli
terraform import module.gcp-<PROJECT_NUMBER>-<PROJECT_NUMBER>-Project-LoggingLogSink.google_logging_log_sink.a_required <PROJECT_NUMBER>###_Required
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.bigquery_googleapis_com <PROJECT_NUMBER>/bigquery.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.bigquerystorage_googleapis_com <PROJECT_NUMBER>/bigquerystorage.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.cloudapis_googleapis_com <PROJECT_NUMBER>/cloudapis.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.clouddebugger_googleapis_com <PROJECT_NUMBER>/clouddebugger.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.cloudfunctions_googleapis_com <PROJECT_NUMBER>/cloudfunctions.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.cloudtrace_googleapis_com <PROJECT_NUMBER>/cloudtrace.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.compute_googleapis_com <PROJECT_NUMBER>/compute.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.container_googleapis_com <PROJECT_NUMBER>/container.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.containerregistry_googleapis_com <PROJECT_NUMBER>/containerregistry.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.datastore_googleapis_com <PROJECT_NUMBER>/datastore.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.iam_googleapis_com <PROJECT_NUMBER>/iam.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.iamcredentials_googleapis_com <PROJECT_NUMBER>/iamcredentials.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.logging_googleapis_com <PROJECT_NUMBER>/logging.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.monitoring_googleapis_com <PROJECT_NUMBER>/monitoring.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.oslogin_googleapis_com <PROJECT_NUMBER>/oslogin.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.pubsub_googleapis_com <PROJECT_NUMBER>/pubsub.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.servicemanagement_googleapis_com <PROJECT_NUMBER>/servicemanagement.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.serviceusage_googleapis_com <PROJECT_NUMBER>/serviceusage.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.sql_component_googleapis_com <PROJECT_NUMBER>/sql-component.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.storage_api_googleapis_com <PROJECT_NUMBER>/storage-api.googleapis.com
terraform import module.gcp-<PROJECT_NUMBER>-Service.google_project_service.storage_component_googleapis_com <PROJECT_NUMBER>/storage-component.googleapis.com
terraform import module.projects-mango-harvester-IAMServiceAccount.google_service_account.mango_harvester projects/mango-harvester/serviceAccounts/mango-harvester@mango-harvester.iam.gserviceaccount.com

./gcp
を消して、一からやり直してみる。
今回はterraform plan
まで行きたい
-
gcloud beta resource-config bulk-export
でプロジェクトをエクスポート -
gcloud beta resource-config terraform generate-import
でインポートのshell scriptとmodule.tfを生成 -
terraform init
&&terraform plan
-
import.sh
でリソースをインポート - 再度
terraform plan

-
gcloud beta resource-config bulk-export
でプロジェクトをエクスポート
❯ gcloud beta resource-config bulk-export \
--project mango-harvester \
--resource-format=terraform \
--path=./gcp

-
gcloud beta resource-config terraform generate-import
でインポートのshell scriptとmodule.tfを生成
❯ cd gcp/
❯ gcloud beta resource-config terraform generate-import \
. \
--output-script-file=import.sh \
--output-module-file=modules.tf

-
terraform init
&&terraform plan
❯ terraform init
Initializing modules...
- gcp-<PROJECT_NUMBER>-<PROJECT_NUMBER>-Project-LoggingLogSink in <PROJECT_NUMBER>/<PROJECT_NUMBER>/Project/LoggingLogSink
- gcp-<PROJECT_NUMBER>-Service in <PROJECT_NUMBER>/Service
- projects-mango-harvester-IAMServiceAccount in projects/mango-harvester/IAMServiceAccount
Initializing the backend...
Initializing provider plugins...
- Finding latest version of hashicorp/google...
- Installing hashicorp/google v4.15.0...
- Installed hashicorp/google v4.15.0 (signed by HashiCorp)
Terraform has created a lock file .terraform.lock.hcl to record the provider
selections it made above. Include this file in your version control repository
so that Terraform can guarantee to make the same selections by default when
you run "terraform init" in the future.
Terraform has been successfully initialized!
You may now begin working with Terraform. Try running "terraform plan" to see
any changes that are required for your infrastructure. All Terraform commands
should now work.
If you ever set or change modules or backend configuration for Terraform,
rerun this command to reinitialize your working directory. If you forget, other
commands will detect it and remind you to do so if necessary.
google_logging_log_sink
リソースがプロバイダになくてエラーになるのでtfファイルから排除した。
❯ terraform plan
...
Plan: 23 to add, 0 to change, 0 to destroy.
23 add。

-
import.sh
でリソースをインポート
❯ ./import.sh
...
module.projects-mango-harvester-IAMServiceAccount.google_service_account.mango_harvester: Import prepared!
Prepared google_service_account for import
module.projects-mango-harvester-IAMServiceAccount.google_service_account.mango_harvester: Refreshing state... [id=projects/mango-harvester/serviceAccounts/mango-harvester@mango-harvester.iam.gserviceaccount.com]
╷
│ Error: Cannot import non-existent remote object
│
│ While attempting to import an existing object to
│ "module.projects-mango-harvester-IAMServiceAccount.google_service_account.mango_harvester",
│ the provider detected that no object exists with the given id. Only pre-existing
│ objects can be imported; check that the id is correct and that it is associated
│ with the provider's configured region or endpoint, or use "terraform apply" to
│ create a new remote object for this resource.
╵
サービスアカウントが存在しないとかで怒られた。
確かになかった。よくわからんので無視

- 再度
terraform plan
❯ terraform plan
~ update in-place
Terraform will perform the following actions:
# module.gcp-<PROJECT_NUMBER>-Service.google_project_service.bigquery_googleapis_com will be updated in-place
~ resource "google_project_service" "bigquery_googleapis_com" {
+ disable_on_destroy = true
id = "<PROJECT_NUMBER>/bigquery.googleapis.com"
# (2 unchanged attributes hidden)
# (1 unchanged block hidden)
}
...
Plan: 0 to add, 22 to change, 0 to destroy.
各google_project_service
でdisable_on_destroy = true
が追加される。これは多分Terraform独自のパラメータで、インポートしただけじゃStateに存在しなくて差分が出るんだろう。
disable_on_destroy - (Optional) If true, disable the service when the Terraform resource is destroyed. Defaults to true. May be useful in the event that a project is long-lived but the infrastructure running in that project changes frequently.
https://registry.terraform.io/providers/hashicorp/google/latest/docs/resources/google_project_service#disable_on_destroy
リソースがデストロイされたときにサービスを無効にするオプションでした。

↑applyした。

google_logging_log_sink
がサポートされてないと出る件について
❯ terraform plan
╷
│ Error: Invalid resource type
│
│ on <PROJECT_NUMBER>/<PROJECT_NUMBER>/Project/LoggingLogSink/a-required.tf line 1, in resource "google_logging_log_sink" "a_required":
│ 1: resource "google_logging_log_sink" "a_required" {
│
│ The provider hashicorp/google does not support resource type
│ "google_logging_log_sink".
╵

ググってもhashicorp/terraform-provider-googleで調べても全く出てこんのやが。
このリソースは一体...?

LoggingLogSinkは存在する

わからん。無視する

❯ ./import.sh
module.gcp-<PROJECT_NUMBER>-Service.google_project_service.bigquery_googleapis_com: Importing from ID "<PROJECT_NUMBER>/bigquery.googleapis.com"...
module.gcp-<PROJECT_NUMBER>-Service.google_project_service.bigquery_googleapis_com: Import prepared!
Prepared google_project_service for import
module.gcp-<PROJECT_NUMBER>-Service.google_project_service.bigquery_googleapis_com: Refreshing state... [id=<PROJECT_NUMBER>/bigquery.googleapis.com]
╷
│ Error: Error when reading or editing Project Service <PROJECT_NUMBER>/bigquery.googleapis.com: googleapi: Error 403: The caller does not have permission, forbidden
│
│
╵
Error: Error when reading or editing Project Service <PROJECT_NUMBER>/bigquery.googleapis.com: googleapi: Error 403: The caller does not have permission, forbidden
permissionが無くてimportできない件

planはできるんだけど

roles/resourcemanager.projectIamAdmin
ロールを付与するといい?今俺はどのユーザで認証しているんだ?
google cloud platform - How to resolve "googleapi: Error 403: The caller does not have permission, forbidden" - Stack Overflow

下を参考にgcloud auth application-default login
で認証した後にimport.sh
叩いたらいけたな...
どういう認証になってたんだろ。わからん。
First, authenticate with GCP. The easiest way to do this is to run gcloud auth application-default login, if you already have gcloud installed. If you don't already have it, you can install it from here.
https://registry.terraform.io/providers/hashicorp/google/latest/docs/guides/getting_started#configuring-the-provider

まとめ
- 👍🏼 簡単に既存リソースからtfファイルを生成できる
- 👎🏼 生成にまあまあ時間かかる
- ほぼ空のプロジェクトで2分強
- 👎🏼 変数に切り出してほしい部分もちょいちょいある
- そこは自分でがんばらないといけない
- ディレクトリ構造がよくわからない
- ベストプラクティスかなんかに則ってるのかも
- 自分の知識不足なだけ説はある
- 👎🏼 プロバイダに存在しないリソースが生まれた
google_logging_log_sink
- https://zenn.dev/link/comments/c5802fbfe8b901
- 👎🏼 プロジェクトに存在しないリソースが生まれた
- 👎🏼 まだベータなので未対応リソースがある
- 👎🏼 生成にまあまあ時間かかる
- 👍🏼
module.tf
とimport.sh
を生成してくれるので簡単にインポートできる。- 謎のリソースの部分はインポートできず
- 👍🏼 それ以外はインポートできた
- 👍🏼 gcloudコマンド便利
- aws cliもがんばってほしい

いらんプロジェクト消そ