This documentation is for a release that is no longer maintained
See documentation for the latest supported version 3 or the latest supported version 4.4.6.2. FlexVolume 드라이버 예
FlexVolume 드라이버의 첫 번째 명령줄 인수는 항상 작업 이름입니다. 다른 매개 변수는 각 작업에 따라 다릅니다. 대부분의 작업에서는 JSON(JavaScript Object Notation) 문자열을 매개변수로 사용합니다. 이 매개변수는 전체 JSON 문자열이며 JSON 데이터가 있는 파일 이름은 아닙니다.
FlexVolume 드라이버에는 다음이 포함됩니다.
-
모든
flexVolume.options
. -
fsType
및readwrite
와 같은kubernetes.io/
접두사가 붙은flexVolume
의 일부 옵션. -
설정된 경우,
kubernetes.io/secret/
이 접두사로 사용되는 참조된 시크릿의 콘텐츠
FlexVolume 드라이버 JSON 입력 예
OpenShift Container Platform은 드라이버의 표준 출력에서 JSON 데이터를 예상합니다. 지정하지 않으면, 출력이 작업 결과를 설명합니다.
FlexVolume 드라이버 기본 출력 예
{ "status": "<Success/Failure/Not supported>", "message": "<Reason for success/failure>" }
{
"status": "<Success/Failure/Not supported>",
"message": "<Reason for success/failure>"
}
드라이버의 종료 코드는 성공의 경우 0
이고 오류의 경우 1
이어야 합니다.
작업은 idempotent여야 합니다. 즉, 이미 마운트된 볼륨의 마운트의 경우 작업이 성공적으로 수행되어야 합니다.