ecspresso icon indicating copy to clipboard operation
ecspresso copied to clipboard

Feature Request: Multiple tfstates reference Support

Open sogaoh opened this issue 1 year ago • 1 comments

2022/8/25 の HashiTalks での @saki-engineering による ベストな Terraform ディレクトリ構成を考察してみた という発表を聞いて、 管理単位の小さいパターンにも ecspresso で対応できないかなあ、と思いました。

  • セッション資料
    • https://speakerdeck.com/harukasakihara/besutona-terraform-deirekutorigou-cheng-wokao-cha-sitemita?slide=4
  • セッション動画
    • https://www.youtube.com/watch?v=4A-c-ykc0ak&
      • 5:40:00 あたりから 5:55:00 あたり

以下のようなラフな ecspresso.yml のインターフェースイメージなどで、実現可能性を検討いただければ幸いです。 (別の形でも、実現できれば良いと思います)

plugins:
  - name: tfstate
    index: db
    config:
      path: db/stg/terraform.tfstate    # path to tfstate file
      # or url: s3://my-bucket/db/stg/terraform.tfstate
  - name: tfstate
    index: ec2
    config:
      path: ec2/stg/terraform.tfstate    # path to tfstate file
      # or url: s3://my-bucket/ec2/stg/terraform.tfstate

勝手ながら、v2.1 くらいで・・・というレベル感かなあ、などと妄想しています。。

sogaoh avatar Aug 29 '22 16:08 sogaoh

複数tfstateについては #398 がmerge済なので、v2リリースで使えるようになる予定です!

fujiwara avatar Aug 30 '22 05:08 fujiwara