This document provides an overview of Terraform and infrastructure as code using Terraform. It discusses what Terraform is, how to get started with Terraform including initializing a Terraform configuration, planning and applying changes, variables, modules, providers and resources. It also covers Terraform state and locking state for multi-user collaboration.
A comprehensive walkthrough of how to manage infrastructure-as-code using Terraform. This presentation includes an introduction to Terraform, a discussion of how to manage Terraform state, how to use Terraform modules, an overview of best practices (e.g. isolation, versioning, loops, if-statements), and a list of gotchas to look out for.
For a written and more in-depth version of this presentation, check out the "Comprehensive Guide to Terraform" blog post series: https://blog.gruntwork.io/a-comprehensive-guide-to-terraform-b3d32832baca
This document introduces infrastructure as code (IaC) using Terraform and provides examples of deploying infrastructure on AWS including:
- A single EC2 instance
- A single web server
- A cluster of web servers using an Auto Scaling Group
- Adding a load balancer using an Elastic Load Balancer
It also discusses Terraform concepts and syntax like variables, resources, outputs, and interpolation. The target audience is people who deploy infrastructure on AWS or other clouds.
The document provides an overview of Terraform and discusses why it was chosen over other infrastructure as code tools. It outlines an agenda covering Terraform installation, configuration, and use of data sources and resources to build example infrastructure including a VCN, internet gateway, subnets, and how to taint and destroy resources. The live demo then walks through setting up Terraform and using it to provision example OCI resources.
Building infrastructure as code using Terraform - DevOps KrakowAnton Babenko
This document provides an overview of a DevOps meetup on building infrastructure as code using Terraform. The agenda includes Terraform basics, frequent questions, and problems. The presenter then discusses Terraform modules, tools, and solutions. He addresses common questions like secrets handling and integration with other tools. Finally, he solicits questions from the audience on Terraform use cases and challenges.
This document discusses Terraform, an open source tool for building, changing, and versioning infrastructure safely and efficiently. It provides declarative configuration files to manage networks, virtual machines, containers, and other infrastructure resources. The document introduces Terraform and how it works, provides examples of Terraform code and its output, and offers best practices for using Terraform including separating infrastructure code from application code, using modules, and managing state. Terraform allows infrastructure to be treated as code, provides a faster development cycle than other tools like CloudFormation, and helps promote a devOps culture.
This document discusses infrastructure as code and the HashiCorp ecosystem. Infrastructure as code allows users to define and provision infrastructure through code rather than manual configuration. It can be used to launch, create, change, and downscale infrastructure based on configuration files. Tools like Terraform allow showing what changes will occur before applying them through files like main.tf and variables.tf. Terraform is part of the broader HashiCorp ecosystem of tools.
Terraform is an open source tool for building, changing, and versioning infrastructure safely and efficiently. It allows users to define and provision a datacenter infrastructure using a high-level configuration language known as HashiCorp Configuration Language. Some key features of Terraform include supporting multiple cloud providers and services, being declarative and reproducible, and maintaining infrastructure as code with immutable infrastructure. It works by defining configuration files that specify what resources need to be created. The configuration is written in HCL. Terraform uses these files to create and manage infrastructure resources like VMs, network, storage, containers and more across multiple cloud platforms.
A comprehensive walkthrough of how to manage infrastructure-as-code using Terraform. This presentation includes an introduction to Terraform, a discussion of how to manage Terraform state, how to use Terraform modules, an overview of best practices (e.g. isolation, versioning, loops, if-statements), and a list of gotchas to look out for.
For a written and more in-depth version of this presentation, check out the "Comprehensive Guide to Terraform" blog post series: https://blog.gruntwork.io/a-comprehensive-guide-to-terraform-b3d32832baca
This document introduces infrastructure as code (IaC) using Terraform and provides examples of deploying infrastructure on AWS including:
- A single EC2 instance
- A single web server
- A cluster of web servers using an Auto Scaling Group
- Adding a load balancer using an Elastic Load Balancer
It also discusses Terraform concepts and syntax like variables, resources, outputs, and interpolation. The target audience is people who deploy infrastructure on AWS or other clouds.
The document provides an overview of Terraform and discusses why it was chosen over other infrastructure as code tools. It outlines an agenda covering Terraform installation, configuration, and use of data sources and resources to build example infrastructure including a VCN, internet gateway, subnets, and how to taint and destroy resources. The live demo then walks through setting up Terraform and using it to provision example OCI resources.
Building infrastructure as code using Terraform - DevOps KrakowAnton Babenko
This document provides an overview of a DevOps meetup on building infrastructure as code using Terraform. The agenda includes Terraform basics, frequent questions, and problems. The presenter then discusses Terraform modules, tools, and solutions. He addresses common questions like secrets handling and integration with other tools. Finally, he solicits questions from the audience on Terraform use cases and challenges.
This document discusses Terraform, an open source tool for building, changing, and versioning infrastructure safely and efficiently. It provides declarative configuration files to manage networks, virtual machines, containers, and other infrastructure resources. The document introduces Terraform and how it works, provides examples of Terraform code and its output, and offers best practices for using Terraform including separating infrastructure code from application code, using modules, and managing state. Terraform allows infrastructure to be treated as code, provides a faster development cycle than other tools like CloudFormation, and helps promote a devOps culture.
This document discusses infrastructure as code and the HashiCorp ecosystem. Infrastructure as code allows users to define and provision infrastructure through code rather than manual configuration. It can be used to launch, create, change, and downscale infrastructure based on configuration files. Tools like Terraform allow showing what changes will occur before applying them through files like main.tf and variables.tf. Terraform is part of the broader HashiCorp ecosystem of tools.
Terraform is an open source tool for building, changing, and versioning infrastructure safely and efficiently. It allows users to define and provision a datacenter infrastructure using a high-level configuration language known as HashiCorp Configuration Language. Some key features of Terraform include supporting multiple cloud providers and services, being declarative and reproducible, and maintaining infrastructure as code with immutable infrastructure. It works by defining configuration files that specify what resources need to be created. The configuration is written in HCL. Terraform uses these files to create and manage infrastructure resources like VMs, network, storage, containers and more across multiple cloud platforms.
This document provides an overview and introduction to Terraform, including:
- Terraform is an open-source tool for building, changing, and versioning infrastructure safely and efficiently across multiple cloud providers and custom solutions.
- It discusses how Terraform compares to other tools like CloudFormation, Puppet, Chef, etc. and highlights some key Terraform facts like its versioning, community, and issue tracking on GitHub.
- The document provides instructions on getting started with Terraform by installing it and describes some common Terraform commands like apply, plan, and refresh.
- Finally, it briefly outlines some key Terraform features and example use cases like cloud app setup, multi
This document discusses the infrastructure provisioning tool Terraform. It can be used to provision resources like EC2 instances, storage, and DNS entries across multiple cloud providers. Terraform uses configuration files to define what infrastructure should be created and maintains state files to track changes. It generates execution plans to determine what changes need to be made and allows applying those changes to create, update or destroy infrastructure.
This document summarizes a meetup about infrastructure as code. It discusses the differences between treating infrastructure as "pets" versus "cattle", where pets are cared for individually and cattle are treated as disposable. When infrastructure is coded declaratively using tools like Terraform, the infrastructure can be version controlled, updated continuously, and rolled back like code. The meetup demonstrated setting up infrastructure on Azure using Terraform to define resources like virtual machines in code. Advanced techniques like storing state remotely and using modules were also discussed.
This document discusses Terraform, an open-source infrastructure as code tool. It begins by explaining how infrastructure can be defined and managed as code through services that have APIs. It then provides an overview of Terraform, including its core concepts of providers, resources, and data sources. The document demonstrates Terraform's declarative configuration syntax and process of planning and applying changes. It also covers features like modules, state management, data sources, and developing custom plugins.
The document discusses infrastructure as code best practices on AWS. It provides an overview of using AWS CloudFormation to define infrastructure in code. AWS CloudFormation allows infrastructure to be provisioned in an automated and repeatable way using templates that are version controlled like code. The document outlines the key components of a CloudFormation template including parameters, mappings, resources, outputs and conditionals. It also discusses using CloudFormation to bootstrap applications on EC2 instances.
Infrastructure-as-Code (IaC) using TerraformAdin Ermie
Learn the benefits of Infrastructure-as-Code (IaC), what Terraform is and why people love it, along with a breakdown of the basics (including live demo deployments). Then wrap up with a comparison of Azure Resource Manager (ARM) templates versus Terraform, consider some best practices, and walk away with some key resources in your Terraform learning adventure.
This document provides an overview of Terraform including its key features and how to install, configure, and use Terraform to deploy infrastructure on AWS. It covers topics such as creating EC2 instances and other AWS resources with Terraform, using variables, outputs, and provisioners, implementing modules and workspaces, and managing the Terraform state.
These are the slides for a talk/workshop delivered to the Cloud Native Wales user group (@CloudNativeWal) on 2019-01-10.
In these slides, we go over some principles of gitops and a hands on session to apply these to manage a microservice.
You can find out more about GitOps online https://www.weave.works/technologies/gitops/
Terraform is a tool for building, changing, and version controlling infrastructure safely and efficiently. It allows users to define and provision resources through code rather than manual configuration. Key concepts include variables, outputs, providers that interface with cloud platforms, reusable modules, and managing infrastructure through commands like plan, apply, and destroy. The presentation demonstrated Terraform's capabilities with a live demo and provided additional resources for learning more.
Terraform is a tool for provisioning and managing infrastructure safely and efficiently. It allows infrastructure to be defined as code so it can be versioned, shared, and treated like any other code. Key features include showing execution plans so changes are not a surprise, building a graph of dependencies to parallelize changes, and enabling complex automated changesets to infrastructure. Operators use Terraform for the benefits of infrastructure as code, managing multiple cloud platforms through a single workflow, and providing self-service infrastructure through reusable modules.
Are you looking to automate your infrastructure but not sure where to start? View this presentation on ‘Getting started with Infrastructure as code’ to learn how to leverage IaC to deploy and manage resources on Azure. You will learn:
• Introduction to IaC
• Develop a simple IaC using Terraform
• Manage the deployed infrastructure using Terraform
View webinar recording at https://www.winwire.com/webinars
Terraform is a tool used by Atlassian for building, changing, and versioning infrastructure safely and efficiently. It manages both popular cloud services and in-house solutions through its infrastructure-as-code approach. Atlassian uses Terraform for its build pipelines via a Python wrapper and fork of Terraform, taking advantage of its modular and extendable design as well as its large, active community for support.
In this hands-on workshop, we'll explore how to deploy resources to azure using terraform. First we'll peek into the basics of terraform (HCL language, CLI, providers, provisioners, modules, plans, state files etc).
Then in our hand-on exercise, we'll author terraform scripts to deploy virtual networks, virtual machines and app services to azure. Finally we'll walk through some azure tooling & integrations for terraform (azure cloud shell, hosted images in azure devops, azure marketplace images, VSCode extensions etc).
Author: Mithun Shanbhag
MeetUp Monitoring with Prometheus and Grafana (September 2018)Lucas Jellema
This presentation introduces the concept of monitoring - focusing on why and how and finally on the tools to use. It introduces Prometheus (metrics gathering, processing, alerting), application instrumentation and Prometheus exporters and finally it introduces Grafana as a common companion for dashboarding, alerting and notifications. This presentations also introduces the handson workshop - for which materials are available from https://github.com/lucasjellema/monitoring-workshop-prometheus-grafana
This document provides an introduction and overview of Terraform, including what it is, why it is used, common use cases, and how it compares to CloudFormation. It then demonstrates hands-on examples of using Terraform to provision AWS resources like S3 buckets, EC2 instances, and CloudFront distributions. The workflow of initializing, planning, and applying changes with Terraform is also outlined.
Using HashiCorp’s Terraform to build your infrastructure on AWS - Pop-up Loft...Amazon Web Services
Using Terraform to automate your infrastructure on AWS. What is Terraform and how is it different from Ansible. How to control cloud deployments using Terraform.
This document provides an overview of Terraform, an open-source infrastructure as code tool. It discusses Terraform's goals of providing a unified view of infrastructure, composing multiple tiers of infrastructure from IaaS to PaaS to SaaS, and safely changing infrastructure over time with one workflow. Key features highlighted include being open source, using infrastructure as code, resource providers that interface with cloud APIs, and the plan and apply workflow. The document also covers topics like collaboration and version history in Terraform Enterprise, file examples, the plan and apply commands, resource providers, and new features in recent Terraform versions like destroy provisioners, remote backends, state locking, and state environments.
This document provides an overview and introduction to Terraform, including:
- Terraform is an open-source tool for building, changing, and versioning infrastructure safely and efficiently across multiple cloud providers and custom solutions.
- It discusses how Terraform compares to other tools like CloudFormation, Puppet, Chef, etc. and highlights some key Terraform facts like its versioning, community, and issue tracking on GitHub.
- The document provides instructions on getting started with Terraform by installing it and describes some common Terraform commands like apply, plan, and refresh.
- Finally, it briefly outlines some key Terraform features and example use cases like cloud app setup, multi
This document discusses the infrastructure provisioning tool Terraform. It can be used to provision resources like EC2 instances, storage, and DNS entries across multiple cloud providers. Terraform uses configuration files to define what infrastructure should be created and maintains state files to track changes. It generates execution plans to determine what changes need to be made and allows applying those changes to create, update or destroy infrastructure.
This document summarizes a meetup about infrastructure as code. It discusses the differences between treating infrastructure as "pets" versus "cattle", where pets are cared for individually and cattle are treated as disposable. When infrastructure is coded declaratively using tools like Terraform, the infrastructure can be version controlled, updated continuously, and rolled back like code. The meetup demonstrated setting up infrastructure on Azure using Terraform to define resources like virtual machines in code. Advanced techniques like storing state remotely and using modules were also discussed.
This document discusses Terraform, an open-source infrastructure as code tool. It begins by explaining how infrastructure can be defined and managed as code through services that have APIs. It then provides an overview of Terraform, including its core concepts of providers, resources, and data sources. The document demonstrates Terraform's declarative configuration syntax and process of planning and applying changes. It also covers features like modules, state management, data sources, and developing custom plugins.
The document discusses infrastructure as code best practices on AWS. It provides an overview of using AWS CloudFormation to define infrastructure in code. AWS CloudFormation allows infrastructure to be provisioned in an automated and repeatable way using templates that are version controlled like code. The document outlines the key components of a CloudFormation template including parameters, mappings, resources, outputs and conditionals. It also discusses using CloudFormation to bootstrap applications on EC2 instances.
Infrastructure-as-Code (IaC) using TerraformAdin Ermie
Learn the benefits of Infrastructure-as-Code (IaC), what Terraform is and why people love it, along with a breakdown of the basics (including live demo deployments). Then wrap up with a comparison of Azure Resource Manager (ARM) templates versus Terraform, consider some best practices, and walk away with some key resources in your Terraform learning adventure.
This document provides an overview of Terraform including its key features and how to install, configure, and use Terraform to deploy infrastructure on AWS. It covers topics such as creating EC2 instances and other AWS resources with Terraform, using variables, outputs, and provisioners, implementing modules and workspaces, and managing the Terraform state.
These are the slides for a talk/workshop delivered to the Cloud Native Wales user group (@CloudNativeWal) on 2019-01-10.
In these slides, we go over some principles of gitops and a hands on session to apply these to manage a microservice.
You can find out more about GitOps online https://www.weave.works/technologies/gitops/
Terraform is a tool for building, changing, and version controlling infrastructure safely and efficiently. It allows users to define and provision resources through code rather than manual configuration. Key concepts include variables, outputs, providers that interface with cloud platforms, reusable modules, and managing infrastructure through commands like plan, apply, and destroy. The presentation demonstrated Terraform's capabilities with a live demo and provided additional resources for learning more.
Terraform is a tool for provisioning and managing infrastructure safely and efficiently. It allows infrastructure to be defined as code so it can be versioned, shared, and treated like any other code. Key features include showing execution plans so changes are not a surprise, building a graph of dependencies to parallelize changes, and enabling complex automated changesets to infrastructure. Operators use Terraform for the benefits of infrastructure as code, managing multiple cloud platforms through a single workflow, and providing self-service infrastructure through reusable modules.
Are you looking to automate your infrastructure but not sure where to start? View this presentation on ‘Getting started with Infrastructure as code’ to learn how to leverage IaC to deploy and manage resources on Azure. You will learn:
• Introduction to IaC
• Develop a simple IaC using Terraform
• Manage the deployed infrastructure using Terraform
View webinar recording at https://www.winwire.com/webinars
Terraform is a tool used by Atlassian for building, changing, and versioning infrastructure safely and efficiently. It manages both popular cloud services and in-house solutions through its infrastructure-as-code approach. Atlassian uses Terraform for its build pipelines via a Python wrapper and fork of Terraform, taking advantage of its modular and extendable design as well as its large, active community for support.
In this hands-on workshop, we'll explore how to deploy resources to azure using terraform. First we'll peek into the basics of terraform (HCL language, CLI, providers, provisioners, modules, plans, state files etc).
Then in our hand-on exercise, we'll author terraform scripts to deploy virtual networks, virtual machines and app services to azure. Finally we'll walk through some azure tooling & integrations for terraform (azure cloud shell, hosted images in azure devops, azure marketplace images, VSCode extensions etc).
Author: Mithun Shanbhag
MeetUp Monitoring with Prometheus and Grafana (September 2018)Lucas Jellema
This presentation introduces the concept of monitoring - focusing on why and how and finally on the tools to use. It introduces Prometheus (metrics gathering, processing, alerting), application instrumentation and Prometheus exporters and finally it introduces Grafana as a common companion for dashboarding, alerting and notifications. This presentations also introduces the handson workshop - for which materials are available from https://github.com/lucasjellema/monitoring-workshop-prometheus-grafana
This document provides an introduction and overview of Terraform, including what it is, why it is used, common use cases, and how it compares to CloudFormation. It then demonstrates hands-on examples of using Terraform to provision AWS resources like S3 buckets, EC2 instances, and CloudFront distributions. The workflow of initializing, planning, and applying changes with Terraform is also outlined.
Using HashiCorp’s Terraform to build your infrastructure on AWS - Pop-up Loft...Amazon Web Services
Using Terraform to automate your infrastructure on AWS. What is Terraform and how is it different from Ansible. How to control cloud deployments using Terraform.
This document provides an overview of Terraform, an open-source infrastructure as code tool. It discusses Terraform's goals of providing a unified view of infrastructure, composing multiple tiers of infrastructure from IaaS to PaaS to SaaS, and safely changing infrastructure over time with one workflow. Key features highlighted include being open source, using infrastructure as code, resource providers that interface with cloud APIs, and the plan and apply workflow. The document also covers topics like collaboration and version history in Terraform Enterprise, file examples, the plan and apply commands, resource providers, and new features in recent Terraform versions like destroy provisioners, remote backends, state locking, and state environments.
Slides form Config Management Camp, looking at how you can take a collaborative GitFlow approach to Terraform using Remote State, Modules and Dynamically Generated Credentials using Vault
My talk at FullStackFest, 4.9.2017. Become more familiar with managing infrastructure using Terraform, Packer and deployment pipeline. Code repository - https://github.com/antonbabenko/terraform-deployment-pipeline-talk
Helm is a package manager for Kubernetes that makes it easier to deploy and manage Kubernetes applications. It allows you to define, install and upgrade Kubernetes applications known as charts. Helm uses templates to define the characteristics of Kubernetes resources and allows parameterization of things like container images, resource requests and limits. The Helm client interacts with Tiller, the server-side component installed in the Kubernetes cluster, to install and manage releases of charts.
Abstract: At DataRobot we deal with automation challenges every day. This talk will give insight into how we use Python tools built around Ansible, Terraform, and Docker to solve real-world problems in infrastructure and automation.
Best Practices of Infrastructure as Code with TerraformDevOps.com
When your organization is moving to cloud, the infrastructure layer transitions from running dedicated servers at limited scale to a dynamic environment, where you can easily adjust to growing demand by spinning up thousands of servers and scaling them down when not in use.
The future of DevOps is infrastructure as code. Infrastructure as code supports the growth of infrastructure and provisioning requests. It treats infrastructure as software: code that can be re-used, tested, automated and version controlled. HashiCorp Terraform adopts infrastructure as code throughout its tool to prevent configuration drift, manage immutable infrastructure and much more!
Join this webinar to learn why Infrastructure as Code is the answer to managing large scale, distributed systems and service-oriented architectures. We will cover key use cases, a demo of how to use Infrastructure as Code to provision your infrastructure and more:
Agenda:
Intro to Infrastructure as Code: Challenges & Use cases
Writing Infrastructure as Code with Terraform
Collaborating with Teams on Infrastructure
The recent launch of the Docker Init command has significantly simplified the process of generating Dockerfiles and Docker Compose templates for containerized applications. This presentation aims to explore the evolution of Docker deployment resources generation process, comparing its approach prior to the Docker Init command release and discussing the way forward. Before the introduction of the Docker Init command, I've been delivering some projects like the "alfresco-docker-installer"[1], which provides custom scripts and configurations to streamline the process of deploying Alfresco in Docker containers. These kinds of projects use tools like Yeoman or raw Python. There are some differences between a Docker Template for a technology (Go, Python, Node or Rust) and a Docker Template for a product (like Alfresco) that may be covered when generating automatic deployment resources. This presentation will delve into the methodologies employed before the Docker Init command:
Custom Dockerfile Extension
Compose Template for a complete product deployment, including a set of services like the database, content repository, search engine, or web application
Configuration Management, including techniques such as environment variable injection, externalized configuration files, and configuration overrides
Following the release of the Docker Init command, this presentation will provide insights into the possibilities and advantages it brings to complex products Docker deployment process. A PoC of a Docker Plugin, including this product-oriented approach for docker init, will be demoed live. >> Note that the Open Source Alfresco product is used only to explain the concepts of building a Docker Compose generator with a real example.
This document discusses the 4 stages of adopting Terraform at an organization from a small startup to a large enterprise. Stage 1 is manual usage with single environments. Stage 2 introduces semi-automated usage with Terraform configuration. Stage 3 focuses on organizational adoption with workspaces, modules, and version control. Stage 4 discusses integration with version control systems, team permissions, and automated "Run Terraform for me" workflows using Terraform Enterprise.
This presentation was given at the Boston Django meetup on November 16, and surveyed several leading PaaS providers including Stackato, Dotcloud, OpenShift and Heroku.
For each PaaS provider, I documented the steps necessary to deploy Mezzanine, a popular Django-based CMS and blogging platform.
At the end of the presentation, I do a wrap-up of the different providers and provide a comparison matrix showing which providers have which features. This matrix is likely to go out-of-date quickly because these providers are adding new features all the time.
Hashidays London 2017 - Evolving your Infrastructure with Terraform By Nicki ...OpenCredo
So you are using Terraform to manage your infrastructure, fantastic! However have you ever accidentally destroyed your production setup? Or managed to change some part of your infrastructure you were not expecting to?
This talk explores some common pain points experienced by users on different parts of their Terraform journey and provides insight into how you can evolve your Terraform setup to manage and address these challenges.
OSDC 2015: Mitchell Hashimoto | Automating the Modern Datacenter, Development...NETWAYS
Physical, virtual, containers. Public cloud, private cloud, hybrid cloud. IaaS, PaaS, SaaS. These are the choices that we're faced with when architecting a datacenter of today. And the choice is not one or the other; it is often a combination of many of these. How do we remain in control of our datacenters? How do we deploy and configure software, manage change across disparate systems, and enforce policy/security? How do we do this in a way that operations engineers and developers alike can rejoice in the processes and workflow?
In this talk, I will discuss the problems faced by the modern datacenter, and how a set of open source tools including Vagrant, Packer, Consul, and Terraform can be used to tame the rising complexity curve and provide solutions for these problems.
Infrastructure-as-Code (IaC) Using Terraform (Advanced Edition)Adin Ermie
In this new presentation, we will cover advanced Terraform topics (full-on DevOps). We will compare the deployment of Terraform using Azure DevOps, GitHub/GitHub Actions, and Terraform Cloud. We wrap everything up with some key takeaway learning resources in your Terraform learning adventure.
NOTE: A recording of this presenting is available here: https://www.youtube.com/watch?v=fJ8_ZbOIdto&t=5574s
Docker San Francisco Meetup April 2015 - The Docker Orchestration Ecosystem o...Patrick Chanezon
The document discusses the Docker ecosystem including:
- The history and components of Docker including the Docker Engine, Hub, Machine, Compose, and Swarm.
- How Docker provides isolation using Linux kernel features like namespaces and cgroups.
- Other projects in the Docker ecosystem like Weave, Flocker, and Powerstrip.
- Orchestration tools like Docker Swarm and Kubernetes that manage Docker containers across multiple hosts.
- Platforms that are built on Docker like CoreOS, Deis, Cloud Foundry, and IBM Bluemix.
**Watch the full webinar at https://codefresh.io/events/terraform-gitops-codefresh/
Today we write "Infrastructure as Code" and even "Pipelines as Code", so let's start treating our "code as code" and practice CI/CD with GitOps! In this talk, we'll show you how we build and deploy applications with Terraform using GitOps and Codefresh. Cloud Posse is a Terraform power user that has developed over 130 Terraform modules which are free and open source. We'll share how we handle automation with security while making the process easy for engineers.
DevOpsDays Tel Aviv DEC 2022 | Building A Cloud-Native Platform Brick by Bric...Haggai Philip Zagury
The overwhelming growth of technologies in the Cloud Native foundation overtook our toolbox and completely changed (well, really enhanced) the Developer Experience.
In this talk, I will try to provide my personal journey from the "Operator to Developer's chair" and the practices which helped me along my journey as a Cloud-Native Dev ;)
As kubernetes matures into the standard de facto Operating System of the Cloud, in addition to a shift in deployment methods such as GitOps and Continuous delivery paradigms - automation of security is one of our main concerns
The security policy alignment starts from the CI/CD pipelines, and continues to runtime security solutions.
In this talk, we will introduce a few solutions built around kubernetes from the early stages of the CI/CD pipelines through runtime application security models which we are seeing from many companies on the security vertical.
Scanning tools [ static ]
Runtime [ pro-active, permissive ]
Few words about Haggai:
Haggai is a DevOps Architect, Group & TechLead at Tikal, for the past 15 years Haggai’s has provided solutions in the domains of Ci/CD, Configuration Management, and Security.
And in the past, ~4 years specialized in Kubernetes-based deployment schemes.
This document discusses building an internal developer platform to improve the developer experience. It suggests that a platform provides self-service tools for onboarding, documentation, best practices, credentials, and understanding available services. A platform engineer builds and maintains the developer portal and tools. Successful companies like Spotify use platforms like Backstage to standardize processes and resources for developers across teams and clouds. The talk encourages building an incremental, self-service platform to streamline development.
This document discusses improving the developer experience through GitOps and ArgoCD. It recommends building developer self-service tools for cloud resources and Kubernetes to reduce frustration. Example GitLab CI/CD pipelines are shown that handle releases, deployments to ECR, and patching apps in an ArgoCD repository to sync changes. The goal is to create faster feedback loops through Git operations and automation to motivate developers.
Ever since the “CloudNative revolution” took over our development environment (devenv), we have never been more challenged (or more excited). With Kubernetes, Docker (Containerd) & many other microservice-related technologies, we have a handful of technologies to master before we write the first line of code.
The document discusses GitOps and continuous infrastructure using Terraform. It describes how GitOps ensures that every change is driven by a change in source control, with the entire system described declaratively and the desired state versioned in Git. Approved changes can be automatically applied. Software agents ensure correctness and alert on divergence. The presenter then discusses their journey using Terraform over 5 years for various use cases and integrations. Common workflows for GitOps using Terraform Cloud, GitHub Actions, and GitLab Runner are presented.
The document discusses modern authentication practices including:
- Early authentication methods like LDAP before cloud services and the issues they posed.
- The evolution of standards like OAuth2.0, JSON Web Tokens, and OpenID Connect to provide authorization and identity in cloud applications.
- Key concepts in OAuth2.0 flows and tokens as well as behind the scenes components like client IDs and secrets.
- Similarities and differences between OAuth2.0, OpenID Connect, and SAML protocols.
This document provides an overview of Linux and its origins and architecture. It discusses how Unix originally dominated the commercial market in the 1970s-1990s. It then describes the development of key free and open-source tools and standards like GNU, POSIX, and Linux itself. It explains the standard Linux directory structure and process management. It also summarizes Linux's architecture principles like treating everything as a file and its evolution from physical installations to containers and cloud-based deployments.
This document discusses authentication and authorization for web applications. It introduces AuthExperience as a set of sessions that takes participants from theory to practice on these topics. The sessions are designed as walkthroughs that explain authentication fundamentals, methods and standards, and authentication and authorization processes. The goal is to help participants understand identity and access management and prepare for developing distributed systems that require authentication and authorization.
Kubernetes is much more than just a container orchestration platform … alongside The Cloud Native Landscape Kubernetes is the equivalent to Linux's kernel with an ecosystem of apps/util which enrich it.
Basic principles of 2nd half thinking in microservices and how "sidecar" systems need to be part of the design considering how this new microservice is going to affect its eco-system.
Logging is a great example and we demonstrate how to plan one, without missing the basics ...
Haggai Philip Zagury gave a presentation about planning data pipelines at scale. He discussed challenges like unpredictable scale, increasing complexity as services grow, and high network traffic from logs. His proposed solutions included using managed cloud services to reduce complexity, optimizing data storage for read/write performance, using multi-tenancy to track costs, and leveraging container orchestration tools like Kubernetes to simplify management of compute resources. He also advocated for measuring performance and costs to continuously improve efficiency.
Chaos Engineering is the discipline of experimenting on a distributed system in order to build confidence in the system’s capability to withstand turbulent conditions in production.
Almost 3 years with Kubernetes and some "war stories", we will take the top-down approach to kubernetes and take a glimpse of the bottom-up and where we could customize it.
The document discusses continuous integration and delivery for machine learning models. It describes wrapping machine learning code into Docker containers to allow for parameterized training. It also discusses deploying models using Kubernetes operators and packaging models as services to run on customer infrastructure for training and serving. The goal is to establish best practices for continuous training, testing, and deployment of machine learning models.
A short introduction to challenges of managing Machine Learning technologies and pipelines / workflows.
Finally see how Kubeflow fits into the mix as a real Multi-Cloud game changer.
The use of serverless architecture has very quickly become an accepted approach for organizations deploying cloud applications, with a plethora of choices available for deployment.
Even traditionally conservative organizations are making partial use of some serverless technologies.
Most of the discussion goes to Functions as a Service (e.g., AWS Lambda, Google Cloud Functions, Azure Functions) while the appropriate patterns for use are still emerging.
The document discusses introducing modern monitoring techniques using Prometheus. It covers defining metrics and alerts, implementing Prometheus and exporters, designing dashboards and alerts, and configuring alert routing and templates. The goal is to improve on traditional monitoring approaches by implementing application-level metrics collection and monitoring multiple dimensions of metrics for better visibility.
This document discusses Git internals and provides examples of how Git stores files and commits as objects in a directed acyclic graph (DAG). It explains that commits point to trees, which point to blobs containing file contents or other trees representing subdirectories. Branches and tags are explained as references to commit objects. Examples are given of branching, merging, tagging, and how remote tracking references map to repositories on remote servers.
This document discusses concepts and best practices related to automation, continuous integration (CI), and continuous deployment (CD). It addresses key questions like how, what, who, when regarding automation and describes the roles of development, QA, and operations in an automated process. It provides examples of implementing CI and CD through tools like Hudson, Maven, Nexus, and virtual machines. The goal is to illustrate how to set up an automated build, test, and deployment pipeline for software.
Software Engineering, Software Consulting, Tech Lead, Spring Boot, Spring Cloud, Spring Core, Spring JDBC, Spring Transaction, Spring MVC, OpenShift Cloud Platform, Kafka, REST, SOAP, LLD & HLD.
What is Augmented Reality Image Trackingpavan998932
Augmented Reality (AR) Image Tracking is a technology that enables AR applications to recognize and track images in the real world, overlaying digital content onto them. This enhances the user's interaction with their environment by providing additional information and interactive elements directly tied to physical images.
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptxrickgrimesss22
Discover the essential features to incorporate in your Winzo clone app to boost business growth, enhance user engagement, and drive revenue. Learn how to create a compelling gaming experience that stands out in the competitive market.
E-commerce Development Services- Hornet DynamicsHornet Dynamics
For any business hoping to succeed in the digital age, having a strong online presence is crucial. We offer Ecommerce Development Services that are customized according to your business requirements and client preferences, enabling you to create a dynamic, safe, and user-friendly online store.
DDS Security Version 1.2 was adopted in 2024. This revision strengthens support for long runnings systems adding new cryptographic algorithms, certificate revocation, and hardness against DoS attacks.
UI5con 2024 - Boost Your Development Experience with UI5 Tooling ExtensionsPeter Muessig
The UI5 tooling is the development and build tooling of UI5. It is built in a modular and extensible way so that it can be easily extended by your needs. This session will showcase various tooling extensions which can boost your development experience by far so that you can really work offline, transpile your code in your project to use even newer versions of EcmaScript (than 2022 which is supported right now by the UI5 tooling), consume any npm package of your choice in your project, using different kind of proxies, and even stitching UI5 projects during development together to mimic your target environment.
Introducing Crescat - Event Management Software for Venues, Festivals and Eve...Crescat
Crescat is industry-trusted event management software, built by event professionals for event professionals. Founded in 2017, we have three key products tailored for the live event industry.
Crescat Event for concert promoters and event agencies. Crescat Venue for music venues, conference centers, wedding venues, concert halls and more. And Crescat Festival for festivals, conferences and complex events.
With a wide range of popular features such as event scheduling, shift management, volunteer and crew coordination, artist booking and much more, Crescat is designed for customisation and ease-of-use.
Over 125,000 events have been planned in Crescat and with hundreds of customers of all shapes and sizes, from boutique event agencies through to international concert promoters, Crescat is rigged for success. What's more, we highly value feedback from our users and we are constantly improving our software with updates, new features and improvements.
If you plan events, run a venue or produce festivals and you're looking for ways to make your life easier, then we have a solution for you. Try our software for free or schedule a no-obligation demo with one of our product specialists today at crescat.io
Revolutionizing Visual Effects Mastering AI Face Swaps.pdfUndress Baby
The quest for the best AI face swap solution is marked by an amalgamation of technological prowess and artistic finesse, where cutting-edge algorithms seamlessly replace faces in images or videos with striking realism. Leveraging advanced deep learning techniques, the best AI face swap tools meticulously analyze facial features, lighting conditions, and expressions to execute flawless transformations, ensuring natural-looking results that blur the line between reality and illusion, captivating users with their ingenuity and sophistication.
Web:- https://undressbaby.com/
Artificia Intellicence and XPath Extension FunctionsOctavian Nadolu
The purpose of this presentation is to provide an overview of how you can use AI from XSLT, XQuery, Schematron, or XML Refactoring operations, the potential benefits of using AI, and some of the challenges we face.
GraphSummit Paris - The art of the possible with Graph TechnologyNeo4j
Sudhir Hasbe, Chief Product Officer, Neo4j
Join us as we explore breakthrough innovations enabled by interconnected data and AI. Discover firsthand how organizations use relationships in data to uncover contextual insights and solve our most pressing challenges – from optimizing supply chains, detecting fraud, and improving customer experiences to accelerating drug discoveries.
Microservice Teams - How the cloud changes the way we workSven Peters
A lot of technical challenges and complexity come with building a cloud-native and distributed architecture. The way we develop backend software has fundamentally changed in the last ten years. Managing a microservices architecture demands a lot of us to ensure observability and operational resiliency. But did you also change the way you run your development teams?
Sven will talk about Atlassian’s journey from a monolith to a multi-tenanted architecture and how it affected the way the engineering teams work. You will learn how we shifted to service ownership, moved to more autonomous teams (and its challenges), and established platform and enablement teams.
Do you want Software for your Business? Visit Deuglo
Deuglo has top Software Developers in India. They are experts in software development and help design and create custom Software solutions.
Deuglo follows seven steps methods for delivering their services to their customers. They called it the Software development life cycle process (SDLC).
Requirement — Collecting the Requirements is the first Phase in the SSLC process.
Feasibility Study — after completing the requirement process they move to the design phase.
Design — in this phase, they start designing the software.
Coding — when designing is completed, the developers start coding for the software.
Testing — in this phase when the coding of the software is done the testing team will start testing.
Installation — after completion of testing, the application opens to the live server and launches!
Maintenance — after completing the software development, customers start using the software.
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI AppGoogle
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
👉👉 Click Here To Get More Info 👇👇
https://sumonreview.com/ai-fusion-buddy-review
AI Fusion Buddy Review: Key Features
✅Create Stunning AI App Suite Fully Powered By Google's Latest AI technology, Gemini
✅Use Gemini to Build high-converting Converting Sales Video Scripts, ad copies, Trending Articles, blogs, etc.100% unique!
✅Create Ultra-HD graphics with a single keyword or phrase that commands 10x eyeballs!
✅Fully automated AI articles bulk generation!
✅Auto-post or schedule stunning AI content across all your accounts at once—WordPress, Facebook, LinkedIn, Blogger, and more.
✅With one keyword or URL, generate complete websites, landing pages, and more…
✅Automatically create & sell AI content, graphics, websites, landing pages, & all that gets you paid non-stop 24*7.
✅Pre-built High-Converting 100+ website Templates and 2000+ graphic templates logos, banners, and thumbnail images in Trending Niches.
✅Say goodbye to wasting time logging into multiple Chat GPT & AI Apps once & for all!
✅Save over $5000 per year and kick out dependency on third parties completely!
✅Brand New App: Not available anywhere else!
✅ Beginner-friendly!
✅ZERO upfront cost or any extra expenses
✅Risk-Free: 30-Day Money-Back Guarantee!
✅Commercial License included!
See My Other Reviews Article:
(1) AI Genie Review: https://sumonreview.com/ai-genie-review
(2) SocioWave Review: https://sumonreview.com/sociowave-review
(3) AI Partner & Profit Review: https://sumonreview.com/ai-partner-profit-review
(4) AI Ebook Suite Review: https://sumonreview.com/ai-ebook-suite-review
#AIFusionBuddyReview,
#AIFusionBuddyFeatures,
#AIFusionBuddyPricing,
#AIFusionBuddyProsandCons,
#AIFusionBuddyTutorial,
#AIFusionBuddyUserExperience
#AIFusionBuddyforBeginners,
#AIFusionBuddyBenefits,
#AIFusionBuddyComparison,
#AIFusionBuddyInstallation,
#AIFusionBuddyRefundPolicy,
#AIFusionBuddyDemo,
#AIFusionBuddyMaintenanceFees,
#AIFusionBuddyNewbieFriendly,
#WhatIsAIFusionBuddy?,
#HowDoesAIFusionBuddyWorks
Enterprise Resource Planning System includes various modules that reduce any business's workload. Additionally, it organizes the workflows, which drives towards enhancing productivity. Here are a detailed explanation of the ERP modules. Going through the points will help you understand how the software is changing the work dynamics.
To know more details here: https://blogs.nyggs.com/nyggs/enterprise-resource-planning-erp-system-modules/
Need for Speed: Removing speed bumps from your Symfony projects ⚡️Łukasz Chruściel
No one wants their application to drag like a car stuck in the slow lane! Yet it’s all too common to encounter bumpy, pothole-filled solutions that slow the speed of any application. Symfony apps are not an exception.
In this talk, I will take you for a spin around the performance racetrack. We’ll explore common pitfalls - those hidden potholes on your application that can cause unexpected slowdowns. Learn how to spot these performance bumps early, and more importantly, how to navigate around them to keep your application running at top speed.
We will focus in particular on tuning your engine at the application level, making the right adjustments to ensure that your system responds like a well-oiled, high-performance race car.
Graspan: A Big Data System for Big Code AnalysisAftab Hussain
We built a disk-based parallel graph system, Graspan, that uses a novel edge-pair centric computation model to compute dynamic transitive closures on very large program graphs.
We implement context-sensitive pointer/alias and dataflow analyses on Graspan. An evaluation of these analyses on large codebases such as Linux shows that their Graspan implementations scale to millions of lines of code and are much simpler than their original implementations.
These analyses were used to augment the existing checkers; these augmented checkers found 132 new NULL pointer bugs and 1308 unnecessary NULL tests in Linux 4.4.0-rc5, PostgreSQL 8.3.9, and Apache httpd 2.2.18.
- Accepted in ASPLOS ‘17, Xi’an, China.
- Featured in the tutorial, Systemized Program Analyses: A Big Data Perspective on Static Analysis Scalability, ASPLOS ‘17.
- Invited for presentation at SoCal PLS ‘16.
- Invited for poster presentation at PLDI SRC ‘16.
2. WHO WE ARE ?
▸ Tikal helps ISV’s in Israel & abroad in their technological
challenges.
▸ Our Engineers are Fullstack Developers with expertise in
Android, DevOps, Java, JS, Python, ML
▸ We are passionate about technology and specialise in
OpenSource technologies.
▸ Our Tech and Group leaders help establish & enhance
existing software teams with innovative & creative
thinking. https://www.meetup.com/full-stack-developer-il/
3. FullStack Developers Israel
SELF INTRODUCTION
▸ My open thinking and open techniques
ideology is driven by Open Source
technologies and the collaborative manner
defining my M.O.
▸ My solution driven approach is strongly
based on hands-on and deep understanding
of Operating Systems, Applications stacks
and Software languages, Networking, Cloud
in general and today more an more Cloud
Native solutions.
▸ Technologies:
▸ Linux { just pick a flavour …}
▸ *Scripting
▸ Git
▸ Python/Go
▸ Cloud { public/private/hybrid }
▸ Docker
▸ Kubernetes
HAGGAI PHILIP ZAGURY - DEVOPS ARCHITECT AND GROUP TECH LEAD
4. FullStack Developers Israel
TERRAFORM | GETTING STARTED
INFRASTRUCTURE AS CODE
Infrastructure as code (IaC) is the process of managing and
provisioning computer data centers through machine-
readable definition files, rather than physical hardware
configuration or interactive configuration tools.[1] The IT
infrastructure meant by this comprises both physical
equipment such as bare-metal servers as well as virtual
machines and associated configuration resources. The
definitions may be in a version control system. It can use
either scripts or declarative definitions, rather than manual
processes, but the term is more often used to promote
declarative approaches.
9. FullStack Developers Israel
TERRAFORM | GETTING STARTED
PROVIDERS - AN EXAMPLE
1 # Configure the GitHub Provider
2 provider "github" {
3 token = "MyMicrosoftToken"
4 organization = "tikal.io"
5 }
6
7 # Add a user to the organization
8 resource "github_membership" "user" {
9 username = “terry.forman"
10 role = "member"
11 }
10. FullStack Developers Israel
TERRAFORM | GETTING STARTED
PROVIDER - ACCESS TOKEN
‣ Create an access token in
Github
‣ Configure the Github Provider
‣ Start managing groups, users,
tokens etc … provider "github" {
token = "MyMicrosoftToken"
organization = "tikal.io"
}
11. FullStack Developers Israel
TERRAFORM | GETTING STARTED
RESOURCES
1 # Configure the PagerDuty provider
2 provider "pagerduty" {
3 token = “MyPgToken"
4 }
5
6 # Create a PagerDuty team
7 resource "pagerduty_team" "engineering" {
8 name = "Engineering"
9 description = "All engineering"
10 }
11
12 # Create a PagerDuty user and add it to a team
13 resource "pagerduty_user" “tikal_io” {
14 name = “Haggai Philip Zagury"
15 email = “hagzag@tikalk.com”
16 teams = ["${pagerduty_team.engineering.id}"]
17 }
12. FullStack Developers Israel
TERRAFORM | GETTING STARTED
VARIABLES - DECLARE
1 variable "profile" {
2 type = "string"
3 description = “see ~/.aws/credentials file for details"
4 default = "my_company"
5 }
6
7 variable "region" {
8 type = "string"
9 description = "your default aws region"
10 default = "eu-west-1"
11 }
12
13 variable "general_tags" {
14 type = "map"
15
16 default = {
17 Name = "example.com"
18 Environment = "dev"
19 KubernetesCluster = "dev.example.com"
20 }
21 }
Best Practice to declare types
Best Practice to be descriptive
13. FullStack Developers Israel
TERRAFORM | GETTING STARTED
VARIABLES - USE
Use ${var.var_name}
1 resource "aws_route53_zone" "dev" {
2 name = "${var.env}.${var.domain_name}"
3
4 tags {
5 Environment = "dev"
6 }
7 }
14. FullStack Developers Israel
TERRAFORM | GETTING STARTED
OUTPUTS
terraform output “output_key”1 output "availability_zones" {
2 value = "${var.azs}"
3 }
More on this later on when we discuss modules and states !
TERRAFORM 1 TERRAFORM 2
availability_zones
hagzag@🌀dev 👉 terraform output availability_zones
eu-west-1a,
eu-west-1b,
eu-west-1c
15. FullStack Developers Israel
TERRAFORM | GETTING STARTED
TERRAFORM TEMPLATE (HCL)
‣ Instantiate / Activate Providers
‣ Define resources in terraform
templates
‣ Basically any file in a given
directory ending with .tf is treated
as a resource template definition
1 # Configure the PagerDuty provider
2 provider "pagerduty" {
3 token = “MyPgToken"
4 }
5
6 # Create a PagerDuty team
7 resource "pagerduty_team" "engineering" {
8 name = "Engineering"
9 description = "All engineering"
10 }
16. FullStack Developers Israel
TERRAFORM | GETTING STARTED
*.tf
‣ 1 FAT file with everything …
‣ main.tf for resources
‣ variables.tf for variables
‣ outputs.tf for outputs
‣ * provider.tf for providers …
‣ What ever suits your use case
17. FullStack Developers Israel
TERRAFORM | GETTING STARTED
HCL SYNTAX - HIGHLIGHTS
‣ Single line comments start with # or //
‣ Values are assigned with the syntax key = value (whitespace doesn't matter).
The value can be any primitive: a string, number, boolean, object, or list.
‣ Multi-line strings start with <<EOF at the end of a line, and end with EOF on its
own line.
‣ See full @ https://github.com/hashicorp/hcl#syntax
<<FOO
Any text
Would do …
FOO
22. FullStack Developers Israel
TERRAFORM | GETTING STARTED
INIT
The .git of your terraform code
Provider code
Terraform will not execute until it has all it’s dependencies locally
23. FullStack Developers Israel
TERRAFORM | GETTING STARTED
PLAN
‣ Preflight -> Show the
“Todo List” before you
apply it.
‣ Identify potential pitfalls /
imports …
30. FullStack Developers Israel
TERRAFORM | GETTING STARTED
IN OUR SCENARIO - BETWEEN “PLAN” & “DESTROY”
1 {
2 "version": 3,
3 "terraform_version": "0.11.7",
4 "serial": 3,
5 "lineage": "d6a3fc33-4869-c90f-6adb-c21947133250",
6 "modules": [
7 {
8 "path": [
9 "root"
10 ],
11 "outputs": {},
12 "resources": {
13 "github_membership.user": {
14 "type": "github_membership",
15 "depends_on": [],
16 "primary": {
17 "id": "tikalio:shellegtk",
18 "attributes": {
19 "id": "tikalio:shellegtk",
20 "role": "member",
21 "username": "shellegtk"
22 },
23 "meta": {},
24 "tainted": false
25 },
26 "deposed": [],
Our Infrastructure has a state and a version !
‣ By default terraform state is
stored locally under
terraform.tfstate file and can be
shared via git { but there are
better ways … }
31. FullStack Developers Israel
TERRAFORM | GETTING STARTED
SHARING STATE IN GIT - COULD WORK
‣ 1-3 developers with tight
communications -> git might do the
trick
‣ 2 or more it depends …
terraform.tfstate
terraform apply
git add terraform.tfstate
git commit “update state”
git push origin master
terraform plan
# oh wait …
git pull origin master
terraform plan
# phew that was close …
32. FullStack Developers Israel
TERRAFORM | GETTING STARTED
SHARING STATE IN S3, CONSUL, ATLAS - BETTER
‣ Instead of using git …
‣ terraform init -backend-
config=backend.tfvars
terraform.tfstate
terraform apply
# state is uploaded to the bucket as part of the execution
terraform plan
terraform refreshes the
state from the remote
store prior to execution
terraform.tfstate
1 bucket = "example-tfstate"
2 dynamodb_table = "TerraformStatelock"
3 key = "example.tfstate"
4 profile = “example"
5 region = "eu-west-1"
33. FullStack Developers Israel
TERRAFORM | GETTING STARTED
SHARING STATE IN S3, CONSUL, ATLAS - SAME PROBLEM
‣ Instead of using git …
‣ terraform init -backend-
config=backend.tfvars
terraform.tfstate
terraform.tfstate
1 bucket = "example-tfstate"
2 dynamodb_table = "TerraformStatelock"
3 key = "example.tfstate"
4 profile = “example"
5 region = "eu-west-1"
terraform apply
git add terraform.tfstate
git commit “update state”
git push origin master
terraform plan
# oh wait …
git pull origin master
terraform plan
# phew that was close …
34. FullStack Developers Israel
TERRAFORM | GETTING STARTED
STATE LOCK
‣ terraform plan [better]
terraform.tfstate
In memory terraform.tfstate
🌀bob 👉 terraform plan
Acquiring state lock. This may take a few moments...
Refreshing Terraform state in-memory prior to plan...
The refreshed state will be used to calculate this plan,
but will not be persisted to local or remote state
storage.
🌀bob 👉 terraform apply
Acquiring state lock. This may take a few moments...
🌀ann 👉 terraform plan
Acquiring state lock. This may take a few moments...
This plan is locked by user <bob ….>
User A cannot get / update the state until
User B had released the lock in the Dynamodb table
35. FullStack Developers Israel
TERRAFORM | GETTING STARTED
STATE + LOCK - CONSUL
‣ terraform plan [better]
terraform.tfstate
In memory terraform.tfstate
🌀bob 👉 terraform plan
Acquiring state lock. This may take a few moments...
Refreshing Terraform state in-memory prior to plan...
The refreshed state will be used to calculate this plan,
but will not be persisted to local or remote state
storage.
🌀bob 👉 terraform apply
Acquiring state lock. This may take a few moments...
🌀ann 👉 terraform plan
Acquiring state lock. This may take a few moments...
This plan is locked by user xxxx ….
User A cannot get / update the state until
User B had released the lock in the Dynamodb table
36. FullStack Developers Israel
TERRAFORM | GETTING STARTED
REFERENCING STATES
data.terraform_remote_state.mainstate.domain_name
What is the default domain_name ?
ask the state !
37. FullStack Developers Israel
TERRAFORM | GETTING STARTED
STATE AS DATA SOURCE
1 data "terraform_remote_state" "mainstate" {
2 backend = "s3"
3
4 config {
5 key = “main/main.tfstate”
6 bucket = "${var.bucket}"
7 dynamodb_table = "${var.dynamodb_table}"
8 profile = "${var.profile}"
9 region = "${var.region}"
10 }
11 }
38. FullStack Developers Israel
TERRAFORM | GETTING STARTED
DATA SOURCES ARE LIKE A “REGIONAL” MAP
data.terraform_remote_state.mainstate.domain_name
CURRENT “MODULE” REPRESENTATION REMOTE OUTPUT
39. FullStack Developers Israel
TERRAFORM | GETTING STARTED
STATE AS DATA SOURCE
1 resource "aws_route53_zone" "dev" {
2 name = “${data.terraform_remote_state.mainstate.domain_name}"
3
4 tags {
5 Environment = "dev"
6 }
7 }
This would work only if the remote state outputs this info ….
Enter - Terraform Modules
43. FullStack Developers Israel
TERRAFORM | GETTING STARTED
USE CASE
▸ Create an ec2 instance
▸ In many regions (AMI-id differs …)
▸ Use a custom image (custom built
AMI),
▸ Community managed image
eu-west-1 us-west-1
us-east-1
44. FullStack Developers Israel
TERRAFORM | GETTING STARTED
main.tf
1 resource "aws_instance" "example" {
2 ami = “ami-xxxxxxx"
3
4 instance_type = "t2.micro"
5
6 tags {
7 Name = “generic-ec2-instance“
8 }
9 }
This will very in each region …
45. FullStack Developers Israel
TERRAFORM | GETTING STARTED
A terraform “module” is basically a set of reusable terror files !
This will very in each region …
data "aws_ami" "centos" {
owners = ["679593333241"]
most_recent = true
filter {
name = "name"
values = ["CentOS Linux 7 x86_64 HVM EBS *"]
}
filter {
name = "architecture"
values = ["x86_64"]
}
filter {
name = "root-device-type"
values = ["ebs"]
}
}
46. FullStack Developers Israel
TERRAFORM | GETTING STARTED
A terraform “module” is basically a set of reusable terror files !
This will very in each region …
data "aws_ami" "ubuntu" {
most_recent = true
filter {
name = "name"
values = ["ubuntu/images/hvm-ssd/ubuntu-xenial-16.04-amd64-server
}
filter {
name = "virtualization-type"
values = ["hvm"]
}
owners = ["099720109477"] # Canonical
}
47. FullStack Developers Israel
TERRAFORM | GETTING STARTED
OUTPUT THE RETURN VALUES FOR THE NEXT MODULE … { THE ROOT MODULE }
output "regional_centos_ami_id" {
value = "${data.aws_ami.centos.id}"
}
output "regional_ubuntu_ami_id" {
value = "${data.aws_ami.ubuntu.id}"
}
48. FullStack Developers Israel
TERRAFORM | GETTING STARTED
USING A MODULE
module "locate_ami" {
source = "./modules/locate_ami/"
}
module “aws_instance" {
source = "terraform-aws-modules/ec2-instance/aws"
name = “my-cool-tool“
instance_count = 1
associate_public_ip_address = true
ami = "${module.locate_ami.regional_ubuntu_ami_id}"
instance_type = "t2.medium"
…
tags = {
Terraform = "true"
Environment = "dev"
Owner = "Tikal-Demo-Do-Not-Delete"
}
}
Module output becomes
Another modules input
49. FullStack Developers Israel
TERRAFORM | GETTING STARTED
MODULE CAN HAVE VARIABLES …
module “aws_instance" {
source = "terraform-aws-modules/ec2-instance/aws"
name = “my-cool-tool“
instance_count = 2
…
}
}
Module variable
variable block expects a value /
sets default one
variable "instance_count" {
description = "Number of instances to launch"
default = 1
}
50. FullStack Developers Israel
TERRAFORM | GETTING STARTED
MODULE CAN HAVE VARIABLES …
module “aws_instance" {
source = "terraform-aws-modules/ec2-instance/aws"
name = “my-cool-tool“
instance_count = 2
…
}
}
Module variable
variable block expects a value /
sets default one
variable "instance_count" {
description = "Number of instances to launch"
default = 1
}
The same as writing your root “module"
51. FullStack Developers Israel
TERRAFORM | GETTING STARTED
SO TERRAFORM IS A BUNCH OF MODULES
.
|-- common
| |-- backend.tf
| |-- files
| |-- global_variables.tf
| `-- provider.tf
|-- mainvpc
| |-- README.md
| |-- backend.tf
| |-- backend.tfvars
| |-- default_sgs.tf
| |-- files
| |-- global_variables.tf -> ../common/global_variables.tf
| |-- main.tf
| |-- outputs.tf
| |-- templates
| `-- variables.tf
|
A module which sets up your s3 bucket,
access and state store etc
a module which sets up the main VPC
security groups, vpn, nat gateways etc
52. FullStack Developers Israel
TERRAFORM | GETTING STARTED
SO TERRAFORM IS A BUNCH OF MODULES
.
|-- common
| |-- backend.tf
| |-- files
| |-- global_variables.tf
| `-- provider.tf
|-- mainvpc
| |-- README.md
| |-- backend.tf
| |-- backend.tfvars
| |-- default_sgs.tf
| |-- files
| |-- global_variables.tf -> ../common/global_variables.tf
| |-- main.tf
| |-- outputs.tf
| |-- templates
| `-- variables.tf
|
IMO - use symbolic links to reduce
duplicate variable decelerations.
53. FullStack Developers Israel
TERRAFORM | GETTING STARTED
SO TERRAFORM IS A BUNCH OF MODULES
.
|-- common
| |-- backend.tf
| |-- files
| |-- global_variables.tf
| `-- provider.tf
|-- mainvpc
| |-- README.md
| |-- backend.tf
| |-- backend.tfvars
| |-- default_sgs.tf
| |-- files
| |-- global_variables.tf -> ../common/global_variables.tf
| |-- main.tf
| |-- outputs.tf
| |-- templates
| `-- variables.tf
|
Use outputs.tf the help understand the
Interface between modules
54. FullStack Developers Israel
TERRAFORM | GETTING STARTED
SO TERRAFORM IS A BUNCH OF MODULES
-- mainvpc-k8s
| |-- README.md
| |-- backend.tf
| |-- backend.tfvars
| |-- global_variables.tf -> ../common/global_variables.tf
| |-- main.tf
| |-- outputs.tf
| `-- variables.tf
|-- mainvpc-peers
| |-- dev.tf
| `-- global_variables.tf -> ../common/global_variables.tf
`-- modules
|-- backend
|-- kops_reqs
|-- kubernetes
|-- locate_ami
`-- rabbitmq-cluster
A module which sets up Kubernetes
Connect vpc peers between main / others
Modules directory
55. FullStack Developers Israel
TERRAFORM | GETTING STARTED
TERRAFORM REGISTRY
▸ A long list of high quality / battle-tested
modules such as:
▸ vpc
▸ security groups
▸ ….