gnoi icon indicating copy to clipboard operation
gnoi copied to clipboard

containerz volume driver enum

Open LimeHat opened this issue 5 months ago • 3 comments

Currently volume drivers are defined as enum but this makes it impossible to use a custom driver (plugins have names and there's no field to specify the name) https://github.com/openconfig/gnoi/blob/d04468fba8d73905e7865fcfd0076a48523f71e6/containerz/containerz.proto#L636-L645

The field must be of type string instead (unless you intend to enumerate all possible drivers)

@robshakir @alshabib

LimeHat avatar Jul 20 '25 00:07 LimeHat

Afaics, it should be possible to specify DS_CUSTOM driver and then add CustomOptions for the name of the driver among other parameters.

LarsxGitHub avatar Jul 28 '25 10:07 LarsxGitHub

Current definition implies that the options are opaque to the gnoi speaker and only passed to the driver itself (It is also how it is used in Docker) https://github.com/openconfig/gnoi/blob/d04468fba8d73905e7865fcfd0076a48523f71e6/containerz/containerz.proto#L683-L684

While your statement is technically correct, it will be a very odd construct (allocating a fixed option name that gnoi server should parse and strip from the other options).

I'd suggest doing it the right way.

LimeHat avatar Aug 21 '25 18:08 LimeHat

For reference here's the docker api docs: https://github.com/moby/moby/blob/ea126c054103628f900e64046e946adf7e98148f/api/docs/v1.52.yaml#L2369-L2385

LimeHat avatar Aug 21 '25 20:08 LimeHat