Skip to content

NodePublishVolume target_path needs additional clarifications #60

@julian-hj

Description

@julian-hj

The spec says:

  // The path to which the volume will be published. It MUST be an
  // absolute path in the root filesystem of the process serving this
  // request. This is a REQUIRED field.
  string target_path = 5;

However, the spec doesn't describe:

  1. Whether the plugin should expect the directory at the target_path to already be created by the CO or the plugin is responsible for creating the directory at target_path itself.
  2. If the CO pre-creates the directory, what permissions the plugin can expect it to have.
  3. If the plugin must create the directory, what permissions the parent path should have.
  4. If more than one directory in the path must be created by the plugin, what permissions the parent directories should be given in order to not break other plugins that will perhaps use the same path.

Points 2 and 3 are mainly relevant for plugins that use fuse mounts and will not run with CAP_SYS_ADMIN. One advantage to allowing the plugin to determine its own mountpoint is that the plugin can be responsible for making sure that it has create rights on the path where the mount points will go, even if it is running as some arbitrary non-root user.

As the spec is written, the CO is responsible for dictating the mount path so I suppose that the mount points must be open for world write, or the CO needs some way to know what user the plugin will run as and chown the directory to that user.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions