본문으로 바로가기 본문 바로가기
WIKI 기술 지식 베이스

calicoctl datastore migrate import

원문 보기 위키 갱신

이 섹션은 calicoctl datastore migrate import 명령을 설명해요.

calicoctl 명령 전체 목록은 calicoctl 개요를 참고하세요.

출처: calicoctl datastore migrate import

본문

'calicoctl datastore migrate import' 명령의 도움말 보기

calicoctl datastore migrate import --help를 실행하면 다음과 같은 도움말 메뉴가 표시돼요.

Import resources from a YAML export into a Kubernetes datastore. Takes the
output of datastore migrate export and loads it into the Kubernetes-backed
datastore.

Usage:
  calicoctl datastore migrate import [flags]

Examples:
  calicoctl datastore migrate import -f datastore.yaml

Flags:
  -c, --config string     Path to the file containing connection configuration in YAML or JSON format. (default "/etc/calico/calicoctl.cfg")
  -f, --filename string   Filename to use to import resources.
  -h, --help              help for import

Global Flags:
      --allow-version-mismatch   Allow client and cluster versions mismatch
      --context string           The name of the kubeconfig context to use
  -l, --log-level string         Set the log level (panic, fatal, error, warn, info, debug) (default "panic")

예제

etcd-migration이라는 파일에 저장된 etcdv3 데이터스토어 내용을 가져와요.

calicoctl datastore migrate import -f etcd-migration

옵션

-f, --filename string   Filename to use to import resources.

일반 옵션

-c, --config string   Path to the file containing connection configuration in YAML or JSON format. (default "/etc/calico/calicoctl.cfg")

더 알아보기 (See also)

더 알아보기 (Learn more)

migrate import는 migrate export가 만든 YAML 내보내기를 쿠버네티스 기반 데이터스토어로 불러오는 명령이에요. -f로 파일을 지정해요. 마이그레이션 전체 흐름에서는 lock → export → import → unlock 순서를 따라가요.