Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ステージング環境と本番環境、両方でMigrationが実行できる環境を構築 #54

Merged
merged 8 commits into from
Dec 12, 2021

Conversation

kobayashi-m42
Copy link
Member

@kobayashi-m42 kobayashi-m42 commented Dec 11, 2021

issueURL

#42

関連URL

#53
nekochans/lgtm-cat-migration#6

Doneの定義

ステージング環境と本番環境、両方でMigrationが実行出来ること

変更点概要

ステージング環境と本番環境、両方でMigrationが実行できる環境を構築するために下記の変更を行った。

  • ece-migration module の修正
    • migration 用 ECS に設定する SSMパラメータストアを環境ごとに作成するように変更 (対象のDB、ユーザーが異なるため)
  • データベース名を variables.tf に記載していたが、SecretManager から取得する形に変更
  • rds module の修正
    • PROD環境用に RDS に接続するための Route53 CNAME レコードを追加 (今までは STG 用のみ構築していた)
    • STG環境用の ECS から RDS に接続できるように SecurityGroup の ingress ルールを追加
  • STG 環境に migration 実行環境のリソースを追加

補足情報

migration の実行の設定は、 nekochans/lgtm-cat-migration#6 で対応している。
STG、PROD 環境にそれぞれ migration を実行できることを確認済み。

@kobayashi-m42 kobayashi-m42 self-assigned this Dec 11, 2021
Copy link
Member

@keitakn keitakn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

対応ありがとう🐱方針含めて問題なさそう👌

LGTMeow

@kobayashi-m42 kobayashi-m42 merged commit 9df9513 into main Dec 12, 2021
@kobayashi-m42 kobayashi-m42 deleted the feature/issue42/add-stg-migration branch December 12, 2021 10:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants