Why is this an issue?
When creating a Kubernetes cluster, provisioning fails with "CLOUD_API_URL is required but not set in environment" even after setting CLOUD_API_KEY. The CLOUD_API_URL env var is required by the k8s provisioner but is not documented and not set in docker-compose.yml.
What is causing it?
The k8s provisioner at internal/repositories/k8s/provisioner.go lines 123-126 checks for both CLOUD_API_KEY and CLOUD_API_URL:
apiURL := os.Getenv("CLOUD_API_URL")
if apiURL == "" {
return p.failCluster(ctx, cluster, "CLOUD_API_URL is required but not set in environment", nil)
}
Neither docker-compose.yml nor .env set this variable.
How can it be solved?
Add CLOUD_API_URL to docker-compose.yml environment variables.
Category
Severity
Steps to reproduce
# Without CLOUD_API_URL:
cloud kubernetes create -n test-cluster -v <vpc-id> -w 1
# API log: "CLOUD_API_URL is required but not set in environment"
Why is this an issue?
When creating a Kubernetes cluster, provisioning fails with "CLOUD_API_URL is required but not set in environment" even after setting
CLOUD_API_KEY. TheCLOUD_API_URLenv var is required by the k8s provisioner but is not documented and not set in docker-compose.yml.What is causing it?
The k8s provisioner at
internal/repositories/k8s/provisioner.golines 123-126 checks for bothCLOUD_API_KEYandCLOUD_API_URL:Neither docker-compose.yml nor .env set this variable.
How can it be solved?
Add
CLOUD_API_URLto docker-compose.yml environment variables.Category
Severity
Steps to reproduce