Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Info

사전 조건 (참조: https://docs.microsoft.com/ko-kr/azure/aks/kubernetes-walkthrough)


Code Block
titleazure-cli 설치
## Microsoft 리포지토리 키를 가져옵니다.
[root@workspace-vm deploy~]# cd ~/ sudo rpm --import https://packages.microsoft.com/keys/microsoft.asc
[root@workspace-vm ~]# 

## 로컬 azure-cli 리포지토리 정보를 만듭니다.
[root@workspace-vm ~]# curl -L  sudo sh -c 'echo -e "[azure-cli]\nname=Azure CLI\nbaseurl=https://packages.microsoft.com/yumrepos/azure-cli\nenabled=1\ngpgcheck=1\ngpgkey=https://packages.microsoft.com/keys/microsoft.asc" > /etc/yum.repos.d/azure-cli.repo'
[root@workspace-vm ~]# 

## azure-cli를 설치 합니다.
[root@workspace-vm ~]# sudo yum install azure-cli
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile


Code Block
## Azure에 로그인 합니다.
[root@workspace-vm ~]# az login
To sign in, use a web browser to open the page https://microsoft.com/devicelogin and enter the code HT3WTWGFJ to authenticate.
[
  {
    "cloudName": "AzureCloud",
    "id": "c6c1cb6d-3a2b-4912-9506-e54767670dbf",
    "isDefault": false,
    "name": "종량제",
    "state": "Disabled",
    "tenantId": "075f7662-60f9-46bb-9158-787589dee498",
    "user": {
      "name": "sooabia22@sptek.co.kr",
      "type": "user"
    }
  },
  {
    "cloudName": "AzureCloud",
    "id": "24ebf866-0c20-435b-af0f-e54c1c28f835",
    "isDefault": true,
    "name": "Visual Studio Enterprise",
    "state": "Enabled",
    "tenantId": "075f7662-60f9-46bb-9158-787589dee498",
    "user": {
      "name": "sooabia22@sptek.co.kr",
      "type": "user"
    }
  }
]
[root@workspace-vm ~]# 
[root@workspace-vm ~]# az account show
{
  "environmentName": "AzureCloud",
  "id": "24ebf866-0c20-435b-af0f-e54c1c28f835",
  "isDefault": true,
  "name": "Visual Studio Enterprise",
  "state": "Enabled",
  "tenantId": "075f7662-60f9-46bb-9158-787589dee498",
  "user": {
    "name": "sooabia22@sptek.co.kr",
    "type": "user"
  }
}aka.ms/InstallAzureCli | bash
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100  1369  100  1369    0     0    993      0  0:00:01  0:00:01 --:--:--  5900
Downloading Azure CLI install script from https://azurecliprod.blob.core.windows.net/install.py to /tmp/azure_cli_install_tmp_FM39Xy.
######################################################################## 100.0%

## 변경 내용을 적용하려면 셸을 다시 시작해야 합니다.