0
votes

Suppose I want to provision a simple stack in any of several public clouds from a single configuration. Will any existing IaC tools do this?

For example:

  • a virtual network (VPC, VNET)
  • one small* Ubuntu instance on the latest Xenial image from Canonical with a public IP (EC2, VM, GCE)
  • one big* server on the latest Trusty image from Canonical
  • an internet gateway (IGW)

I can do this easily using Terraform or Ansible. But, per my current understanding, this would be a separate Ansible playbooks or Terraform configurations for each cloud environment (AWS, Azure, GCP).

Does a tool exist that would allow me to point to a single configuration and pass the cloud in which to provision the stack as an option.

i.e. toolname create --config=my_simple_stack --provider=azure or toolname create --config=my_simple_stack --provider=gcp

Then if my_simple_stack configuration needed to change, the change could be made in one place rather than three.

* sizes being ballpark as I realize that available VM sizes are not necessarily consistent across providers. So small might be 2+ core / 2+ GB RAM and big might be 16+ core / 16+ GB RAM depending on what the provider offers.

1
Terraform would allow you to write modules that abstract the cloud providers as per the duplicate link (stackoverflow.com/questions/42789247/…) but I'm not sure it's necessarily a good idea. Terraform itself specifically won't abstract different cloud providers because you will find it very difficult to access many cloud features if you limit yourself to what is common across them all.ydaetskcoR

1 Answers

0
votes

Thanks all. I suspect that there isn't tooling available to do this for the reason that ydaetskcoR said - it isn't necessarily a good idea.

Containerization is the better approach rather than trying to build like-for-like least-common-denominator environments across a bunch of different cloud platforms.