{"id":49373877,"url":"https://github.com/licenseware/azcli-aks","last_synced_at":"2026-04-28T01:07:29.849Z","repository":{"id":225273455,"uuid":"765531771","full_name":"licenseware/azcli-aks","owner":"licenseware","description":"AZ CLI \u0026 kubectl both in one Docker image. Disposable and reusable deployment tool.","archived":false,"fork":false,"pushed_at":"2026-03-03T04:59:22.000Z","size":49,"stargazers_count":5,"open_issues_count":5,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-03-03T08:41:14.304Z","etag":null,"topics":["aks","az-cli","azure","azure-aks","azure-cli","continuous-delivery","continuous-deployment","deployment","docker","kubectl","pod"],"latest_commit_sha":null,"homepage":"","language":"Dockerfile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/licenseware.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-03-01T05:19:40.000Z","updated_at":"2025-08-17T12:44:44.000Z","dependencies_parsed_at":"2024-07-25T03:27:00.675Z","dependency_job_id":"5c60bbde-cc83-41fa-8fb8-1131618d60ca","html_url":"https://github.com/licenseware/azcli-aks","commit_stats":null,"previous_names":["licenseware/azcli-aks"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/licenseware/azcli-aks","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/licenseware%2Fazcli-aks","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/licenseware%2Fazcli-aks/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/licenseware%2Fazcli-aks/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/licenseware%2Fazcli-aks/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/licenseware","download_url":"https://codeload.github.com/licenseware/azcli-aks/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/licenseware%2Fazcli-aks/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32361482,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-27T20:07:02.737Z","status":"ssl_error","status_checked_at":"2026-04-27T20:07:00.910Z","response_time":128,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aks","az-cli","azure","azure-aks","azure-cli","continuous-delivery","continuous-deployment","deployment","docker","kubectl","pod"],"created_at":"2026-04-28T01:07:29.068Z","updated_at":"2026-04-28T01:07:29.844Z","avatar_url":"https://github.com/licenseware.png","language":"Dockerfile","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003c!-- START doctoc generated TOC please keep comment here to allow auto update --\u003e\n\u003c!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE --\u003e\n**Table of Contents**  *generated with [DocToc](https://github.com/thlorenz/doctoc)*\n\n- [AZ CLI for AKS](#az-cli-for-aks)\n  - [Service Principal Creation](#service-principal-creation)\n  - [Usage](#usage)\n  - [FAQ](#faq)\n    - [Why not use the azure-cli docker image instead?](#why-not-use-the-azure-cli-docker-image-instead)\n\n\u003c!-- END doctoc generated TOC please keep comment here to allow auto update --\u003e\n\n# AZ CLI for AKS\n\n[![ghcr-size](https://ghcr-badge.egpl.dev/licenseware/azcli-aks/size)](https://github.com/orgs/licenseware/packages/container/package/azcli-aks)\n[![ghcr-tags](https://ghcr-badge.egpl.dev/licenseware/azcli-aks/latest_tag?label=latest-tag)](https://github.com/orgs/licenseware/packages/container/package/azcli-aks)\n\nThis Docker image allows for a disposable container to run `kubectl` commands\nagainst an AKS cluster. The image is based on the official [`mcr.microsoft.com/azure-cli`][AZ CLI Official Docker] image.\n\n## Service Principal Creation\n\nIf you want to see the TF code that created the Service Principal, expand the\ndetails below.\n\n\u003cdetails\u003e\n\u003csummary\u003eExpand for details\u003c/summary\u003e\n\n```terraform\ndata \"azuread_client_config\" \"current\" {}\n\ndata \"azurerm_kubernetes_cluster\" \"this\" {\n  name                = \"my-aks-cluster\"\n  resource_group_name = \"my-rg\"\n}\n\n\nresource \"azuread_application\" \"this\" {\n  display_name = \"my-aks-app\"\n  owners       = [data.azuread_client_config.current.object_id]\n}\n\nresource \"azuread_service_principal\" \"this\" {\n  app_role_assignment_required = false\n  client_id                    = azuread_application.this.client_id\n  owners                       = [data.azuread_client_config.current.object_id]\n}\n\nresource \"time_rotating\" \"this\" {\n  rotation_days = 7\n}\n\nresource \"azuread_service_principal_password\" \"this\" {\n  service_principal_id = azuread_service_principal.this.object_id\n  rotate_when_changed = {\n    rotation = time_rotating.this.id\n  }\n}\n\nresource \"azurerm_role_assignment\" \"aks_rbac\" {\n  principal_id         = azuread_service_principal.this.object_id\n  role_definition_name = \"Azure Kubernetes Service Cluster User Role\"\n  scope                = data.azurerm_kubernetes_cluster.this.id\n}\n\noutput \"client_id\" {\n  value = azuread_service_principal.this.client_id\n}\n\noutput \"client_secret\" {\n  value     = azuread_service_principal_password.this.value\n  sensitive = true\n}\n```\n\n\u003c/details\u003e\n\n## Usage\n\n```bash\n# entrypoint.sh\nexport ARM_CLIENT_ID=\"00000000-0000-0000-0000-000000000000\"\nexport ARM_CLIENT_SECRET=\"12345678-0000-0000-0000-000000000000\"\nexport ARM_TENANT_ID=\"10000000-0000-0000-0000-000000000000\"\nexport ARM_SUBSCRIPTION_ID=\"20000000-0000-0000-0000-000000000000\"\n\nexport AKS_CLUSTER_NAME=something\nexport AKS_RESOURCE_GROUP_NAME=something-else\n\naz login --service-principal \\\n  -u \"${ARM_CLIENT_ID}\" \\\n  -p \"${ARM_CLIENT_SECRET}\" \\\n  --tenant ${ARM_TENANT_ID}\naz aks get-credentials \\\n  --name ${AKS_CLUSTER_NAME} \\\n  --resource-group ${AKS_RESOURCE_GROUP_NAME}\naz account set --subscription ${ARM_SUBSCRIPTION_ID}\n\nkubelogin convert-kubeconfig \\\n  --context ${AKS_CLUSTER_NAME} \\\n  --client-id \"${ARM_CLIENT_ID}\" \\\n  --tenant-id \"${ARM_TENANT_ID}\" \\\n  --client-secret \"${ARM_CLIENT_SECRET}\" \\\n  -l spn # \u003c-- service principal\n\n\n# This requires sufficient Kubernetes RBAC\nkubectl get pods\n```\n\n```bash\ndocker run --rm \\\n  --name azcli \\\n  -v $(pwd):/app:ro \\\n  ghcr.io/licenseware/azcli-aks:2.57.0 \\\n  bash -eux /app/entrypoint.sh\n```\n\n## FAQ\n\n### Why not use the azure-cli docker image instead?\n\nIt does not have the `kubelogin` installed, which is the [authenticator extension][kubelogin extension]\nthat allows for all the `kubectl` commands to work.\n\nBeside the official AZ CLI image doesn't have `kubectl` installed. This image\nhas both.\n\n[kubelogin extension]: https://github.com/Azure/kubelogin\n[AZ CLI Official Docker]: https://mcr.microsoft.com/en-us/product/azure-cli/tags\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flicenseware%2Fazcli-aks","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flicenseware%2Fazcli-aks","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flicenseware%2Fazcli-aks/lists"}