Comments (7)
What do you do with Yaml after you export it with statement above?
from aks.
@artisticcheese save the yaml to a file (i.e. aks.config).
Then set the environment variable KUBECONFIG to the full path of aks.config.
You should then be able to interact with kubectl.
from aks.
I manually copied the content from file. C:\Users\USERNAME\AppData\Local\Packages\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc\LocalState\rootfs\home\USERNAME.kube to C:\Users\USERNAME.kube
Basically.. I first did the get-credential in Ubuntu Subsystem and then taken the file and copied to for windows CLI kubectl config.
from aks.
Saving as YAML file and the modifying variable did not work either. Error is below which appears wanting JSON and not YAML.
error: Error loading config file ".\.kube\config": couldn't get version/kind; json parse error: json: cannot unmarshal string into Go value of type struct { APIVersion string "json:\"apiVersion,omitempty\""; Kind string "json:\"kind,omitempty\"" }
from aks.
I found saving the YAML isn't a viable workaround as @artisticcheese states, kubctl is expecting JSON not YAML. Just hope Azure/azure-cli#4746 gets fixed soon
from aks.
After getting the exception on Windows 10, I managed to workaround this issue by doing the following:
Assuming that you already downloaded the kubectl using "az aks install-cli" command
- Open CMD, and run: az aks get-credentials -g [your aks resource group] -n [your aks name] -f - > .kube\config
- Add to your environment variable the following parameter: KUBECONFIG and set the value to where previous step save the config file. for example: C:\Users[your user name folder].kube\config
- Try now to run the following command: "kubectl get nodes"
- In order to open the dashboard you need to run the following command:
kubectl port-forward kubernetes-dashboard-1672970692-375tg 9090 --namespace kube-system
you need to replace "kubernetes-dashboard-1672970692-375tg" with your pod name which run the dashboard. you can get it by running the following command:
kubectl get pods --all-namespaces
Hope it will help.
from aks.
looks like its fixed in Azure/azure-cli#4746 and version number 2.0.21.
Get the new MSI at https://aka.ms/InstallAzureCliWindows
from aks.
Related Issues (20)
- [Question] What is the difference of availability zone settings between AKS and nodepool?
- [BUG] Issues from the roadmap get stale and auto-closed
- [Feedback] Document additional steps needed to deploy Istio managed add-on in cluster using a HTTP Proxy HOT 2
- [BUG] Pod network theoretical IPs calculations blocks cluster autoscaler HOT 2
- AKS will start rejecting requests with unknown AgentPool mode starting on 2025-01-01
- [Feature] managed istio egress gateway support HOT 2
- [BREAKING CHANGE] KEDA 2.15 and KEDA 2.14 introduces multiple breaking changes in AKS v1.30+ HOT 3
- AKS GPU Image (preview) will be retired on January 1, 2025
- [BUG] Test flow HOT 3
- [BUG] [test] Testing flow HOT 1
- [Feature] Azure CNI Overlay Dual-stack Windows Support HOT 1
- [Feature] Azure CNI Powered by Cilium Azure CNI Overlay Dual-stack support HOT 2
- Bump KEDA version to 2.15.1 on AKS 1.31 preview HOT 1
- AKS v1.31 public preview
- Attach ACR support in AKS Vs Code extension HOT 1
- Deployment Safeguards - Introduction of Pod Security Standards
- Bump KEDA version to 2.14.1 on AKS 1.30 HOT 3
- Nodepool VM SKU resize
- [BUG] Private DNS record not created by webAppRouting addon's Internal IngressController HOT 3
- [Feature] Enable the addition of Windows node pools after migrating from Kubenet to Azure CNI
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from aks.