AKS traffic manager manages calls to Azure resource manager
Перейти к файлу
Pengfei Ni ac6453888a
Merge pull request #31 from Azure/dependabot/go_modules/github.com/onsi/gomega-1.34.1
Bump github.com/onsi/gomega from 1.33.1 to 1.34.1
2024-08-16 13:34:30 +08:00
.github
.gitignore
AzureStackCloud_China.json
AzureStackCloud_German.json
AzureStackCloud_USGov.json
CODE_OF_CONDUCT.md
Dockerfile
LICENSE
README.md
SECURITY.md
autothrust.go
azure-pipelines.yml
azurestackcloud.json
go.mod
go.sum
main.go
proxy.go
proxy_test.go

README.md

AKS traffic manager

AKS traffic manager is a proxy between Azure Kubernetes cluster's cloud provider and Azure resource manager. It helps with throttling related issues by delaying 429 responses from Azure resource manager.

User Guide

All aks clusters already have aks-traffic-manager applied. But you need to manually apply aks traffic manager to aks-engine clusters. At below are the steps:

  1. Log on the master node of your cluster

  2. Download aks-traffic-manager binary:

curl -o aks-traffic-manager -L https://github.com/Azure/aks-traffic-manager/releases/download/v0.3/aks-traffic-manager

chmod a+rx aks-traffic-manager

  1. Download the azurestackcloud.json file:

curl -o /etc/kubernetes/azurestackcloud.json -L https://raw.githubusercontent.com/Azure/aks-traffic-manager/master/azurestackcloud.json

For national clouds, download the cloud specific file and rename to azurestackcloud.json file. For example, for US gov cloud, use AzureStackCloud_USGov.json

  1. Reconfig azure.json to use azure stack:

sed -i 's/AzurePublicCloud/AzureStackCloud/g' /etc/kubernetes/azure.json For national clouds, replace "AzurePublicCloud" above with the cloud name.

  1. Edit /etc/kubernetes/manifests/kube-controller-manager.yaml to include the following environment variable definition:
      env:
        - name: AZURE_ENVIRONMENT_FILEPATH
          value: /etc/kubernetes/azurestackcloud.json
  1. Run aks-traffic-manager ./aks-traffic-manager . Use --cloud argument to specify the current cloud. Default is "AzurePublicCloud". You can also specify national clouds: AZURECHINACLOUD | AZUREGERMANCLOUD| AZUREUSGOVERNMENTCLOUD.

  2. You should now be able to see logs from aks-traffice-manager showing the ARM requests going through the proxy.

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.

When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.