Commit Graph

164 Commits

Author SHA1 Message Date
Sebastiaan van Stijn e4fc8cfa23
docs/extend: reformat notes
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-04-19 17:53:06 +02:00
Sebastiaan van Stijn 824a9ce64b
docs: update code-hints for compatibility with "rouge"
Unlike GitHub's web-UI, the "rouge" hightlighter used in our
online documentation is case-sensitive. As a result, code-blocks
having the Dockerfile (uppercase) code-hint were not highlighted.

This changes those to use lowercase, which is supported by both.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2020-03-17 15:01:52 +01:00
Stefan Scherer 4d3a76d71e
Search Windows CLI plugins also in ProgramFiles
Signed-off-by: Stefan Scherer <stefan.scherer@docker.com>
2019-03-20 11:45:03 -07:00
Ian Campbell 4eb642be46 Add a field to the config file for plugin use.
This is a bit manual (as the unit test attests) so we may find we want to add
some helpers/accessors, but this is enough to let plugins use it and to
preserve the information through round-trips.

Signed-off-by: Ian Campbell <ijc@docker.com>
2019-02-25 10:38:48 +00:00
Ian Campbell 891b3d953e cli-plugins: use `docker system dial-stdio` to call the daemon
This means that plugins can use whatever methods the monolithic CLI supports,
which is good for consistency.

This relies on `os.Args[0]` being something which can be executed again to
reach the same binary, since it is propagated (via an envvar) to the plugin for
this purpose. This essentially requires that the current working directory and
path are not modified by the monolithic CLI before it launches the plugin nor
by the plugin before it initializes the client. This should be the case.

Previously the fake apiclient used by `TestExperimentalCLI` was not being used,
since `cli.Initialize` was unconditionally overwriting it with a real one
(talking to a real daemon during unit testing, it seems). This wasn't expected
nor desirable and no longer happens with the new arrangements, exposing the
fact that no `pingFunc` is provided, leading to a panic. Add a `pingFunc` to
the fake client to avoid this.

Signed-off-by: Ian Campbell <ijc@docker.com>
2019-02-18 11:53:37 +00:00
Ian Campbell 609dcb9152 Documentation on writing a plugin
Signed-off-by: Ian Campbell <ijc@docker.com>
2019-01-30 13:45:26 +00:00
Anusha Ragunathan 5fd9eab3d0 Update examples to reflect docker-runc's runtime root for plugins.
Signed-off-by: Anusha Ragunathan <anusha.ragunathan@docker.com>
2018-04-05 12:14:59 -07:00
Misty Stanley-Jones 16d29b3cd6 Clarify network plugins and swarm mode
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2018-02-08 14:08:31 -08:00
doncicuto 3e6e54a90f Update Flocker plugin link
ClusterHQ shutted down at the end of 2016. It seems that ScatterHQ is a group of ClusterHQ former employees that have forked Flocker. It seems that no code has been commited in the last months but if somebody comes to this Docker page it should be referenced to ScatterHQ.

Signed-off-by: Miguel Angel Alvarez Cabrerizo <doncicuto@gmail.com>
2017-11-28 13:51:08 +01:00
Skip e575b8e756 Docs - Typo in volume plugin doc
There is a typo in the `plugins_volume.md#volumedriverpath` section.
The `/VolumeDriver.Path` response (v1) should be `Mountpoint`and not `Mountpoin`.

Signed-off-by: scipio3000 <gunther@gameslabs.net>
Signed-off-by: Günther Jungbluth <gunther@gameslabs.net>
2017-11-20 15:56:09 +01:00
Abdur Rehman c3fe9d85ef fix a number of minor typos
Fix 19 typos, grammatical errors and duplicated words.

These fixes have minimal impact on the code as these are either in the
doc files or in comments inside the code files.

Signed-off-by: Abdur Rehman <abdur_rehman@mentor.com>
2017-10-31 15:21:51 +05:00
John Mulhausen 4a5db8d27e
Removing titles from md files
Signed-off-by: John Mulhausen <john@docker.com>
2017-10-13 15:24:06 -07:00
Frieder Bluemle 45c9b9b6c1
Fix GitHub spelling
Signed-off-by: Frieder Bluemle <frieder.bluemle@gmail.com>
2017-10-05 01:14:31 +08:00
Misty Stanley-Jones eb77961399 Revert "Change sshfs by cloudstor on Installing and using a plugin"
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2017-09-07 10:15:59 -07:00
Julien Maitrehenry e97d72334f Change sshfs by cloudstor on Installing and using a plugin
Signed-off-by: Julien Maitrehenry <julien.maitrehenry@me.com>
2017-09-01 14:42:01 -04:00
Sebastiaan van Stijn d30987f85f
Fix "liquid" warning on logging plugins page
Noticed this warning in the documentation CI:

    Liquid Warning: Liquid syntax error (line 210): Expected end_of_string but found id in "{{ log stream }}" in engine/extend/plugins_logging.md

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2017-08-17 00:56:54 +02:00
Harald Albers 2dca576a4c Fix invalid plugin references in docs
The plugins `tiborvass/sample-volume-plugins` and `tiborvass/no-remove`
do not exist.

Signed-off-by: Harald Albers <github@albersweb.de>
2017-08-07 11:15:39 +02:00
Misty Stanley-Jones 83e8551876 Add Infinit plugin
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2017-08-01 15:50:42 -07:00
Kir Kolyshkin 6d85a4f5f8 Fix repo references in docs
Since CLI was moved to a separate repo, these references are incorrect.
Fixed with the help of sed script, verified manually.

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2017-07-28 10:32:42 -07:00
Misty Stanley-Jones ede69a38c2 Fix small typo
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2017-06-21 11:06:26 -07:00
Sebastiaan van Stijn 8b11d46ecd Merge pull request #33572 from hsluoyz/patch-1
Add Casbin plugin to the list of Authorization plugins in docs.
(cherry picked from commit 220831d541bfe9bf566c1038773198d431560dd3)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
(cherry picked from commit 0ad3e3294e74f443130b5e1fb1ef6b31f4f92366)
Signed-off-by: Tibor Vass <tibor@docker.com>
2017-06-14 02:48:46 +00:00
Brian Goff d8e04f68d3 Add support for metrics plugins
Allows for a plugin type that can be used to scrape metrics.
This is useful because metrics are not neccessarily at a standard
location... `--metrics-addr` must be set, and must currently be a TCP
socket.
Even if metrics are done via a unix socket, there's no guarentee where
the socket may be located on the system, making bind-mounting such a
socket into a container difficult (and racey, failure-prone on daemon
restart).

Metrics plugins side-step this issue by always listening on a unix
socket and then bind-mounting that into a known path in the plugin
container.

Note there has been similar work in the past (and ultimately punted at
the time) for consistent access to the Docker API from within a
container.

Why not add metrics to the Docker API and just provide a plugin with
access to the Docker API? Certainly this can be useful, but gives a lot
of control/access to a plugin that may only need the metrics. We can
look at supporting API plugins separately for this reason.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2017-06-02 00:11:05 +00:00
Michael Friis 542af38ce5 fix typo in plugins_logging.md
Signed-off-by: Michael Friis <friism@gmail.com>
2017-06-02 00:11:04 +00:00
yuexiao-wang 852a861b8e fix errors in config
Signed-off-by: yuexiao-wang <wang.yuexiao@zte.com.cn>
2017-06-02 00:11:04 +00:00
Julien Kassar ba5a2dc787 Update legacy_plugins.md to include HBM authz plugin
Signed-off-by: Julien Kassar <github@kassisol.com>
2017-06-02 00:11:04 +00:00
Alfred Landrum 4b8712eacb Let graphdrivers declare diff stream fidelity
This allows graphdrivers to declare that they can reproduce the original
diff stream for a layer. If they do so, the layer store will not use
tar-split processing, but will still verify the digest on layer export.
This makes it easier to experiment with non-default diff formats.

Signed-off-by: Alfred Landrum <alfred.landrum@docker.com>
2017-06-02 00:11:02 +00:00
Brian Goff 114cc6ca3a Implement plugins for logging drivers
Logging plugins use the same HTTP interface as other plugins for basic
command operations meanwhile actual logging operations are handled (on
Unix) via a fifo.

The plugin interface looks like so:

```go
type loggingPlugin interface {
  StartLogging(fifoPath string, loggingContext Context) error
  StopLogging(fifoPath)
```

This means a plugin must implement `LoggingDriver.StartLogging` and
`LoggingDriver.StopLogging` endpoints and be able to consume the passed
in fifo.

Logs are sent via stream encoder to the fifo encoded with protobuf.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2017-06-02 00:11:02 +00:00
Misty Stanley-Jones 0e86bfb1e0 Escape some double brackets
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2017-06-02 00:11:01 +00:00
Sebastiaan van Stijn 82f097e8d5 Merge pull request #32265 from breuner/patch-1
Updated legacy_plugins.md to include BeeGFS plugin
(cherry picked from commit d0057bd12dae5276b83e931e9e9ea185c58486a2)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2017-06-02 00:11:01 +00:00
JimGalasyn 64704a2a80 Delete extraneous H1 title
Signed-off-by: JimGalasyn <jim.galasyn@docker.com>
2017-06-02 00:11:00 +00:00
Anusha Ragunathan c9f1050226 Add pid host support
Tested using global-net-plugin-ipc which sets PidHost in config.json.

Plugins might need access to host pid namespace. Add support for that.
Tested using aragunathan/global-net-plugin-ipc which sets "pidhost" in
config.json. Observed using `readlink /proc/self/ns/pid` that plugin and
host have the same ns.

Signed-off-by: Anusha Ragunathan <anusha.ragunathan@docker.com>
2017-06-02 00:10:59 +00:00
Anusha Ragunathan 9111051d98 Add support in plugin config for accessing host ipc namespace.
Plugins might need access to host ipc namespace. A good usecase is
a volume plugin running iscsi multipath commands that need access to
host kernel locks.
Tested with a custom plugin (aragunathan/global-net-plugin-full) that's
built with `"ipchost" : true` in config.json. Observed using
`readlink /proc/self/ns/ipc` that plugin and host have the same ns.

Signed-off-by: Anusha Ragunathan <anusha.ragunathan@docker.com>
2017-06-02 00:10:59 +00:00
Jimmy Song 3e4d1cacf4 modify docker plugin sshfs entrypoint
Signed-off-by: Jimmy Song <rootsongjc@gmail.com>
2017-06-02 00:10:58 +00:00
Keith Hudgins 01468292d6 added listing for Nimble Storage's volume plugin
Signed-off-by: Keith Hudgins <greenman@greenman.org>

updated nimble plugin url
2017-06-02 00:10:57 +00:00
scjane 2c9f862eaf Update index.md
Signed-off-by: Wang Jie <wangjie5@chinaskycloud.com>
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2017-06-02 00:10:56 +00:00
Anusha Ragunathan 93344b57f3 Service creation using network plugin filters.
Signed-off-by: Anusha Ragunathan <anusha.ragunathan@docker.com>
2017-06-02 00:10:56 +00:00
Misty Stanley-Jones f36bcf1acd Fix some Liquid errors
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2017-06-02 00:10:55 +00:00
Misty Stanley-Jones 38ac6860eb Update plugin_volume apidocs for v2
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
2017-06-02 00:10:55 +00:00
Anusha Ragunathan ab7522c939 Add plugin socket related debug docs.
Signed-off-by: Anusha Ragunathan <anusha.ragunathan@docker.com>
2017-06-02 00:10:55 +00:00
Anusha Ragunathan c76dcd33f7 Add plugin debug docs.
Doc fix for #30761

Signed-off-by: Anusha Ragunathan <anusha.ragunathan@docker.com>
2017-06-02 00:10:53 +00:00
Brian Goff df4e570ff4 Make propagated mount persist outside rootfs
This persists the "propagated mount" for plugins outside the main
rootfs. This enables `docker plugin upgrade` to not remove potentially
important data during upgrade rather than forcing plugin authors to hard
code a host path to persist data to.

Also migrates old plugins that have a propagated mount which is in the
rootfs on daemon startup.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
2017-06-02 00:10:52 +00:00
Yong Tang ecfe6ab218 Add `capability` filter to `docker plugin ls`
This fix adds `--filter capability=[volumedriver|authz]` to `docker plugin ls`.

The related docs has been updated.

An integration test has been added.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
2017-06-02 00:10:51 +00:00
David Williamson b8df00a4b4 Provide password to volume create command
* Depending on the host configuration between the docker engine and the remote host we wish to mount using sshfs, a password may be required.
* Confirmed syntax for optional parameter with @vieux
* Verified change works as desired with engine running on Ubuntu host and mounting a volume from a file system on a Mac.

Signed-off-by: David Williamson <david.williamson@docker.com>
2017-06-02 00:10:51 +00:00
Anusha Ragunathan 79479e040f Add docs for service create based on plugins.
Signed-off-by: Anusha Ragunathan <anusha.ragunathan@docker.com>
2017-06-02 00:10:51 +00:00
Janonymous 7953201f9d Fix json format of plugin
Signed-off-by: Janonymous <janonymous.codevulture@gmail.com>
2017-06-02 00:10:51 +00:00
Tibor Vass f75cb34afa plugins: add example docs for a rexray plugin
Signed-off-by: Tibor Vass <tibor@docker.com>
2017-06-02 00:10:49 +00:00
Zhang Wei b5758e62de Fix some typos
Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
2017-06-02 00:10:49 +00:00
Tibor Vass 8c3f18ca6d plugins: rename DeviceCreation to AllowAllDevices
Signed-off-by: Tibor Vass <tibor@docker.com>
2017-06-02 00:10:48 +00:00
Victor Vieux 63aa05d3f7 replace no-remove by sample-volume-plugin in docs
Signed-off-by: Victor Vieux <vieux@docker.com>
2017-06-02 00:10:47 +00:00
Ovidio Mallo b839363db9 Reference new DigitalOcean plugin (Closes #29729)
Signed-off-by: Ovidio Mallo <ovidio.mallo@gmail.com>
2017-06-02 00:10:47 +00:00