Azure-Samples / Azure-Samples/aks-platform-engineering

Remove kubeconfig error message from output

Open
#68 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
160
Forks
86
PR merge metrics
No merged PRs in 30d

Description

### This issue is for a: (mark with an `x`)
```
- [ ] bug report -> please search issues before submitting
- [x] feature request
- [ ] documentation issue or request
- [ ] regression (a behavior that used to work and stopped in a new release)
```

### Minimal steps to reproduce
> Run `terraform apply` without a file named `kubeconfig` in the terraform directory.

It outputs this:

```
Invalid attribute in provider configuration with provider["registry.terraform.io/hashicorp/kubernetes"], on provider.tf line 42, in provider "kubernetes": 42: provider "kubernetes" { 'config_path' refers to an invalid path: "./kubeconfig": stat ./kubeconfig: no such file or directory
```

By design this file doesn't exist since the Terraform code downloads the kubeconfig to this directory for use in to install ArgoCD and apply configurations after the AKS cluster is created.

See if there is a way to eliminate this to avoid confusion. [Related slack thread](https://stackoverflow.com/questions/72645372/config-path-refers-to-an-invalid-path-kubeconfig-stat-kubeconfig-no-such). Also related to #48

Contributor guide

Open the contributing guide

Research direction

Reproduce the issue with `terraform apply` and no `kubeconfig` file, then inspect `provider.tf` around line 42 and the related configuration in issue #48. Done means the missing-file message is eliminated without preventing the downloaded kubeconfig from being used to install ArgoCD and apply configurations.

Written by the indexing model from the issue text.

Assessment

Tech stack
kubernetes, terraform
Domain
devops, infrastructure
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.