Azure / Azure/azure-cli

az aks command invoke attachment size limit is too small

Open
#22,870 5 comments 1 reaction 0 assignees View on GitHub
act-observability-squad AKS Auto-Assign customer-reported feature-request Service Attention
Dominant language
Python
Stars
4.6k
Forks
3.5k
Avg merge
3d 2h
Merged PRs (30d)
60

Description

> ### `az feedback` auto-generates most of the information requested below, as of CLI version 2.0.62

**Related command**

``` powershell
az aks command invoke -g $Env:AKS_RESOURCEGROUP -n $Env:AKS_CLUSTER_NAME -c "chmod +x deploycharts.sh && ./deploycharts.sh ${Env:AKS_HELMOVERRIDE_ENVIRONMENT}" -f .
```

The deploycharts.sh looks like this:

``` bash
#!/bin/bash
# Usage: deploycharts.sh [ENVIRONMENT]

set -ex

echo "Starting helm chart deployments for kube-prometheus-stack using overrides for environment $1"
helm upgrade --install --namespace=prometheus --create-namespace \
kube-prometheus-stack ./kube-prometheus-stack

echo "Show pods and services:"
kubectl get pods -n prometheus
kubectl get services -n prometheus

echo "Show pods for release:"
kubectl get pods -l "release=kube-prometheus-stack" -n prometheus
```

and the contents of the folder attached have this structure:
```
deploycharts.sh
kube-prometheus-stack\
charts\
crds\
values.yaml
...(all the other contents of the chart)
```

**Describe the bug**

When executing this command to deploy our Prometheus chart (https://prometheus-community.github.io/helm-charts/kube-prometheus-stack:35.4.2) it fails with the following error:

```
Running az aks command invoke on charts-prometheus...
ERROR: Operation returned an invalid status 'Request Entity Too Large'
aksdeploy.ps1: Error when running az aks command.
```

The chart is not big (2.08 MB according to Windows Explorer). So what's the attachment size limitation for this command and how can we increase it?

**To Reproduce**

Pull the chart:
`helm pull kube-prometheus-stack --repo https://prometheus-community.github.io/helm-charts --version 35.4.2 --untar --untardir `

Then deploy this chart to a kubernetes cluster with the default values using `az aks command invoke` and use the parameter -f '.' to attach the whole chart.

**Expected behavior**

Chart deployment should succeed naturally without this error 'Request Entity Too Large'.

**Environment summary**

Azure Cli 2.32.0

We use Ubuntu images and Azure Container Instances (part of Ev2 Shell extensions https://ev2docs.azure.net/features/extensibility/shell/intro.html?q=adm-ubuntu-1804-l) to run these deployment scripts and deploy to our private AKS cluster. The images are Ubuntu 1804.

**Additional context**

In the past we've had to split the charts into parts to work around this.

We are a Microsoft team (jucallej@microsoft.com).

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.