replace no-remove by sample-volume-plugin in docs
Signed-off-by: Victor Vieux <vieux@docker.com>
(cherry picked from commit bcead9282e
)
Signed-off-by: Victor Vieux <vieux@docker.com>
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
This commit is contained in:
parent
84f25c7cb8
commit
4e9dd0e51c
11 changed files with 109 additions and 182 deletions
126
api/swagger.yaml
126
api/swagger.yaml
|
@ -1497,74 +1497,39 @@ definitions:
|
|||
type: "string"
|
||||
example:
|
||||
Id: "5724e2c8652da337ab2eedd19fc6fc0ec908e4bd907c7421bf6a8dfc70c4c078"
|
||||
Name: "tiborvass/no-remove"
|
||||
Name: "tiborvass/sample-volume-plugin"
|
||||
Tag: "latest"
|
||||
Active: true
|
||||
Config:
|
||||
Mounts:
|
||||
- Name: ""
|
||||
Description: ""
|
||||
Settable: null
|
||||
Source: "/data"
|
||||
Destination: "/data"
|
||||
Type: "bind"
|
||||
Options:
|
||||
- "shared"
|
||||
- "rbind"
|
||||
- Name: ""
|
||||
Description: ""
|
||||
Settable: null
|
||||
Source: null
|
||||
Destination: "/foobar"
|
||||
Type: "tmpfs"
|
||||
Options: null
|
||||
Settings:
|
||||
Env:
|
||||
- "DEBUG=1"
|
||||
- "DEBUG=0"
|
||||
Args: null
|
||||
Devices: null
|
||||
Manifest:
|
||||
ManifestVersion: "v0"
|
||||
Description: "A test plugin for Docker"
|
||||
Config:
|
||||
Description: "A sample volume plugin for Docker"
|
||||
Documentation: "https://docs.docker.com/engine/extend/plugins/"
|
||||
Interface:
|
||||
Types:
|
||||
- "docker.volumedriver/1.0"
|
||||
Socket: "plugins.sock"
|
||||
Entrypoint:
|
||||
- "plugin-no-remove"
|
||||
- "/usr/bin/sample-volume-plugin"
|
||||
- "/data"
|
||||
WorkDir: ""
|
||||
User: {}
|
||||
Network:
|
||||
Type: "host"
|
||||
Capabilities: null
|
||||
Mounts:
|
||||
- Name: ""
|
||||
Description: ""
|
||||
Settable: null
|
||||
Source: "/data"
|
||||
Destination: "/data"
|
||||
Type: "bind"
|
||||
Options:
|
||||
- "shared"
|
||||
- "rbind"
|
||||
- Name: ""
|
||||
Description: ""
|
||||
Settable: null
|
||||
Source: null
|
||||
Destination: "/foobar"
|
||||
Type: "tmpfs"
|
||||
Options: null
|
||||
Devices:
|
||||
- Name: "device"
|
||||
Description: "a host device to mount"
|
||||
Settable: null
|
||||
Path: "/dev/cpu_dma_latency"
|
||||
Type: ""
|
||||
Linux:
|
||||
Capabilities: null
|
||||
DeviceCreation: false
|
||||
Devices: null
|
||||
Mounts: null
|
||||
PropagatedMount: "/data"
|
||||
Env:
|
||||
- Name: "DEBUG"
|
||||
Description: "If set, prints debug messages"
|
||||
Settable: null
|
||||
Value: "1"
|
||||
Value: "0"
|
||||
Args:
|
||||
Name: "args"
|
||||
Description: "command line arguments"
|
||||
|
@ -6366,74 +6331,39 @@ paths:
|
|||
$ref: "#/definitions/Plugin"
|
||||
example:
|
||||
- Id: "5724e2c8652da337ab2eedd19fc6fc0ec908e4bd907c7421bf6a8dfc70c4c078"
|
||||
Name: "tiborvass/no-remove"
|
||||
Name: "tiborvass/sample-volume-plugin"
|
||||
Tag: "latest"
|
||||
Active: true
|
||||
Config:
|
||||
Mounts:
|
||||
- Name: ""
|
||||
Description: ""
|
||||
Settable: null
|
||||
Source: "/data"
|
||||
Destination: "/data"
|
||||
Type: "bind"
|
||||
Options:
|
||||
- "shared"
|
||||
- "rbind"
|
||||
- Name: ""
|
||||
Description: ""
|
||||
Settable: null
|
||||
Source: null
|
||||
Destination: "/foobar"
|
||||
Type: "tmpfs"
|
||||
Options: null
|
||||
Settings:
|
||||
Env:
|
||||
- "DEBUG=1"
|
||||
- "DEBUG=0"
|
||||
Args: null
|
||||
Devices: null
|
||||
Manifest:
|
||||
ManifestVersion: "v0"
|
||||
Description: "A test plugin for Docker"
|
||||
Config:
|
||||
Description: "A sample volume plugin for Docker"
|
||||
Documentation: "https://docs.docker.com/engine/extend/plugins/"
|
||||
Interface:
|
||||
Types:
|
||||
- "docker.volumedriver/1.0"
|
||||
Socket: "plugins.sock"
|
||||
Entrypoint:
|
||||
- "plugin-no-remove"
|
||||
- "/usr/bin/sample-volume-plugin"
|
||||
- "/data"
|
||||
WorkDir: ""
|
||||
User: {}
|
||||
Network:
|
||||
Type: "host"
|
||||
Capabilities: null
|
||||
Mounts:
|
||||
- Name: ""
|
||||
Description: ""
|
||||
Settable: null
|
||||
Source: "/data"
|
||||
Destination: "/data"
|
||||
Type: "bind"
|
||||
Options:
|
||||
- "shared"
|
||||
- "rbind"
|
||||
- Name: ""
|
||||
Description: ""
|
||||
Settable: null
|
||||
Source: null
|
||||
Destination: "/foobar"
|
||||
Type: "tmpfs"
|
||||
Options: null
|
||||
Devices:
|
||||
- Name: "device"
|
||||
Description: "a host device to mount"
|
||||
Settable: null
|
||||
Path: "/dev/cpu_dma_latency"
|
||||
Type: ""
|
||||
Linux:
|
||||
Capabilities: null
|
||||
DeviceCreation: false
|
||||
Devices: null
|
||||
Mounts: null
|
||||
PropagatedMount: "/data"
|
||||
Env:
|
||||
- Name: "DEBUG"
|
||||
Description: "If set, prints debug messages"
|
||||
Settable: null
|
||||
Value: "1"
|
||||
Value: "0"
|
||||
Args:
|
||||
Name: "args"
|
||||
Description: "command line arguments"
|
||||
|
|
|
@ -171,52 +171,49 @@ Config provides the base accessible fields for working with V0 plugin format
|
|||
|
||||
## Example Config
|
||||
|
||||
*Example showing the 'tiborvass/no-remove' plugin config.*
|
||||
*Example showing the 'tiborvass/sample-volume-plugin' plugin config.*
|
||||
|
||||
```json
|
||||
{
|
||||
"description": "A test plugin for Docker",
|
||||
"documentation": "https://docs.docker.com/engine/extend/plugins/",
|
||||
"entrypoint": ["plugin-no-remove", "/data"],
|
||||
"interface": {
|
||||
"types": ["docker.volumedriver/1.0"],
|
||||
"socket": "plugins.sock"
|
||||
},
|
||||
"network": {
|
||||
"type": "host"
|
||||
},
|
||||
"mounts": [
|
||||
{
|
||||
"source": "/data",
|
||||
"destination": "/data",
|
||||
"type": "bind",
|
||||
"options": ["shared", "rbind"]
|
||||
},
|
||||
{
|
||||
"destination": "/foobar",
|
||||
"type": "tmpfs"
|
||||
}
|
||||
],
|
||||
"args": {
|
||||
"name": "args",
|
||||
"description": "command line arguments",
|
||||
"value": []
|
||||
},
|
||||
"env": [
|
||||
{
|
||||
"name": "DEBUG",
|
||||
"description": "If set, prints debug messages",
|
||||
"value": "1"
|
||||
}
|
||||
],
|
||||
"linux": {
|
||||
"devices": [
|
||||
{
|
||||
"name": "device",
|
||||
"description": "a host device to mount",
|
||||
"path": "/dev/cpu_dma_latency"
|
||||
}
|
||||
]
|
||||
}
|
||||
"Args": {
|
||||
"Description": "",
|
||||
"Name": "",
|
||||
"Settable": null,
|
||||
"Value": null
|
||||
},
|
||||
"Description": "A sample volume plugin for Docker",
|
||||
"Documentation": "https://docs.docker.com/engine/extend/plugins/",
|
||||
"Entrypoint": [
|
||||
"/usr/bin/sample-volume-plugin",
|
||||
"/data"
|
||||
],
|
||||
"Env": [
|
||||
{
|
||||
"Description": "",
|
||||
"Name": "DEBUG",
|
||||
"Settable": [
|
||||
"value"
|
||||
],
|
||||
"Value": "0"
|
||||
}
|
||||
],
|
||||
"Interface": {
|
||||
"Socket": "plugin.sock",
|
||||
"Types": [
|
||||
"docker.volumedriver/1.0"
|
||||
]
|
||||
},
|
||||
"Linux": {
|
||||
"Capabilities": null,
|
||||
"DeviceCreation": false,
|
||||
"Devices": null
|
||||
},
|
||||
"Mounts": null,
|
||||
"Network": {
|
||||
"Type": ""
|
||||
},
|
||||
"PropagatedMount": "/data",
|
||||
"User": {},
|
||||
"Workdir": ""
|
||||
}
|
||||
```
|
||||
|
|
|
@ -194,8 +194,8 @@ relative to the current time on the client machine:
|
|||
2015-12-23T21:38:25.119625123Z network connect 8b111217944ba0ba844a65b13efcd57dc494932ee2527577758f939315ba2c5b (name=test-event-network-local, container=b4be644031a3d90b400f88ab3d4bdf4dc23adb250e696b6328b85441abe2c54e, type=bridge)
|
||||
|
||||
$ docker events --filter 'type=plugin' (experimental)
|
||||
2016-07-25T17:30:14.825557616Z plugin pull ec7b87f2ce84330fe076e666f17dfc049d2d7ae0b8190763de94e1f2d105993f (name=tiborvass/no-remove:latest)
|
||||
2016-07-25T17:30:14.888127370Z plugin enable ec7b87f2ce84330fe076e666f17dfc049d2d7ae0b8190763de94e1f2d105993f (name=tiborvass/no-remove:latest)
|
||||
2016-07-25T17:30:14.825557616Z plugin pull ec7b87f2ce84330fe076e666f17dfc049d2d7ae0b8190763de94e1f2d105993f (name=tiborvass/sample-volume-plugin:latest)
|
||||
2016-07-25T17:30:14.888127370Z plugin enable ec7b87f2ce84330fe076e666f17dfc049d2d7ae0b8190763de94e1f2d105993f (name=tiborvass/sample-volume-plugin:latest)
|
||||
|
||||
**Format:**
|
||||
|
||||
|
|
|
@ -30,27 +30,27 @@ see [`docker plugin install`](plugin_install.md). Without the `-f` option,
|
|||
a plugin that has references (eg, volumes, networks) cannot be disabled.
|
||||
|
||||
|
||||
The following example shows that the `no-remove` plugin is installed
|
||||
The following example shows that the `sample-volume-plugin` plugin is installed
|
||||
and enabled:
|
||||
|
||||
```bash
|
||||
$ docker plugin ls
|
||||
|
||||
ID NAME TAG DESCRIPTION ENABLED
|
||||
69553ca1d123 tiborvass/no-remove latest A test plugin for Docker true
|
||||
ID NAME TAG DESCRIPTION ENABLED
|
||||
69553ca1d123 tiborvass/sample-volume-plugin latest A test plugin for Docker true
|
||||
```
|
||||
|
||||
To disable the plugin, use the following command:
|
||||
|
||||
```bash
|
||||
$ docker plugin disable tiborvass/no-remove
|
||||
$ docker plugin disable tiborvass/sample-volume-plugin
|
||||
|
||||
tiborvass/no-remove
|
||||
tiborvass/sample-volume-plugin
|
||||
|
||||
$ docker plugin ls
|
||||
|
||||
ID NAME TAG DESCRIPTION ENABLED
|
||||
69553ca1d123 tiborvass/no-remove latest A test plugin for Docker false
|
||||
ID NAME TAG DESCRIPTION ENABLED
|
||||
69553ca1d123 tiborvass/sample-volume-plugin latest A test plugin for Docker false
|
||||
```
|
||||
|
||||
## Related information
|
||||
|
|
|
@ -29,27 +29,27 @@ Enables a plugin. The plugin must be installed before it can be enabled,
|
|||
see [`docker plugin install`](plugin_install.md).
|
||||
|
||||
|
||||
The following example shows that the `no-remove` plugin is installed,
|
||||
The following example shows that the `sample-volume-plugin` plugin is installed,
|
||||
but disabled:
|
||||
|
||||
```bash
|
||||
$ docker plugin ls
|
||||
|
||||
ID NAME TAG DESCRIPTION ENABLED
|
||||
69553ca1d123 tiborvass/no-remove latest A test plugin for Docker false
|
||||
ID NAME TAG DESCRIPTION ENABLED
|
||||
69553ca1d123 tiborvass/sample-volume-plugin latest A test plugin for Docker false
|
||||
```
|
||||
|
||||
To enable the plugin, use the following command:
|
||||
|
||||
```bash
|
||||
$ docker plugin enable tiborvass/no-remove
|
||||
$ docker plugin enable tiborvass/sample-volume-plugin
|
||||
|
||||
tiborvass/no-remove
|
||||
tiborvass/sample-volume-plugin
|
||||
|
||||
$ docker plugin ls
|
||||
|
||||
ID NAME TAG DESCRIPTION ENABLED
|
||||
69553ca1d123 tiborvass/no-remove latest A test plugin for Docker true
|
||||
ID NAME TAG DESCRIPTION ENABLED
|
||||
69553ca1d123 tiborvass/sample-volume-plugin latest A test plugin for Docker true
|
||||
```
|
||||
|
||||
## Related information
|
||||
|
|
|
@ -31,12 +31,12 @@ in a JSON array.
|
|||
Example output:
|
||||
|
||||
```bash
|
||||
$ docker plugin inspect tiborvass/no-remove:latest
|
||||
$ docker plugin inspect tiborvass/sample-volume-plugin:latest
|
||||
```
|
||||
```JSON
|
||||
{
|
||||
"Id": "8c74c978c434745c3ade82f1bc0acf38d04990eaf494fa507c16d9f1daa99c21",
|
||||
"Name": "tiborvass/no-remove:latest",
|
||||
"Name": "tiborvass/sample-volume-plugin:latest",
|
||||
"Enabled": true,
|
||||
"Config": {
|
||||
"Mounts": [
|
||||
|
@ -79,7 +79,7 @@ $ docker plugin inspect tiborvass/no-remove:latest
|
|||
"Socket": "plugins.sock"
|
||||
},
|
||||
"Entrypoint": [
|
||||
"plugin-no-remove",
|
||||
"plugin-sample-volume-plugin",
|
||||
"/data"
|
||||
],
|
||||
"Workdir": "",
|
||||
|
@ -143,7 +143,7 @@ $ docker plugin inspect tiborvass/no-remove:latest
|
|||
|
||||
|
||||
```bash
|
||||
$ docker plugin inspect -f '{{.Id}}' tiborvass/no-remove:latest
|
||||
$ docker plugin inspect -f '{{.Id}}' tiborvass/sample-volume-plugin:latest
|
||||
```
|
||||
```
|
||||
8c74c978c434745c3ade82f1bc0acf38d04990eaf494fa507c16d9f1daa99c21
|
||||
|
|
|
@ -33,20 +33,20 @@ the registry. Note that the minimum required registry version to distribute
|
|||
plugins is 2.3.0
|
||||
|
||||
|
||||
The following example installs `no-remove` plugin and [set](plugin_set.md) it's env variable
|
||||
The following example installs `vieus/sshfs` plugin and [set](plugin_set.md) it's env variable
|
||||
`DEBUG` to 1. Install consists of pulling the plugin from Docker Hub, prompting
|
||||
the user to accept the list of privileges that the plugin needs, settings parameters
|
||||
and enabling the plugin.
|
||||
|
||||
```bash
|
||||
$ docker plugin install tiborvass/no-remove DEBUG=1
|
||||
$ docker plugin install vieux/sshfs DEBUG=1
|
||||
|
||||
Plugin "tiborvass/no-remove" is requesting the following privileges:
|
||||
Plugin "vieux/sshfs" is requesting the following privileges:
|
||||
- network: [host]
|
||||
- mount: [/data]
|
||||
- device: [/dev/cpu_dma_latency]
|
||||
- device: [/dev/fuse]
|
||||
- capabilities: [CAP_SYS_ADMIN]
|
||||
Do you grant the above permissions? [y/N] y
|
||||
tiborvass/no-remove
|
||||
vieux/sshfs
|
||||
```
|
||||
|
||||
After the plugin is installed, it appears in the list of plugins:
|
||||
|
@ -55,7 +55,7 @@ After the plugin is installed, it appears in the list of plugins:
|
|||
$ docker plugin ls
|
||||
|
||||
ID NAME TAG DESCRIPTION ENABLED
|
||||
69553ca1d123 tiborvass/no-remove latest A test plugin for Docker true
|
||||
69553ca1d123 vieux/sshfs latest sshFS plugin for Docker true
|
||||
```
|
||||
|
||||
## Related information
|
||||
|
|
|
@ -36,8 +36,8 @@ Example output:
|
|||
```bash
|
||||
$ docker plugin ls
|
||||
|
||||
ID NAME TAG DESCRIPTION ENABLED
|
||||
69553ca1d123 tiborvass/no-remove latest A test plugin for Docker true
|
||||
ID NAME TAG DESCRIPTION ENABLED
|
||||
69553ca1d123 tiborvass/sample-volume-plugin latest A test plugin for Docker true
|
||||
```
|
||||
|
||||
## Related information
|
||||
|
|
|
@ -33,14 +33,14 @@ a plugin using the [`docker plugin disable`](plugin_disable.md) before removing
|
|||
it (or use --force, use of force is not recommended, since it can affect
|
||||
functioning of running containers using the plugin).
|
||||
|
||||
The following example disables and removes the `no-remove:latest` plugin;
|
||||
The following example disables and removes the `sample-volume-plugin:latest` plugin;
|
||||
|
||||
```bash
|
||||
$ docker plugin disable tiborvass/no-remove
|
||||
tiborvass/no-remove
|
||||
$ docker plugin disable tiborvass/sample-volume-plugin
|
||||
tiborvass/sample-volume-plugin
|
||||
|
||||
$ docker plugin rm tiborvass/no-remove:latest
|
||||
tiborvass/no-remove
|
||||
$ docker plugin rm tiborvass/sample-volume-plugin:latest
|
||||
tiborvass/sample-volume-plugin
|
||||
```
|
||||
|
||||
## Related information
|
||||
|
|
|
@ -33,15 +33,15 @@ The settings currently supported are:
|
|||
* args
|
||||
|
||||
The following example change the env variable `DEBUG` on the
|
||||
`no-remove` plugin.
|
||||
`sample-volume-plugin` plugin.
|
||||
|
||||
```bash
|
||||
$ docker plugin inspect -f {{.Settings.Env}} tiborvass/no-remove
|
||||
$ docker plugin inspect -f {{.Settings.Env}} tiborvass/sample-volume-plugin
|
||||
[DEBUG=0]
|
||||
|
||||
$ docker plugin set tiborvass/no-remove DEBUG=1
|
||||
$ docker plugin set tiborvass/sample-volume-plugin DEBUG=1
|
||||
|
||||
$ docker plugin inspect -f {{.Settings.Env}} tiborvass/no-remove
|
||||
$ docker plugin inspect -f {{.Settings.Env}} tiborvass/sample-volume-plugin
|
||||
[DEBUG=1]
|
||||
```
|
||||
|
||||
|
|
|
@ -168,8 +168,8 @@ Lines. For information about JSON Lines, please refer to http://jsonlines.org/ .
|
|||
2015-12-23T21:38:25.119625123Z network connect 8b111217944ba0ba844a65b13efcd57dc494932ee2527577758f939315ba2c5b (name=test-event-network-local, container=b4be644031a3d90b400f88ab3d4bdf4dc23adb250e696b6328b85441abe2c54e, type=bridge)
|
||||
|
||||
$ docker events --filter 'type=plugin' (experimental)
|
||||
2016-07-25T17:30:14.825557616Z plugin pull ec7b87f2ce84330fe076e666f17dfc049d2d7ae0b8190763de94e1f2d105993f (name=tiborvass/no-remove:latest)
|
||||
2016-07-25T17:30:14.888127370Z plugin enable ec7b87f2ce84330fe076e666f17dfc049d2d7ae0b8190763de94e1f2d105993f (name=tiborvass/no-remove:latest)
|
||||
2016-07-25T17:30:14.825557616Z plugin pull ec7b87f2ce84330fe076e666f17dfc049d2d7ae0b8190763de94e1f2d105993f (name=tiborvass/sample-volume-plugin:latest)
|
||||
2016-07-25T17:30:14.888127370Z plugin enable ec7b87f2ce84330fe076e666f17dfc049d2d7ae0b8190763de94e1f2d105993f (name=tiborvass/sample-volume-plugin:latest)
|
||||
|
||||
|
||||
# HISTORY
|
||||
|
|
Loading…
Reference in a new issue