6.2. CLI를 사용하여 Azure에 인스턴스 배포
Azure 웹 콘솔 또는 CLI에서 새 RHEL AI Azure 이미지로 인스턴스를 시작할 수 있습니다. 인스턴스를 시작할 배포 방법을 사용할 수 있습니다. 다음 절차에서는 CLI를 사용하여 사용자 정의 Azure 이미지로 Azure 인스턴스를 시작하는 방법을 표시합니다.
CLI를 배포 옵션으로 사용하도록 선택하는 경우 "사전 요구 사항"에 표시된 대로 생성해야 하는 여러 구성이 있습니다.
사전 요구 사항
- RHEL AI Azure 이미지를 생성하셨습니다. 자세한 내용은 "RHEL AI 이미지를 Azure 이미지로 변환"을 참조하십시오.
- 특정 머신에 Azure CLI를 설치한 경우 Linux에 Azure CLI 설치를 참조하십시오.
프로세스
다음 명령을 실행하여 Azure 계정에 로그인합니다.
$ az login배포에 사용할 인스턴스 프로필을 선택해야 합니다. 다음 명령을 실행하여 원하는 리전의 모든 프로필을 나열합니다.
$ az vm list-sizes --location <region> --output table인스턴스 배포에 필요한 기본 인스턴스 프로필을 기록해 두십시오.
이제 Azure 인스턴스 만들기를 시작할 수 있습니다. 인스턴스를 생성할 때 에 대한 환경 변수를 채웁니다.
name=my-rhelai-instance az_location=eastus az_resource_group=my_resource_group az_admin_username=azureuser az_vm_size=Standard_ND96isr_H100_v5 az_image=my-custom-rhelai-image sshpubkey=$HOME/.ssh/id_rsa.pub disk_size=1024다음 명령을 실행하여 인스턴스를 시작할 수 있습니다.
$ az vm create \ --resource-group $az_resource_group \ --name ${name} \ --image ${az_image} \ --size ${az_vm_size} \ --location ${az_location} \ --admin-username ${az_admin_username} \ --ssh-key-values @$sshpubkey \ --authentication-type ssh \ --nic-delete-option Delete \ --accelerated-networking true \ --os-disk-size-gb 1024 \ --os-disk-name ${name}-${az_location}
검증
Red Hat Enterprise Linux AI 툴이 올바르게 설치되었는지 확인하려면
ilab명령을 실행합니다.$ ilab출력 예
$ ilab Usage: ilab [OPTIONS] COMMAND [ARGS]... CLI for interacting with InstructLab. If this is your first time running ilab, it's best to start with `ilab config init` to create the environment. Options: --config PATH Path to a configuration file. [default: /home/<user>/.config/instructlab/config.yaml] -v, --verbose Enable debug logging (repeat for even more verbosity) --version Show the version and exit. --help Show this message and exit. Commands: config Command Group for Interacting with the Config of InstructLab. data Command Group for Interacting with the Data generated by... model Command Group for Interacting with the Models in InstructLab. system Command group for all system-related command calls taxonomy Command Group for Interacting with the Taxonomy of InstructLab. Aliases: chat model chat generate data generate serve model serve train model train
Updating Red Hat Enterprise Linux AI
최신 RHEL AI 버전으로 업데이트하려면 Red Hat Enterprise Linux AI 업데이트 설명서의 절차를 따르십시오.