Advertisement
Guest User

Untitled

a guest
Jul 25th, 2016
260
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.25 KB | None | 0 0
  1. variable location { default = "CA1" }
  2. variable control_count { default = 1 }
  3. variable worker_count { default = 2 }
  4. variable edge_count { default = 1 }
  5. variable ssh_pass { default = "SeeEllSeeMant!" }
  6. variable ssh_key { default = "~/.ssh/id_rsa.pub" }
  7.  
  8. provider "clc" {
  9. # username = "${var.clc_username}"
  10. # password = "${var.clc_password}"
  11. # account = "${var.clc_account}" # optional
  12. }
  13.  
  14. # server group
  15. resource "clc_group" "mantl" {
  16. location_id = "${var.location}"
  17. name = "mantl"
  18. parent = "Default Group"
  19. }
  20.  
  21. module "control-nodes" {
  22. source = "./terraform/clc/node"
  23. location = "${var.location}"
  24. group_id = "${clc_group.mantl.id}"
  25. role = "control"
  26. name = "CTL"
  27. count = "${var.control_count}"
  28. ssh_pass = "${var.ssh_pass}"
  29. ssh_key = "${var.ssh_key}"
  30. }
  31.  
  32. module "edge-nodes" {
  33. source = "./terraform/clc/node"
  34. location = "${var.location}"
  35. group_id = "${clc_group.mantl.id}"
  36. role = "edge"
  37. name = "EDG"
  38. count = "${var.edge_count}"
  39. ssh_pass = "${var.ssh_pass}"
  40. ssh_key = "${var.ssh_key}"
  41. }
  42.  
  43. module "worker-nodes" {
  44. source = "./terraform/clc/node"
  45. location = "${var.location}"
  46. group_id = "${clc_group.mantl.id}"
  47. role = "worker"
  48. name = "WKR"
  49. count = "${var.worker_count}"
  50. ssh_pass = "${var.ssh_pass}"
  51. ssh_key = "${var.ssh_key}"
  52. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement