이 명령어는 포드에서 프로세스를 생성하는 Kubernetes 제어 영역 연결을 열어서 CF의 SSH 명령어를 모방합니다.
이 명령어는 앱의 런타임 라벨과 일치하는 임의 포드에 연결됩니다. 특정 Pod를 원하는 경우 해당 pod/ 표기법을 사용합니다.
참고: CLI와 제어 영역 그리고 제어 영역과 포드 사이의 트래픽이 암호화됩니다. 악의적인 Kubernetes 제어 영역이 트래픽을 관찰할 수 있습니다.
예
# Open a shell to a specific App
kf ssh myapp
# Open a shell to a specific Pod
kf ssh pod/myapp-revhex-podhex
# Start a different command with args
kf ssh myapp -c /my/command -c arg1 -c arg2
플래그
-c, --command=stringArray
셸에서 실행할 명령어입니다. 후속 정의는 인수로 사용됩니다. (기본값 [/bin/bash])
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["이해하기 어려움","hardToUnderstand","thumb-down"],["잘못된 정보 또는 샘플 코드","incorrectInformationOrSampleCode","thumb-down"],["필요한 정보/샘플이 없음","missingTheInformationSamplesINeed","thumb-down"],["번역 문제","translationIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-09-04(UTC)"],[],[],null,["# kf ssh\n\n### Name\n\n`kf ssh` - Open a shell on an App instance.\n\n### Synopsis\n\n```\nkf ssh APP_NAME [flags]\n```\n\n### Description\n\nOpens a shell on an App instance using the Pod exec endpoint.\n\nThis command mimics CF's SSH command by opening a connection to the\nKubernetes control plane which spawns a process in a Pod.\n\nThe command connects to an arbitrary Pod that matches the App's runtime\nlabels. If you want a specific Pod, use the pod/ notation.\n\nNOTE: Traffic is encrypted between the CLI and the control plane, and\nbetween the control plane and Pod. A malicious Kubernetes control plane\ncould observe the traffic.\n\n### Examples\n\n```\n# Open a shell to a specific App\nkf ssh myapp\n\n# Open a shell to a specific Pod\nkf ssh pod/myapp-revhex-podhex\n\n# Start a different command with args\nkf ssh myapp -c /my/command -c arg1 -c arg2\n```\n\n### Flags\n\n`-c, --command=`\u003cvar translate=\"no\"\u003estringArray\u003c/var\u003e\n\n: Command to run for the shell. Subsequent definitions will be used as args. (default \\[/bin/bash\\])\n\n`--container=`\u003cvar translate=\"no\"\u003estring\u003c/var\u003e\n\n: Container to start the command in. (default \"user-container\")\n\n`-T, --disable-pseudo-tty`\n\n: Don't use a TTY when executing.\n\n`-h, --help`\n\n: help for ssh\n\n### Inherited flags\n\nThese flags are inherited from parent commands.\n\n`--as=`\u003cvar translate=\"no\"\u003estring\u003c/var\u003e\n\n: Username to impersonate for the operation.\n\n`--as-group=`\u003cvar translate=\"no\"\u003estrings\u003c/var\u003e\n\n: Group to impersonate for the operation. Include this flag multiple times to specify multiple groups.\n\n`--config=`\u003cvar translate=\"no\"\u003estring\u003c/var\u003e\n\n: Path to the Kf config file to use for CLI requests.\n\n`--kubeconfig=`\u003cvar translate=\"no\"\u003estring\u003c/var\u003e\n\n: Path to the kubeconfig file to use for CLI requests.\n\n`--log-http`\n\n: Log HTTP requests to standard error.\n\n`--space=`\u003cvar translate=\"no\"\u003estring\u003c/var\u003e\n\n: Space to run the command against. This flag overrides the currently targeted Space."]]