SlideShare a Scribd company logo
Effettuare il
provisioning su Azure
utilizzando Terraform e
Azure DevOps
GIORGIO LASALA
Thanks to
www.linkedin.com/in/giorgiolasala
github.com/salem84
Solution Architect
@ Engineering Ingegneria Informatica
giorgio.lasala@eng.it
AGENDA
• Infrastructure as Code
• Terraform Architecture and Workflow
• IaaS provisioning
• PaaS provisioning
• Terraform with Azure DevOps using YAML
• Terraform with Azure DevOps using Plugins
• Provisioning SharePoint Farm with Terraform
• Provisioning Azure ETL with Terraform
Once upon a time… (Windows) Azure
Today… Microsoft Azure
Azure and Command Line
Infrastructure as Code (IaC)
“Infrastructure as Code is the process of managing and
provisioning computing infrastructure and its configuration
through machine-processable definition files. It treats the
infrastructure as a software system, applying software
engineering practices to manage changes to the system in a
structured, safe way”
Infrastructure as Code characteristics
• Consistency
• Treat infrastructure like application code
• Single source of truth
• Increase repeatability and testability
• Idempotent provisioning and configuration
• Speed
• Decrease provisioning time
Infrastructure as Code characteristics
• Accountability
• Rely less on availability of persons to perform tasks
• Always know what is changed
• Validate infrastructure before deployment
• Increased Efficiency
• Use proven software development practices for
deploying infrastructure
• Lowering the costs of infrastructure management
Terraform
www.terraform.io
Core ideas in Terraform
• IaC Tool
• Open Source
• Multiplatform (Windows, Linux, Mac, …)
• Multiprovider (+200) cloud and on-premise, but …
• Plan validation
• HashiCorp Configuration Language (HCL) ~ JSON
• Simple model of resource entities with attributes
• Stateful lifecycle with CRUD operations
• Declarative configuration
• Dependencies by inference
• Parallel execution
Terraform Architecture
Terraform flow
terraform init
Init ApplyPlan
Terraform
Scripts
Terraform
State
terraform plan –out plan.dat
terraform apply plan.dat
Terminology in Terraform
Providers
Offer technology integrations and functionality, largely by wrapping third-
party APIs (e.g. azurerm)
Resources and Data Sources
Made available via a Provider, are the building blocks used to codify and
manage infrastructure; have a set of configurable attributes and a lifecycle
such as create, read, update, delete (e.g. Azure App Service)
Made reusable with Modules
Provisioner
Initiliaze a resource from a local or remote script
Provisioning with Terraform - AzureDay Reloaded
Provisioning with Terraform - AzureDay Reloaded
Terraform flow with Azure
Init ApplyPlan
State file contiene
informazioni
sensibiliState condiviso Locking dello stato 
Deployment con Azure Pipelines
Provisioning with Terraform - AzureDay Reloaded
Provisioning with Terraform - AzureDay Reloaded
Provisioning with Terraform - AzureDay Reloaded
Demo
Joy and pain of Terraform
• Declarative language
• Not imperative
• It’s not ARM
• Slower
• Not integrated in Azure Management Portal
• Provider coverage largely depends on community
• State file is critical
• Creation, storing and maintenance
• Integration with existing infrastructure
• Import command is for single resource
• Not aware of API rate and resources limits (plan / apply)
✓ Use a VCS
✓ Use remote state and access policy
❑ e. g. use a single build server
✓ Avoid user credentials in Terraform code
✓ Naming convention
❑ e. g. "${var.shortname}-{var.env}"
✓ Use VSCode with following extensions:
❑ Terraform [mauve.terraform] by Mikael Olenfalk
❑ Terraform doc snippet [run-at-scale.terraform-doc-
snippets] by Brandon O'Connor
Terraform tips and tricks
✓ https://github.com/shuaibiyy/awesome-terraform
✓ https://28mm.github.io/notes/d3-terraform-graphs
Hashicorp Docs and modules
✓ https://www.terraform.io/docs/
✓ https://registry.terraform.io/
Framework testing
✓ https://github.com/gruntwork-io/terratest
Terraform tips and links
Provisioning with Terraform - AzureDay Reloaded
Thank You!!!
Thanks to

More Related Content

What's hot (14)

PDF
Terraform @Base
Miroslaw Nagas
 
PPTX
Automation in Cloud
Abhishek Amralkar
 
PDF
Terraform Q&A - HashiCorp User Group Oslo
Anton Babenko
 
PPTX
Comprehensive Terraform Training
Yevgeniy Brikman
 
PPTX
Terraform day 1
Kalkey
 
PDF
Scaling terraform
Paolo Tonin
 
PPTX
Terraform modules restructured
Ami Mahloof
 
PPTX
Transforming Infrastructure into Code - Importing existing cloud resources u...
Shih Oon Liong
 
PPTX
Cloud storage with AWS
Ahmad karawash
 
PDF
Installing WordPress on AWS
Manish Jain
 
PPTX
Reusable, composable, battle-tested Terraform modules
Yevgeniy Brikman
 
PPTX
Terraform on Azure
Mithun Shanbhag
 
PPT
Rocking the enterprise with Ruby - RubyKaigi 2010
releasebeta
 
PDF
Case Study: Using Terraform and Packer to deploy go applications to AWS
Patrick Bolduan
 
Terraform @Base
Miroslaw Nagas
 
Automation in Cloud
Abhishek Amralkar
 
Terraform Q&A - HashiCorp User Group Oslo
Anton Babenko
 
Comprehensive Terraform Training
Yevgeniy Brikman
 
Terraform day 1
Kalkey
 
Scaling terraform
Paolo Tonin
 
Terraform modules restructured
Ami Mahloof
 
Transforming Infrastructure into Code - Importing existing cloud resources u...
Shih Oon Liong
 
Cloud storage with AWS
Ahmad karawash
 
Installing WordPress on AWS
Manish Jain
 
Reusable, composable, battle-tested Terraform modules
Yevgeniy Brikman
 
Terraform on Azure
Mithun Shanbhag
 
Rocking the enterprise with Ruby - RubyKaigi 2010
releasebeta
 
Case Study: Using Terraform and Packer to deploy go applications to AWS
Patrick Bolduan
 

Similar to Provisioning with Terraform - AzureDay Reloaded (20)

PDF
Deploy resources on Azure using IaC (Azure Terraform)
George Grammatikos
 
PDF
Infrastructure as Code with Terraform
Tim Berry
 
PDF
Introduction to IAC and Terraform
Venkat NaveenKashyap Devulapally
 
PPTX
Linode_eBook_Declarative_Cloud_Infrastructure_Management_with_Terraform.pptx
AkwasiBoateng6
 
PPTX
Terraform
An Nguyen
 
PDF
Infrastructure-As-A/From-Code - An Introduction
Alex Tjahjana
 
PPTX
Infrastructure as Code with Terraform.pptx
Samuel862293
 
PPTX
Azure enterprise integration platform
Michael Stephenson
 
PPTX
A brief introduction to IaC with Terraform by Kenton Robbins (codeHarbour May...
Alex Cachia
 
PDF
Terraform vs Pulumi
HoaiNam307
 
PPTX
Terraform Automation in Azure Cloud Online Training in Hyderabad.pptx
sivavisualpath
 
PPTX
Terraform Automation in Azure Online Training Institute in Hyderabad.pptx
sivavisualpath
 
PDF
Terraform Definition, Working and Challenges it Overcomes
Eyeglass Repair USA
 
PPTX
Terraform Basics
Mohammed Fazuluddin
 
PDF
PuppetConf 2017: Unlocking Azure with Puppet Enterprise- Keiran Sweet, Source...
Puppet
 
PPTX
apidays Munich 2025 - Building an AWS Serverless Application with Terraform, ...
apidays
 
PDF
TechnicalTerraformLandingZones121120229238.pdf
MIlton788007
 
PPTX
Infrastructure as Code - Getting Started, Concepts & Tools
Lior Kamrat
 
PPTX
Infrastructure as code with terraform and packer
Alex Landa
 
PDF
Intro to Telegraf
InfluxData
 
Deploy resources on Azure using IaC (Azure Terraform)
George Grammatikos
 
Infrastructure as Code with Terraform
Tim Berry
 
Introduction to IAC and Terraform
Venkat NaveenKashyap Devulapally
 
Linode_eBook_Declarative_Cloud_Infrastructure_Management_with_Terraform.pptx
AkwasiBoateng6
 
Terraform
An Nguyen
 
Infrastructure-As-A/From-Code - An Introduction
Alex Tjahjana
 
Infrastructure as Code with Terraform.pptx
Samuel862293
 
Azure enterprise integration platform
Michael Stephenson
 
A brief introduction to IaC with Terraform by Kenton Robbins (codeHarbour May...
Alex Cachia
 
Terraform vs Pulumi
HoaiNam307
 
Terraform Automation in Azure Cloud Online Training in Hyderabad.pptx
sivavisualpath
 
Terraform Automation in Azure Online Training Institute in Hyderabad.pptx
sivavisualpath
 
Terraform Definition, Working and Challenges it Overcomes
Eyeglass Repair USA
 
Terraform Basics
Mohammed Fazuluddin
 
PuppetConf 2017: Unlocking Azure with Puppet Enterprise- Keiran Sweet, Source...
Puppet
 
apidays Munich 2025 - Building an AWS Serverless Application with Terraform, ...
apidays
 
TechnicalTerraformLandingZones121120229238.pdf
MIlton788007
 
Infrastructure as Code - Getting Started, Concepts & Tools
Lior Kamrat
 
Infrastructure as code with terraform and packer
Alex Landa
 
Intro to Telegraf
InfluxData
 
Ad

Recently uploaded (20)

PDF
Step-by-Step Guide to Install SAP HANA Studio | Complete Installation Tutoria...
SAP Vista, an A L T Z E N Company
 
PDF
Enhancing Security in VAST: Towards Static Vulnerability Scanning
ESUG
 
PDF
Salesforce Pricing Update 2025: Impact, Strategy & Smart Cost Optimization wi...
GetOnCRM Solutions
 
PDF
advancepresentationskillshdhdhhdhdhdhhfhf
jasmenrojas249
 
PDF
Using licensed Data Loss Prevention (DLP) as a strategic proactive data secur...
Q-Advise
 
PDF
AI Image Enhancer: Revolutionizing Visual Quality”
docmasoom
 
PPTX
TRAVEL APIs | WHITE LABEL TRAVEL API | TOP TRAVEL APIs
philipnathen82
 
PDF
MiniTool Power Data Recovery Crack New Pre Activated Version Latest 2025
imang66g
 
PPT
Brief History of Python by Learning Python in three hours
adanechb21
 
PDF
Adobe Illustrator Crack Full Download (Latest Version 2025) Pre-Activated
imang66g
 
PPTX
Web Testing.pptx528278vshbuqffqhhqiwnwuq
studylike474
 
PDF
SAP GUI Installation Guide for Windows | Step-by-Step Setup for SAP Access
SAP Vista, an A L T Z E N Company
 
PDF
New Download MiniTool Partition Wizard Crack Latest Version 2025
imang66g
 
PDF
New Download FL Studio Crack Full Version [Latest 2025]
imang66g
 
PDF
Supabase Meetup: Build in a weekend, scale to millions
Carlo Gilmar Padilla Santana
 
PDF
How to Download and Install ADT (ABAP Development Tools) for Eclipse IDE | SA...
SAP Vista, an A L T Z E N Company
 
PDF
Applitools Platform Pulse: What's New and What's Coming - July 2025
Applitools
 
PPT
Activate_Methodology_Summary presentatio
annapureddyn
 
PPTX
Presentation about Database and Database Administrator
abhishekchauhan86963
 
PDF
Salesforce Implementation Services Provider.pdf
VALiNTRY360
 
Step-by-Step Guide to Install SAP HANA Studio | Complete Installation Tutoria...
SAP Vista, an A L T Z E N Company
 
Enhancing Security in VAST: Towards Static Vulnerability Scanning
ESUG
 
Salesforce Pricing Update 2025: Impact, Strategy & Smart Cost Optimization wi...
GetOnCRM Solutions
 
advancepresentationskillshdhdhhdhdhdhhfhf
jasmenrojas249
 
Using licensed Data Loss Prevention (DLP) as a strategic proactive data secur...
Q-Advise
 
AI Image Enhancer: Revolutionizing Visual Quality”
docmasoom
 
TRAVEL APIs | WHITE LABEL TRAVEL API | TOP TRAVEL APIs
philipnathen82
 
MiniTool Power Data Recovery Crack New Pre Activated Version Latest 2025
imang66g
 
Brief History of Python by Learning Python in three hours
adanechb21
 
Adobe Illustrator Crack Full Download (Latest Version 2025) Pre-Activated
imang66g
 
Web Testing.pptx528278vshbuqffqhhqiwnwuq
studylike474
 
SAP GUI Installation Guide for Windows | Step-by-Step Setup for SAP Access
SAP Vista, an A L T Z E N Company
 
New Download MiniTool Partition Wizard Crack Latest Version 2025
imang66g
 
New Download FL Studio Crack Full Version [Latest 2025]
imang66g
 
Supabase Meetup: Build in a weekend, scale to millions
Carlo Gilmar Padilla Santana
 
How to Download and Install ADT (ABAP Development Tools) for Eclipse IDE | SA...
SAP Vista, an A L T Z E N Company
 
Applitools Platform Pulse: What's New and What's Coming - July 2025
Applitools
 
Activate_Methodology_Summary presentatio
annapureddyn
 
Presentation about Database and Database Administrator
abhishekchauhan86963
 
Salesforce Implementation Services Provider.pdf
VALiNTRY360
 
Ad

Provisioning with Terraform - AzureDay Reloaded

  • 1. Effettuare il provisioning su Azure utilizzando Terraform e Azure DevOps GIORGIO LASALA
  • 4. AGENDA • Infrastructure as Code • Terraform Architecture and Workflow • IaaS provisioning • PaaS provisioning • Terraform with Azure DevOps using YAML • Terraform with Azure DevOps using Plugins • Provisioning SharePoint Farm with Terraform • Provisioning Azure ETL with Terraform
  • 5. Once upon a time… (Windows) Azure
  • 8. Infrastructure as Code (IaC) “Infrastructure as Code is the process of managing and provisioning computing infrastructure and its configuration through machine-processable definition files. It treats the infrastructure as a software system, applying software engineering practices to manage changes to the system in a structured, safe way”
  • 9. Infrastructure as Code characteristics • Consistency • Treat infrastructure like application code • Single source of truth • Increase repeatability and testability • Idempotent provisioning and configuration • Speed • Decrease provisioning time
  • 10. Infrastructure as Code characteristics • Accountability • Rely less on availability of persons to perform tasks • Always know what is changed • Validate infrastructure before deployment • Increased Efficiency • Use proven software development practices for deploying infrastructure • Lowering the costs of infrastructure management
  • 12. Core ideas in Terraform • IaC Tool • Open Source • Multiplatform (Windows, Linux, Mac, …) • Multiprovider (+200) cloud and on-premise, but … • Plan validation • HashiCorp Configuration Language (HCL) ~ JSON • Simple model of resource entities with attributes • Stateful lifecycle with CRUD operations • Declarative configuration • Dependencies by inference • Parallel execution
  • 14. Terraform flow terraform init Init ApplyPlan Terraform Scripts Terraform State terraform plan –out plan.dat terraform apply plan.dat
  • 15. Terminology in Terraform Providers Offer technology integrations and functionality, largely by wrapping third- party APIs (e.g. azurerm) Resources and Data Sources Made available via a Provider, are the building blocks used to codify and manage infrastructure; have a set of configurable attributes and a lifecycle such as create, read, update, delete (e.g. Azure App Service) Made reusable with Modules Provisioner Initiliaze a resource from a local or remote script
  • 18. Terraform flow with Azure Init ApplyPlan State file contiene informazioni sensibiliState condiviso Locking dello stato 
  • 19. Deployment con Azure Pipelines
  • 23. Demo
  • 24. Joy and pain of Terraform • Declarative language • Not imperative • It’s not ARM • Slower • Not integrated in Azure Management Portal • Provider coverage largely depends on community • State file is critical • Creation, storing and maintenance • Integration with existing infrastructure • Import command is for single resource • Not aware of API rate and resources limits (plan / apply)
  • 25. ✓ Use a VCS ✓ Use remote state and access policy ❑ e. g. use a single build server ✓ Avoid user credentials in Terraform code ✓ Naming convention ❑ e. g. "${var.shortname}-{var.env}" ✓ Use VSCode with following extensions: ❑ Terraform [mauve.terraform] by Mikael Olenfalk ❑ Terraform doc snippet [run-at-scale.terraform-doc- snippets] by Brandon O'Connor Terraform tips and tricks
  • 26. ✓ https://github.com/shuaibiyy/awesome-terraform ✓ https://28mm.github.io/notes/d3-terraform-graphs Hashicorp Docs and modules ✓ https://www.terraform.io/docs/ ✓ https://registry.terraform.io/ Framework testing ✓ https://github.com/gruntwork-io/terratest Terraform tips and links