Terraform how-to: create a variable list of numbered items
In a couple of templates I worked on I came across the need to create a variable list of numbered strings that is a product of a different list.
Dealing with this kind of thing is easy when you’re dealing with resources (that support
count). It’s less straight-forward when you need to create a
local variable, say, to use for a resource’s value, or an
output, that don’t.
Let’s have a look at a dirty hack that can help. 🙂
Use Pulse Virtual Traffic Manager to route traffic to Kubernetes pods
Pulse Virtual Traffic Manager (vTM) v18.1 introduced new Service Discovery mechanism to help with situations where vTM sits in front of an application made up from dynamic components.
Many organisations are now either use or experimenting with Kubernetes (K8s). Let’s see if we can get this Service Discovery mechanism to help us expose an application running on K8s to the Internet:
- In a way that works both in public clouds and on-prem;
- Supports session persistence and per-pod health checks;
- Can scale really well; and
- Is highly available*.
*The above assumes that you operate a production-grade HA cluster of vTMs somewhere where they can reach your K8s nodes running your application pods.
Let’s Terraform the vTM: Part 4 / 4
Continuing from Part 1, Part 2, and Part 3, in this final instalment we’ll finish our configuration by adding things like SSL offload and L7 routing.
Let’s Terraform the vTM: Part 3 / 4
Carrying on from Part 1 and Part 2, in this instalment we’ll continue adding to our configuration.
If you’re back with us after a break – feel free to go over the part 1 and 2 again, and if you’re following along – make sure your set-up is all good, and the very last exercise from Part 2 completes correctly.
Let’s Terraform the vTM: Part 2 / 4
Continuing from Part 1, today we’ll make our template do something useful. If you’re following along – make sure your set-up is all good, and the very last exercise of Part 1 completes correctly.
Ready? Let’s carry on!
Let’s Terraform the vTM: Part 1 / 4
The freshly-released Pulse Virtual Traffic Manager (vTM) v18.1 comes out with a Terraform Provider for vTM. The provider ships with 100% coverage for all vTM’s REST API resources, and includes support for the API version 4.0 that goes back to vTM 17.2, and the API version 5.2 that includes all the newest features that shipped with vTM 18.1.
In this 4-part post we’ll do a quick introduction of Terraform provider for vTM, and show how it can help you support the needs of your applications.
New version of the CloudFormation template for Pulse vTM
Quick announcement – I’ve published a new version of the CloudFormation template that deploys a HA cluster of Pulse vTM instances into an existing VPC.
- Suitable for using as a module in bigger stacks, e.g., CloudFormation or Terraform that take care of the VPC and other infrastructure. Has been tested with the later.
- Updated with the latest vTM AMIs for 17.2r2, 17.3, 17.4, and 18.1.
- Supports additional Security Groups (e.g., when your target instances use SG with Source based on SG name).
- Can take UserData from Pulse Service Director’s Cloud Registrations for self-registration.
Please see README for full details, especially the Disclaimer at the beginning. 🙂