LoginSignup
1
0

More than 5 years have passed since last update.

リージョン丸ごと綺麗にしてみた

Last updated at Posted at 2019-03-02

環境作りの練習に使っていた環境を削除するので、その様子をメモ書きします。

やったこと

  1. CloudFormationのスタックを削除する準備
  2. CloudFormationのスタックを削除する
  3. 残ったものを削除する

1. CloudFormationのスタックを削除する準備

  • ECRを削除します。
    あらかじめ消さない場合、以下のようにCloudFormationのスタック削除が失敗します。
in registry with id '******' cannot be deleted because it still contains images (Service: AmazonECR; Status Code: 400; Error Code: RepositoryNotEmptyException; Request ID: cbe340fe-39e6-11e9-90f7-******)
  • API GatewayのVPC Linkを削除します。

    VPC Linkが参照しているリソースは削除できないためです。

  • RDSインスタンスを削除します。

2. CloudFormationのスタックを削除する

普通にCloudFormationのコンソール画面からスタックを削除します。

3. 残ったものを削除する

  • EC2のマネジメントコンソールからネットワークインターフェースの一覧を表示し、それを削除対象のVPCで絞り込み、利用しているリソースを削除します。

  • ENIを利用しているリソースを削除したら、次はENIをでタッチします。

  • 最後にVPCを削除します。

  • Route53で登録されているドメイン名から、使わなくなったものを削除します。

1
0
0

Register as a new user and use Qiita more conveniently

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