관리자 워크스테이션 만들기(빠른 시작)

이 문서에서는 클러스터를 만드는 데 사용할 수 있는 VMware용 Anthos 클러스터(GKE On-Prem)의 관리자 워크스테이션을 만드는 방법을 설명합니다.

여기 제시된 안내는 빠른 시작의 일부입니다. 관리자 워크스테이션을 만드는 방법에 대한 자세한 안내는 관리자 워크스테이션 만들기를 참조하세요.

시작하기 전에

Google Cloud 프로젝트를 만듭니다(빠른 시작).

서비스 계정을 만듭니다(빠른 시작).

vCenter 서버 주소CA 인증서 경로를 확인합니다.

구성 파일용 템플릿 생성

이 문서의 단계에서는 64비트 Linux, Windows 10, Windows Server 2019, macOS 10.15 이상에서 사용할 수 있는 gkeadm 명령줄 도구를 사용합니다.

현재 디렉터리로 gkeadm을 다운로드합니다.

템플릿을 생성합니다.

./gkeadm create config

위 명령어를 실행하면 현재 디렉터리에 다음 파일이 만들어집니다.

  • credential.yaml
  • admin-ws-config.yaml

credential.yaml 입력

credential.yaml에 vCenter 사용자 이름과 비밀번호를 입력합니다. 예를 들면 다음과 같습니다.

kind: CredentialFile
items:
- name: vCenter
  username: "my-account-name"
  password: "AadmpqGPqq!a"

admin-ws-config.yaml 입력

다음 필드가 자동으로 입력됩니다.

vCenter:
  credentials:
    fileRef:
    path: credential.yaml
    entry: vCenter

adminWorkstation:
  name: gke-admin-ws-...
  cpus: 4
  memoryMB: 8192

  diskGB: 50
  dataDiskName: gke-on-prem-admin-workstation-data-disk,,,.vmdk
  dataDiskMB: 512
  network:
    ntpServer: ntp.ubuntu.com

다음 필수 필드를 입력합니다. 필드를 입력하는 방법에 대한 자세한 내용은 관리자 워크스테이션 구성 파일을 참조하세요.

gcp:
   whitelistedServiceAccountKeyPath: "Fill in"
vCenter:
  credentials:
    address: "Fill in"
  datacenter: "Fill in"
  datastore: "Fill in"
  cluster: "Fill in"
  network: "Fill in"
  resourcePool: "Fill in"
  caCertPath: "Fill in"

network:
  hostConfig:
    ipAllocationMode: Fill in. Set to "static".
    ip: "Fill in"
    gateway: "Fill in"
    netmask: "Fill in"

필요한 경우 proxyURL 필드를 입력합니다.

adminWorkstation:
  proxyURL: "Fill in"

관리자 워크스테이션 만들기

관리자 워크스테이션을 만들고 서비스 계정을 자동으로 만듭니다.

./gkeadm create admin-workstation --auto-create-service-accounts

출력은 관리자 워크스테이션 생성에 대한 자세한 정보를 제공합니다.

...
Getting ... service account...

Creating other service accounts and JSON key files...
    - connect-agent-sa-2007081316
    - connect-register-sa-2007081316
    - log-mon-sa-2007081316
********************************************************************
Admin workstation is ready to use.

Admin workstation information saved to /usr/local/google/home/me/my-admin-workstation
This file is required for future upgrades
SSH into the admin workstation with the following command:
ssh -i /usr/local/google/home/me/.ssh/gke-admin-workstation ubuntu@172.16.5.1
********************************************************************

관리자 워크스테이션으로 SSH 연결 가져오기

이전 출력의 끝부분에 관리자 워크스테이션으로 SSH 연결을 가져오는 데 사용할 수 있는 명령어가 있습니다. 지금 명령어를 입력합니다. 예를 들면 다음과 같습니다.

ssh -i /usr/local/google/home/me/.ssh/gke-admin-workstation ubuntu@172.16.5.1

관리자 워크스테이션의 파일을 나열합니다.

ls -1

출력에서 두 개의 클러스터 구성 파일, CA 인증서 파일, 서비스 계정의 JSON 키 파일을 볼 수 있습니다.

admin-cluster.yaml
connect-agent-sa-2007081316.json
connect-register-sa-2007081316.json
log-mon-sa-2007081316.json
user-cluster.yaml
vcenter-ca-cert.pem
component-access-key.json

다음 단계

Seesaw 부하 분산기(빠른 시작)