equinix / terraform-provider-equinix

Terraform Equinix provider
https://deploy.equinix.com/labs/terraform-provider-equinix/
MIT License
47 stars 44 forks source link

Support cloudinit for Cisco 8000V #413

Open grotewortel opened 11 months ago

grotewortel commented 11 months ago

Community Note

Description

When deploying a Cisco 8000V with this Terraform provider, we cannot deploy the essential base configuration to continue configuring this edge with Terraform.

Not having a cloudinit option results in a dependency to open up SSH to public internet and run ansible to compensate.
An example is documented here: Equinix-labs Multi Cloud Router.

All necessary resources and functionality seems to be present already.

Please implement cloudinit functionality for Cisco 8000V.

New or Affected Resource(s)

Potential Terraform Configuration

variable "filepath" { default = "cloudInitFileFolder/TF-CISCO-cloud-init-file.txt" }

resource "equinix_network_file" "cisco-cloudinit-file" {
  file_name = "TF-CISCO-cloud-init-file.txt"
  content = file("${path.module}/${var.filepath}")
  metro_code = data.equinix_network_account.sv.metro_code
  device_type_code = "C8000V"
  process_type = "CLOUD_INIT"
  self_managed = true
  byol = true
}

resource "equinix_network_device" "cisco" {
  name            = "tf-cisco"
  metro_code      = data.equinix_network_account.sv.metro_code
  type_code       = "C8000V"
  self_managed    = true
  byol            = true
  package_code    = "STD"
  notifications   = ["network-essentials"]
  term_length     = 12
  account_number  = data.equinix_network_account.sv.number
  version         = "6.9"
  core_count      = 2
  cloud_init_file_id = equinix_network_file.cisco-cloudinit-file.uuid
  acl_template_id = "c06150ea-b604-4ad1-832a-d63936e9b938"
}

References

grotewortel commented 5 months ago

I noticed that your web gui support this feature already for the 8000V in controller mode. Not in standalone mode.

Is there any progress on this?

cisco_8000v_cloudinit