Skip to content

Commit af47f95

Browse files
committed
Clarify staging and target paths for blocks
The vague wording around the staging and target paths left open too many possible implementations for raw block volumes, and implementors ended up doing non-obvious things. This change clarifies the contract between the CO and the SP when staging and publishing raw block volumes on the node.
1 parent 7673c23 commit af47f95

File tree

3 files changed

+98
-95
lines changed

3 files changed

+98
-95
lines changed

csi.proto

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -980,11 +980,10 @@ message NodeStageVolumeRequest {
980980

981981
// The path to which the volume MAY be staged. It MUST be an
982982
// absolute path in the root filesystem of the process serving this
983-
// request. The CO SHALL ensure that there is only one
984-
// `staging_target_path` per volume. The CO SHALL ensure that the
985-
// process serving the request has `read` and `write` permission to
986-
// the path, and is able to create files or directories at the path
987-
// if it does not exist.
983+
// request, and MUST be a directory. The CO SHALL ensure that there
984+
// is only one `staging_target_path` per volume. The CO SHALL ensure
985+
// that the path is an existing directory and that process serving the
986+
// request has `read` and `write` permission to the directory.
988987
// This is a REQUIRED field.
989988
string staging_target_path = 3;
990989

@@ -1043,9 +1042,11 @@ message NodePublishVolumeRequest {
10431042
// The path to which the volume will be published. It MUST be an
10441043
// absolute path in the root filesystem of the process serving this
10451044
// request. The CO SHALL ensure uniqueness of target_path per volume.
1046-
// The CO SHALL ensure that the process serving the request has
1047-
// `read` and `write` permissions to the path, and is able to create
1048-
// files or directories at the path if it does not exist.
1045+
// The CO SHALL ensure that the path exists and that the process
1046+
// serving the request has `read` and `write` permissions to the path.
1047+
// For volumes with an access type of block, the path MUST be a file.
1048+
// For volumes with an access type of mount, the path MUST be a
1049+
// directory. The SP SHALL bind mount the volume to the target path.
10491050
// This is a REQUIRED field.
10501051
string target_path = 4;
10511052

0 commit comments

Comments
 (0)