main.tf 534 B

1234567891011121314151617181920212223
  1. provider "aws" {
  2. region = "${var.region}"
  3. profile = "${var.profile}"
  4. }
  5. # Allow us to configure volumes
  6. locals {
  7. count_volumes = (var.enable-volumes == true ? var.data-node-count : 0)
  8. }
  9. # Allow us to enable flash devices
  10. locals {
  11. count_flash = (var.enable-flash == true ? var.data-node-count : 0)
  12. }
  13. locals {
  14. ssh_key_path = (var.ssh-key == "" ? "~/.ssh/${var.vpc-name}.pem" : "~/.ssh/${replace(var.ssh-key, ".pem", "")}.pem")
  15. }
  16. locals {
  17. ssh_key= (var.ssh-key == "" ? var.vpc-name : replace(var.ssh-key, ".pem", ""))
  18. }