GCP - Associate Cloud Engineer 준비기
GCP Certification 취득을 위해 공부합니다. GCP 전반에 대한 내용을 다룹니다.
정리된 내용은 “Udemy-GCP Associate Cloud Engineer - Google Cloud Certification” 강의를 기반으로 합니다.
Gcloud
GCP 자원들을 사용하기 위한 Command Line Interface(CLI)
- GCP 자원의 75%는
Gcloud로 제어 가능 - googlc cloud SDK 설치하여 사용하거나, 웹 콘솔의 cloud shell에서 사용 가능
Configuration
gcloud init: Gcloud 초기화gcloud config list: config 리스트 조회gcloud config set compute/region VALUE: config 설정gcloud config unset compute/region VALUE: config 해제gcloud config configurations create|activate|describe|delete|list: 여러 config 대한 작업
Gcloud Command
명령어 구조
gcloud GROUP SUBGROUP ACTION ...
- GROUP : config, compute, container, dataflow, functions, iam …
- SUBGROUP : instances, images, instance-templates, machine-types, regions, zones
- ACTION : create, list, start, stop, describe
CREATE
- instance 생성 :
gcoud compute instances create INSTANCE
Default Regions and Zones
- Centralized Configuration :
gcloud compute project-info add-metadata - Local Gcoud Configuration :
gcloud config set compute/region REGION - Command Specific :
--zone,--region
-> 우선순위 : 3 > 2 > 1
List
- 자원 집합의 리스트를 출력 :
gcloud compute RESOURCES list -
옵션
--filter="zone:VALUE"또는--filter="zone:(VALUE1 VALUE2)": 단일 필터, 다중 필터--sort-by(VALUE or ~VALUE): 순, 역순--uri: 콘솔 접속 URL
Describe
- 특정 자원 상세 설명을 조회 :
gcloud compute regions describe us-west1
