Upgrade to PRO for Only $50/Year—Limited-Time Offer! 🔥
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Terraform workspaces
Search
Mattias Gees
January 17, 2018
Programming
0
100
Terraform workspaces
How can you use Terraform workspaces and how can you structure your Terraform projects better.
Mattias Gees
January 17, 2018
Tweet
Share
More Decks by Mattias Gees
See All by Mattias Gees
A Cloud Native Journey At Scale (Belgium Kubernetes Meetup)
mattiasgees
0
37
Tarmak, why do we need another Kubernetes provisioner?
mattiasgees
1
260
Pod autoscaling with custom-metrics
mattiasgees
0
74
Lightning Talk Prometheus
mattiasgees
0
65
Introduction to Ansible
mattiasgees
0
110
Other Decks in Programming
See All in Programming
まだ間に合う!Claude Code元年をふりかえる
nogu66
5
870
Giselleで作るAI QAアシスタント 〜 Pull Requestレビューに継続的QAを
codenote
0
270
Deno Tunnel を使ってみた話
kamekyame
0
200
Socio-Technical Evolution: Growing an Architecture and Its Organization for Fast Flow
cer
PRO
0
390
ローターアクトEクラブ アメリカンナイト:川端 柚菜 氏(Japan O.K. ローターアクトEクラブ 会長):2720 Japan O.K. ロータリーEクラブ2025年12月1日卓話
2720japanoke
0
740
tparseでgo testの出力を見やすくする
utgwkk
2
260
バックエンドエンジニアによる Amebaブログ K8s 基盤への CronJobの導入・運用経験
sunabig
0
170
大規模Cloud Native環境におけるFalcoの運用
owlinux1000
0
180
AIエンジニアリングのご紹介 / Introduction to AI Engineering
rkaga
8
3.2k
ハイパーメディア駆動アプリケーションとIslandアーキテクチャ: htmxによるWebアプリケーション開発と動的UIの局所的適用
nowaki28
0
440
エディターってAIで操作できるんだぜ
kis9a
0
750
著者と進める!『AIと個人開発したくなったらまずCursorで要件定義だ!』
yasunacoffee
0
150
Featured
See All Featured
Leading Effective Engineering Teams in the AI Era
addyosmani
9
1.4k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
1.8k
Primal Persuasion: How to Engage the Brain for Learning That Lasts
tmiket
0
180
What Being in a Rock Band Can Teach Us About Real World SEO
427marketing
0
140
Code Review Best Practice
trishagee
74
19k
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
36
[RailsConf 2023] Rails as a piece of cake
palkan
58
6.2k
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
110
Principles of Awesome APIs and How to Build Them.
keavy
127
17k
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
280
sira's awesome portfolio website redesign presentation
elsirapls
0
87
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
Transcript
Terraform workspaces Mattias Gees
Mattias Gees • Cloud Engineer @skyscrapers • Avid runner •
Likes to experiment github.com/mattiasgees twitter.com/mattiasgees blog.mattiasgees.be
Who has used Terraform?
Some history!
Flat file
Modules
Remote config v1 terraform remote config \ -backend=s3 \ -backend-config="bucket=s3-bucket"
\ -backend-config="key=project" \ -backend-config="region=us-east-1"
Remote config v2 terraform { required_version = ">= 0.11.2" backend
"s3" { bucket = "s3-bucket" key = "project" region = "us-east-1" dynamodb_table = "terraform-state-lock-example-default" encrypt = true } }
Remote config v2 • local • artifactory • azurerm •
consul • etcd • gcs
Remote config v2 • http • manta • s3 •
swift • terraform enterprise
Workspaces
What are they? • First called terraform env • Introduced
in 0.9.0, renamed in 0.10.0 • One codebase, multiple deployments • Works with certain backends
How to use it?
Variables Tfvars vs Maps
Multiple projects • Datasource for remote state • Split up
logically
Terragrunt • Var file per workspace • Specific Terraform CLI
flags • Execute on multiple projects at once • ...
CI/CD Plan before deploy
Partial configuration
CI/CD Tools • Testing • Kitchen-Terraform • AWSpec • Deployment
• Atlantis from Hootsuite • HashiCorp Terraform Enterprise • Your own CI/CD tool
Future
Questions?
None