Hacker News new | ask | show | jobs
by JBerlinsky 3455 days ago
Are you looking to automate infrastructure-as-code in there, as well? I've lost many a night to trying to get Rancher to play nice with Terraform, especially in high-availability mode. Luckily, it appears that the process has been vastly simplified in recent rancher-manager releases.
2 comments

Oh great, you've just added Terraform[1] to my list of possible tie-in softwares. Thanks for that, you monster. /s

Yes, at least for development, setting up the entire environment must be a one-command execution. Every new developer to a team will obviously need to progressively learn the entire stack, but they should be up and running after a single VCS checkout and installation command.

I expect staging and production to be a perfect replica of the same environment developers use. As to how realistic it is to "launch the entire production cluster with a single command", with remote server provisioning, IP allocations, multiple hosts for various load-balanced pools, etc... I'll have to see when that time comes.

[1] https://www.terraform.io/

You're welcome ;)

Terraform is designed for something close to one-command execution. You're going to have to swap in variables (e.g. AWS access keys for a particular account, domain names, IP addresses, etc.), but Terraform is designed for that. I would advise looking into Terraform Modules[0], which encapsulate this kind of work nicely.

[0]: https://www.terraform.io/docs/modules/create.html

You might take a look at troposphere[1] too. I've used both extensively and each definitely has it's strengths. In some cases troposphere is a better fit.

[1] https://github.com/cloudtools/troposphere

Are there good ways to use Terraform internally / without online providers like AWS? I've just started using it with DigitalOcean, but I'd like to use it at home to do IAC with my whole setup. As far as I can tell the only good route for this is to throw OpenStack on bare metal, but I'm a newbie so I wonder if there's a better way.
You can write your own providers for Terraform[0] and bake whatever you want into its HCL syntax. In your case, this might not have significant returns over bootstrapping with Ansible/Chef/Puppet -- it all depends on what you want to do.

[0]: https://www.hashicorp.com/blog/terraform-custom-providers.ht...