rancher / terraform-provider-rancher2

Terraform Rancher2 provider
https://www.terraform.io/docs/providers/rancher2/
Mozilla Public License 2.0
253 stars 216 forks source link

Change default image to 20-04 #1264

Closed felipe-colussi closed 7 months ago

felipe-colussi commented 7 months ago

Issue: rancher/terraform-provider-rancher2#1215

Problem

During tests we found a problem with the ubuntu-22-04-x64, wile creating the downstream cluster it would get stuck after Installing Docker from: https://releases.rancher.com/install-docker/24.0.sh with one of the following errors:

Those errors were happening 100% of the times (UI or TF) on 2.7 and also were happening on 2.8 (sometimes it worked on that one).

Solution

Wile testing with ubuntu-20-04-x64 we didn't get the error. For safety reasons we decided to change the image back to 20-04

Testing

Create machine using TF.

Engineering Testing

Manual Testing

Create machine using TF.

Automated Testing

None

QA Testing Considerations

Regressions Considerations

main.tf


terraform {
  required_providers {
    rancher2 = {
      source  = "terraform.local/local/rancher2"
      version = "4.0.0-rc4"
    }
  }
}

provider "rancher2" {
  api_url   = "<REDACTED>"
  token_key = "<REDACTED>"
  insecure  = true
}

resource "rancher2_node_template" "rancher2_node_template" {
  name = "qa-testing-jkeslar-plz-deletee"
  digitalocean_config {
    access_token  = "<REDACTED>"
    ipv6 = false
    monitoring = false
    private_networking = false
    region = "nyc3"
    size = "s-2vcpu-4gb-intel"
    ssh_key_fingerprint=    ""
    ssh_port = "22"
    ssh_user =  "root"
    tags =""
    userdata= ""
  }
}

resource "rancher2_cluster" "rancher2_cluster" {
  depends_on = [rancher2_node_template.rancher2_node_template]
  name       = "jkeslar-qa-testing-plz-deletee"
  rke_config {
    kubernetes_version = "v1.27.6-rancher1-1"
    network {
      plugin = "canal"
    }
  }
}

resource "rancher2_node_pool" "pool1" {
  depends_on       = [rancher2_cluster.rancher2_cluster]
  cluster_id       = rancher2_cluster.rancher2_cluster.id
  name             = "pool1"
  hostname_prefix  = "jkeslar-pool1-"
  node_template_id = rancher2_node_template.rancher2_node_template.id
  quantity         = 1
  control_plane    = true
  etcd             = true
  worker           = true
}
kkaempf commented 7 months ago

closing stale PRs. If you still intend to work on this, please reopen.