equinix / terraform-equinix-metal-anthos-on-vsphere

[Deprecated] Automated Anthos Installation via Terraform for Equinix Metal with vSphere
https://registry.terraform.io/modules/equinix/anthos-on-vsphere/metal/latest
Apache License 2.0
62 stars 41 forks source link

Deployment fails when respecting the README.MD #129

Closed vhamburger closed 2 weeks ago

vhamburger commented 3 years ago

The introduced changes with the vsphere module break the entire repository. Variables in TF are not documented or broken (object_store_tool is undocumented while the "s3_boolean" is not doing anything anymre). Also - I was not able to deploy and continously got NSX errors like: Error: remote-exec provisioner error

with module.vsphere.null_resource.apply_esx_network_config[0], on .terraform/modules/vsphere/main.tf line 408, in resource "null_resource" "apply_esx_network_config": 408: provisioner "remote-exec" {

error executing "/tmp/terraform_433087771.sh": Process exited with status 1 This seems to be the python3 code from the vSphere module (main.tf line 408...)

Would it be possible to bring the readme up to date and fully document the changes. Also - could you test this with Anthos on VMware version 1.7 (most recent - 1.5 is rather old).

displague commented 3 years ago

https://github.com/equinix/terraform-metal-anthos-on-vsphere/pull/127 is bringing some of these updates. That PR is being tested through CI and there are some test failures blocking it currently.

I've created #130 to represent an interest in supporting Anthos 1.7.

di commented 3 years ago

This is affecting me as well. Are there any quick workarounds?

c0dyhi11 commented 3 years ago

You can run off this release. It pre-dates all of these changes: https://github.com/equinix/terraform-metal-anthos-on-vsphere/releases/tag/v0.1.0

di commented 3 years ago

Thanks @c0dyhi11! I get the following error though:

$ git checkout v0.1.0
HEAD is now at d053ee7 improve error handling in deploy_admin_ws.sh (#79)

$ terraform init

Initializing the backend...

Initializing provider plugins...
- Finding hashicorp/packet versions matching "~> 2.10.1"...
- Finding latest version of hashicorp/random...
- Finding latest version of hashicorp/null...
- Finding latest version of hashicorp/local...
- Finding latest version of hashicorp/tls...
- Finding latest version of hashicorp/template...
- Installing hashicorp/random v3.1.0...
- Installed hashicorp/random v3.1.0 (signed by HashiCorp)
- Installing hashicorp/null v3.1.0...
- Installed hashicorp/null v3.1.0 (signed by HashiCorp)
- Installing hashicorp/local v2.1.0...
- Installed hashicorp/local v2.1.0 (signed by HashiCorp)
- Installing hashicorp/tls v3.1.0...
- Installed hashicorp/tls v3.1.0 (signed by HashiCorp)
- Installing hashicorp/template v2.2.0...
- Installed hashicorp/template v2.2.0 (signed by HashiCorp)
╷
│ Error: Failed to query available provider packages
│
│ Could not retrieve the list of available versions for provider hashicorp/packet: provider registry registry.terraform.io does not have a provider named
│ registry.terraform.io/hashicorp/packet
│
│ Did you intend to use packethost/packet? If so, you must specify that source address in each module which requires that provider. To see which modules
│ are currently depending on hashicorp/packet, run the following command:
│     terraform providers

Sorry, not super familiar with terraform so I'm not sure what's best to do here.

di commented 3 years ago

I tried making the following update to my main.tf:

--- a/main.tf
+++ b/main.tf
@@ -1,6 +1,9 @@
 terraform {
   required_providers {
-    packet = "~> 2.10.1"
+    packet = {
+      source = "packethost/packet"
+      version = "~> 2.10.1"
+    }
   }
 }

However this gives me:

$ terraform init

Initializing the backend...

Initializing provider plugins...
- Finding latest version of hashicorp/local...
- Finding latest version of hashicorp/template...
- Finding packethost/packet versions matching "~> 2.10.1"...
- Finding latest version of hashicorp/random...
- Finding latest version of hashicorp/null...
- Finding latest version of hashicorp/tls...
- Using previously-installed hashicorp/random v3.1.0
- Using previously-installed hashicorp/null v3.1.0
- Using previously-installed hashicorp/tls v3.1.0
- Using previously-installed hashicorp/local v2.1.0
- Using previously-installed hashicorp/template v2.2.0
╷
│ Error: Failed to query available provider packages
│
│ Could not retrieve the list of available versions for provider packethost/packet: no available releases
match the given constraints ~> 2.10.1

And indeed 2.10.1 doesn't seem to be available here: https://registry.terraform.io/providers/packethost/packet/. Attempting to upgrade to any newer version gives me:

$ terraform apply --auto-approve
╷
│ Error: "network_type": this field cannot be set
│
│   with packet_device.router,
│   on 03-edge-router.tf line 13, in resource "packet_device" "router":
│   13: resource "packet_device" "router" {
│
╵
╷
│ Error: "network_type": this field cannot be set
│
│   with packet_device.esxi_hosts,
│   on 04-esx-hosts.tf line 1, in resource "packet_device" "esxi_hosts":
│    1: resource "packet_device" "esxi_hosts" {
│
╵
c0dyhi11 commented 3 years ago

Yeah... This is pretty broken... The is being compounded that packet was acquired by Equinix and changed the module from packet to equinix-metal

Do you need to run Anthos on VMware?

Or could you get away with Running Anthos on Baremetal?

https://github.com/equinix/terraform-metal-anthos-on-baremetal

di commented 3 years ago

That could work, I tried it but I'm running into issues there as well: https://github.com/equinix/terraform-metal-anthos-on-baremetal/issues/74