Professional Documents
Culture Documents
3 Zones in 3 Weeks. Devops With Terraform, Ansible and Packer
3 Zones in 3 Weeks. Devops With Terraform, Ansible and Packer
3 Zones in 3 Weeks. Devops With Terraform, Ansible and Packer
3 Zones in 3 Weeks.
DevOps with Terraform,
Ansible and Packer
#v FORUMAU
PROJECT OCTOPUS
Building
Proposed
The Challenge
• vCenter
• Veeam Backup & Recovery • Load Balancers
• ESXi
• Zerto • Networking
• vCloud Director
• NSX • Star (Zettagrid Automation) • Databases
• vSAN • Message Queues
• vCloud Availability • Management
• vRealize Operations • Monitoring
• LogInsight
Why Automate with DevOps?
• Small Team, ~1,000 VMs per engineer • Speed, Reliability and Consistency
• Manual Tasks Increase: • Team members empowered
– Human Error • Faster Feedback
– Configuration Drift • Testable, Repeatable Infrastructure
– Increased lead times and overheads • Reduction in latency between dependent
tasks
What Needs Automating
• Infrastructure/Platform Agnostic
– Avoid lock-in to a specific platform
– Nimble, composable and flexibility to adapt
• Ideally Open Source
– Scope to extend to support new platforms/infrastructure
• Widely Adopted
– Training and Reference Materials
• Configured with human readable text files (JSON, YAML)
– Maintain Version Control
– Serves as Documentation
– Point and Click is no longer an acceptable form of configuring infrastructure
Challenges and Approach - Human Element
Challenges Approaches
• Learning Curve
• Training and Coaching
– Expecting too much too soon: People
become hostile • KPIs/OKRs: Assess skills, create road maps
– Can be daunting - individuals evolve at their own pace
• Different Teams, Different Tools • Prioritise tools that have multiple interfaces
– Wasted Effort (CLI, API, Web) – e.g. GitHub/GitLab
• DevOps is not a rebranded SysAdmin Role • Run regular team “show and tell” sessions
– Can have similar outcomes, skills and • Understand DevOps team topologies
approach differ (devopstopologies.com)
Infrastructure as Code – Tools of the Trade
• Packer:
– Single Configuration: Multiple Images
and Platforms
– Open Source, lightweight, runs on all
major OS
– Supports vSphere, AWS EC2 AMIs,
VirtualBox and more
• Use Cases:
– Building Appliances
– Base Templates
– Development and Production Parity
– Continuous Delivery
Building VM Images with Packer
Deploying Infrastructure with Terraform
• What is infrastructure?
– VMs (vSphere, vCloud) and Compute
Instances (AWS, Azure)
– DNS Entries
– Networks, Firewall Rules
– Databases
– SaaS Services – PagerDuty, StatusCake,
NewRelic
– Community Providers provide automation
of anything imaginable
Deploying Infrastructure with Terraform
Terraform Configuration
• Terraform Inputs:
– Variable Files: Variables specific to the
environment
– Configuration Files: Reference variables and
modules
– Modules: Collections of resources, keeps
things DRY
• Terraform Outputs:
– Infrastructure
– Updated State Data
• No Agents:
– SSH on Linux
– WinRM on Windows
• Roles:
– Write your own
– Galaxy – thousands of user contributed Roles
– Comprise Variables, Tasks and Handlers
– One Role can target multiple OS/Platform (Facts)
Configuration Management with Ansible
Project Octopus – Bringing it all together
Conclusions
Questions?
#v FORUMAU
4
Join the
conversation
#vFORUMAU @VMwareAU
#v FORUMAU