chapter five

5 Serverless Made Easy

 

This chapter covers:

  • Deploying a serverless application with Azure
  • Problem solving techniques and strategies for Terraform projects
  • Adapting modules to fetch build artifacts at runtime
  • Overcoming deficiencies and bugs in the Azure provider
  • Case studies for combining Azure Resource Manager (ARM) with Terraformrestore

Serverless is one of the biggest marketing gimmicks of all time. It seems like everything is marketed as “serverless” these days, despite nobody being able to agree on what the word even means. One thing for sure is that serverless does not refer to the elimination of servers; ironically, since serverless implementations typically involve dynamic, scalable, and highly distributed systems, there’s often way more servers involved than in conventional system designs. Serverless is not one technology, it’s an umbrella term for technologies sharing two key characteristics:

  1. pay-as-you-go billing
  2. minimal operational overhead

Pay-as-you-go billing is all about paying for the actual amount of resources consumed, rather than pre-purchased units of capacity (i.e. pay for what you use, not what you don’t use). Yes, you could save money by buying reserved units of capacity, but it’s easy to overestimate how much you’ll really need and end up paying way too much. Like when you go to the movies and buy a huge bag of popcorn because its only 50 cents more, but you actually would have been fine with a small.

5.2       Architecture and Planning

5.2.1   Sorting by Group, then by Size

5.2.2   Problem Solving

5.3       Writing the Code

5.3.1   Resource Group

5.3.2   Storage Container

5.3.3   Storage Blob

5.3.4   Function App

5.3.5   Final Touches

5.4       Deploying to Azure

5.5       Combining Azure Resource Manager (ARM) with Terraform

5.5.1   Deploying Unsupported Resources

5.5.2   Migrating from Legacy Code with the Strangler Façade Pattern

5.5.3   Generating Configuration Code

5.6       Summary