nutanix / terraform-provider-nutanix

Terraform Nutanix Provider
https://www.terraform.io/docs/providers/nutanix/
Mozilla Public License 2.0
101 stars 112 forks source link

Failed add private registry with certificate #677

Open omega31 opened 7 months ago

omega31 commented 7 months ago

Nutanix Cluster Information

Terraform Version

1.5.7

Affected Resource(s)

resource nutanix_karbon_private_registry

Terraform Configuration Files

resource "nutanix_karbon_private_registry" "harbor" {
  name     = "registry-test"
  cert     =  filebase64("${path.module}/CA.pem")
  url      = "10.1.x.x"
  port     = 443
  username = "robot$nke"
  password = "xxxxxxxxxxx"
}

Debug Output

On the pcvm /home/data/nutanix/logs_karbon_core there is a log saying illegal base64 data at input byte 0

I tried multiple ways to implement certificate in base64 :

Expected Behavior

Apply complete! Resources: 1 added, 0 changed, 0 destroyed.

Actual Behavior

│ Error: error occurred during private registry creation: error: map[Private Registry Create:Failed to add new private registry to NKE]
│
│   with nutanix_karbon_private_registry.harbor,
│   on 03_registry.tf line 1, in resource "nutanix_karbon_private_registry" "harbor":
│    1: resource "nutanix_karbon_private_registry" "harbor" {
│
╵

Steps to Reproduce

  1. terraform apply

Important Factors