github.com/Heebron/moby@v0.0.0-20221111184709-6eab4f55faf7/docs/api/v1.39.yaml (about) 1 # A Swagger 2.0 (a.k.a. OpenAPI) definition of the Engine API. 2 # 3 # This is used for generating API documentation and the types used by the 4 # client/server. See api/README.md for more information. 5 # 6 # Some style notes: 7 # - This file is used by ReDoc, which allows GitHub Flavored Markdown in 8 # descriptions. 9 # - There is no maximum line length, for ease of editing and pretty diffs. 10 # - operationIds are in the format "NounVerb", with a singular noun. 11 12 swagger: "2.0" 13 schemes: 14 - "http" 15 - "https" 16 produces: 17 - "application/json" 18 - "text/plain" 19 consumes: 20 - "application/json" 21 - "text/plain" 22 basePath: "/v1.39" 23 info: 24 title: "Docker Engine API" 25 version: "1.39" 26 x-logo: 27 url: "https://docs.docker.com/assets/images/logo-docker-main.png" 28 description: | 29 The Engine API is an HTTP API served by Docker Engine. It is the API the 30 Docker client uses to communicate with the Engine, so everything the Docker 31 client can do can be done with the API. 32 33 Most of the client's commands map directly to API endpoints (e.g. `docker ps` 34 is `GET /containers/json`). The notable exception is running containers, 35 which consists of several API calls. 36 37 # Errors 38 39 The API uses standard HTTP status codes to indicate the success or failure 40 of the API call. The body of the response will be JSON in the following 41 format: 42 43 ``` 44 { 45 "message": "page not found" 46 } 47 ``` 48 49 # Versioning 50 51 The API is usually changed in each release, so API calls are versioned to 52 ensure that clients don't break. To lock to a specific version of the API, 53 you prefix the URL with its version, for example, call `/v1.30/info` to use 54 the v1.30 version of the `/info` endpoint. If the API version specified in 55 the URL is not supported by the daemon, a HTTP `400 Bad Request` error message 56 is returned. 57 58 If you omit the version-prefix, the current version of the API (v1.39) is used. 59 For example, calling `/info` is the same as calling `/v1.39/info`. Using the 60 API without a version-prefix is deprecated and will be removed in a future release. 61 62 Engine releases in the near future should support this version of the API, 63 so your client will continue to work even if it is talking to a newer Engine. 64 65 The API uses an open schema model, which means server may add extra properties 66 to responses. Likewise, the server will ignore any extra query parameters and 67 request body properties. When you write clients, you need to ignore additional 68 properties in responses to ensure they do not break when talking to newer 69 daemons. 70 71 72 # Authentication 73 74 Authentication for registries is handled client side. The client has to send 75 authentication details to various endpoints that need to communicate with 76 registries, such as `POST /images/(name)/push`. These are sent as 77 `X-Registry-Auth` header as a [base64url encoded](https://tools.ietf.org/html/rfc4648#section-5) 78 (JSON) string with the following structure: 79 80 ``` 81 { 82 "username": "string", 83 "password": "string", 84 "email": "string", 85 "serveraddress": "string" 86 } 87 ``` 88 89 The `serveraddress` is a domain/IP without a protocol. Throughout this 90 structure, double quotes are required. 91 92 If you have already got an identity token from the [`/auth` endpoint](#operation/SystemAuth), 93 you can just pass this instead of credentials: 94 95 ``` 96 { 97 "identitytoken": "9cbaf023786cd7..." 98 } 99 ``` 100 101 # The tags on paths define the menu sections in the ReDoc documentation, so 102 # the usage of tags must make sense for that: 103 # - They should be singular, not plural. 104 # - There should not be too many tags, or the menu becomes unwieldy. For 105 # example, it is preferable to add a path to the "System" tag instead of 106 # creating a tag with a single path in it. 107 # - The order of tags in this list defines the order in the menu. 108 tags: 109 # Primary objects 110 - name: "Container" 111 x-displayName: "Containers" 112 description: | 113 Create and manage containers. 114 - name: "Image" 115 x-displayName: "Images" 116 - name: "Network" 117 x-displayName: "Networks" 118 description: | 119 Networks are user-defined networks that containers can be attached to. 120 See the [networking documentation](https://docs.docker.com/network/) 121 for more information. 122 - name: "Volume" 123 x-displayName: "Volumes" 124 description: | 125 Create and manage persistent storage that can be attached to containers. 126 - name: "Exec" 127 x-displayName: "Exec" 128 description: | 129 Run new commands inside running containers. Refer to the 130 [command-line reference](https://docs.docker.com/engine/reference/commandline/exec/) 131 for more information. 132 133 To exec a command in a container, you first need to create an exec instance, 134 then start it. These two API endpoints are wrapped up in a single command-line 135 command, `docker exec`. 136 137 # Swarm things 138 - name: "Swarm" 139 x-displayName: "Swarm" 140 description: | 141 Engines can be clustered together in a swarm. Refer to the 142 [swarm mode documentation](https://docs.docker.com/engine/swarm/) 143 for more information. 144 - name: "Node" 145 x-displayName: "Nodes" 146 description: | 147 Nodes are instances of the Engine participating in a swarm. Swarm mode 148 must be enabled for these endpoints to work. 149 - name: "Service" 150 x-displayName: "Services" 151 description: | 152 Services are the definitions of tasks to run on a swarm. Swarm mode must 153 be enabled for these endpoints to work. 154 - name: "Task" 155 x-displayName: "Tasks" 156 description: | 157 A task is a container running on a swarm. It is the atomic scheduling unit 158 of swarm. Swarm mode must be enabled for these endpoints to work. 159 - name: "Secret" 160 x-displayName: "Secrets" 161 description: | 162 Secrets are sensitive data that can be used by services. Swarm mode must 163 be enabled for these endpoints to work. 164 - name: "Config" 165 x-displayName: "Configs" 166 description: | 167 Configs are application configurations that can be used by services. Swarm 168 mode must be enabled for these endpoints to work. 169 # System things 170 - name: "Plugin" 171 x-displayName: "Plugins" 172 - name: "System" 173 x-displayName: "System" 174 175 definitions: 176 Port: 177 type: "object" 178 description: "An open port on a container" 179 required: [PrivatePort, Type] 180 properties: 181 IP: 182 type: "string" 183 format: "ip-address" 184 description: "Host IP address that the container's port is mapped to" 185 PrivatePort: 186 type: "integer" 187 format: "uint16" 188 x-nullable: false 189 description: "Port on the container" 190 PublicPort: 191 type: "integer" 192 format: "uint16" 193 description: "Port exposed on the host" 194 Type: 195 type: "string" 196 x-nullable: false 197 enum: ["tcp", "udp", "sctp"] 198 example: 199 PrivatePort: 8080 200 PublicPort: 80 201 Type: "tcp" 202 203 MountPoint: 204 type: "object" 205 description: | 206 MountPoint represents a mount point configuration inside the container. 207 This is used for reporting the mountpoints in use by a container. 208 properties: 209 Type: 210 description: | 211 The mount type: 212 213 - `bind` a mount of a file or directory from the host into the container. 214 - `volume` a docker volume with the given `Name`. 215 - `tmpfs` a `tmpfs`. 216 - `npipe` a named pipe from the host into the container. 217 type: "string" 218 enum: 219 - "bind" 220 - "volume" 221 - "tmpfs" 222 - "npipe" 223 example: "volume" 224 Name: 225 description: | 226 Name is the name reference to the underlying data defined by `Source` 227 e.g., the volume name. 228 type: "string" 229 example: "myvolume" 230 Source: 231 description: | 232 Source location of the mount. 233 234 For volumes, this contains the storage location of the volume (within 235 `/var/lib/docker/volumes/`). For bind-mounts, and `npipe`, this contains 236 the source (host) part of the bind-mount. For `tmpfs` mount points, this 237 field is empty. 238 type: "string" 239 example: "/var/lib/docker/volumes/myvolume/_data" 240 Destination: 241 description: | 242 Destination is the path relative to the container root (`/`) where 243 the `Source` is mounted inside the container. 244 type: "string" 245 example: "/usr/share/nginx/html/" 246 Driver: 247 description: | 248 Driver is the volume driver used to create the volume (if it is a volume). 249 type: "string" 250 example: "local" 251 Mode: 252 description: | 253 Mode is a comma separated list of options supplied by the user when 254 creating the bind/volume mount. 255 256 The default is platform-specific (`"z"` on Linux, empty on Windows). 257 type: "string" 258 example: "z" 259 RW: 260 description: | 261 Whether the mount is mounted writable (read-write). 262 type: "boolean" 263 example: true 264 Propagation: 265 description: | 266 Propagation describes how mounts are propagated from the host into the 267 mount point, and vice-versa. Refer to the [Linux kernel documentation](https://www.kernel.org/doc/Documentation/filesystems/sharedsubtree.txt) 268 for details. This field is not used on Windows. 269 type: "string" 270 example: "" 271 272 DeviceMapping: 273 type: "object" 274 description: "A device mapping between the host and container" 275 properties: 276 PathOnHost: 277 type: "string" 278 PathInContainer: 279 type: "string" 280 CgroupPermissions: 281 type: "string" 282 example: 283 PathOnHost: "/dev/deviceName" 284 PathInContainer: "/dev/deviceName" 285 CgroupPermissions: "mrw" 286 287 ThrottleDevice: 288 type: "object" 289 properties: 290 Path: 291 description: "Device path" 292 type: "string" 293 Rate: 294 description: "Rate" 295 type: "integer" 296 format: "int64" 297 minimum: 0 298 299 Mount: 300 type: "object" 301 properties: 302 Target: 303 description: "Container path." 304 type: "string" 305 Source: 306 description: "Mount source (e.g. a volume name, a host path)." 307 type: "string" 308 Type: 309 description: | 310 The mount type. Available types: 311 312 - `bind` Mounts a file or directory from the host into the container. Must exist prior to creating the container. 313 - `volume` Creates a volume with the given name and options (or uses a pre-existing volume with the same name and options). These are **not** removed when the container is removed. 314 - `tmpfs` Create a tmpfs with the given options. The mount source cannot be specified for tmpfs. 315 type: "string" 316 enum: 317 - "bind" 318 - "volume" 319 - "tmpfs" 320 ReadOnly: 321 description: "Whether the mount should be read-only." 322 type: "boolean" 323 Consistency: 324 description: "The consistency requirement for the mount: `default`, `consistent`, `cached`, or `delegated`." 325 type: "string" 326 BindOptions: 327 description: "Optional configuration for the `bind` type." 328 type: "object" 329 properties: 330 Propagation: 331 description: "A propagation mode with the value `[r]private`, `[r]shared`, or `[r]slave`." 332 type: "string" 333 enum: 334 - "private" 335 - "rprivate" 336 - "shared" 337 - "rshared" 338 - "slave" 339 - "rslave" 340 VolumeOptions: 341 description: "Optional configuration for the `volume` type." 342 type: "object" 343 properties: 344 NoCopy: 345 description: "Populate volume with data from the target." 346 type: "boolean" 347 default: false 348 Labels: 349 description: "User-defined key/value metadata." 350 type: "object" 351 additionalProperties: 352 type: "string" 353 DriverConfig: 354 description: "Map of driver specific options" 355 type: "object" 356 properties: 357 Name: 358 description: "Name of the driver to use to create the volume." 359 type: "string" 360 Options: 361 description: "key/value map of driver specific options." 362 type: "object" 363 additionalProperties: 364 type: "string" 365 TmpfsOptions: 366 description: "Optional configuration for the `tmpfs` type." 367 type: "object" 368 properties: 369 SizeBytes: 370 description: "The size for the tmpfs mount in bytes." 371 type: "integer" 372 format: "int64" 373 Mode: 374 description: "The permission mode for the tmpfs mount in an integer." 375 type: "integer" 376 377 RestartPolicy: 378 description: | 379 The behavior to apply when the container exits. The default is not to 380 restart. 381 382 An ever increasing delay (double the previous delay, starting at 100ms) is 383 added before each restart to prevent flooding the server. 384 type: "object" 385 properties: 386 Name: 387 type: "string" 388 description: | 389 - Empty string means not to restart 390 - `always` Always restart 391 - `unless-stopped` Restart always except when the user has manually stopped the container 392 - `on-failure` Restart only when the container exit code is non-zero 393 enum: 394 - "" 395 - "always" 396 - "unless-stopped" 397 - "on-failure" 398 MaximumRetryCount: 399 type: "integer" 400 description: | 401 If `on-failure` is used, the number of times to retry before giving up. 402 403 Resources: 404 description: "A container's resources (cgroups config, ulimits, etc)" 405 type: "object" 406 properties: 407 # Applicable to all platforms 408 CpuShares: 409 description: | 410 An integer value representing this container's relative CPU weight 411 versus other containers. 412 type: "integer" 413 Memory: 414 description: "Memory limit in bytes." 415 type: "integer" 416 format: "int64" 417 default: 0 418 # Applicable to UNIX platforms 419 CgroupParent: 420 description: | 421 Path to `cgroups` under which the container's `cgroup` is created. If 422 the path is not absolute, the path is considered to be relative to the 423 `cgroups` path of the init process. Cgroups are created if they do not 424 already exist. 425 type: "string" 426 BlkioWeight: 427 description: "Block IO weight (relative weight)." 428 type: "integer" 429 minimum: 0 430 maximum: 1000 431 BlkioWeightDevice: 432 description: | 433 Block IO weight (relative device weight) in the form: 434 435 ``` 436 [{"Path": "device_path", "Weight": weight}] 437 ``` 438 type: "array" 439 items: 440 type: "object" 441 properties: 442 Path: 443 type: "string" 444 Weight: 445 type: "integer" 446 minimum: 0 447 BlkioDeviceReadBps: 448 description: | 449 Limit read rate (bytes per second) from a device, in the form: 450 451 ``` 452 [{"Path": "device_path", "Rate": rate}] 453 ``` 454 type: "array" 455 items: 456 $ref: "#/definitions/ThrottleDevice" 457 BlkioDeviceWriteBps: 458 description: | 459 Limit write rate (bytes per second) to a device, in the form: 460 461 ``` 462 [{"Path": "device_path", "Rate": rate}] 463 ``` 464 type: "array" 465 items: 466 $ref: "#/definitions/ThrottleDevice" 467 BlkioDeviceReadIOps: 468 description: | 469 Limit read rate (IO per second) from a device, in the form: 470 471 ``` 472 [{"Path": "device_path", "Rate": rate}] 473 ``` 474 type: "array" 475 items: 476 $ref: "#/definitions/ThrottleDevice" 477 BlkioDeviceWriteIOps: 478 description: | 479 Limit write rate (IO per second) to a device, in the form: 480 481 ``` 482 [{"Path": "device_path", "Rate": rate}] 483 ``` 484 type: "array" 485 items: 486 $ref: "#/definitions/ThrottleDevice" 487 CpuPeriod: 488 description: "The length of a CPU period in microseconds." 489 type: "integer" 490 format: "int64" 491 CpuQuota: 492 description: | 493 Microseconds of CPU time that the container can get in a CPU period. 494 type: "integer" 495 format: "int64" 496 CpuRealtimePeriod: 497 description: | 498 The length of a CPU real-time period in microseconds. Set to 0 to 499 allocate no time allocated to real-time tasks. 500 type: "integer" 501 format: "int64" 502 CpuRealtimeRuntime: 503 description: | 504 The length of a CPU real-time runtime in microseconds. Set to 0 to 505 allocate no time allocated to real-time tasks. 506 type: "integer" 507 format: "int64" 508 CpusetCpus: 509 description: | 510 CPUs in which to allow execution (e.g., `0-3`, `0,1`). 511 type: "string" 512 example: "0-3" 513 CpusetMems: 514 description: | 515 Memory nodes (MEMs) in which to allow execution (0-3, 0,1). Only 516 effective on NUMA systems. 517 type: "string" 518 Devices: 519 description: "A list of devices to add to the container." 520 type: "array" 521 items: 522 $ref: "#/definitions/DeviceMapping" 523 DeviceCgroupRules: 524 description: "a list of cgroup rules to apply to the container" 525 type: "array" 526 items: 527 type: "string" 528 example: "c 13:* rwm" 529 DiskQuota: 530 description: "Disk limit (in bytes)." 531 type: "integer" 532 format: "int64" 533 KernelMemory: 534 description: "Kernel memory limit in bytes." 535 type: "integer" 536 format: "int64" 537 example: 209715200 538 MemoryReservation: 539 description: "Memory soft limit in bytes." 540 type: "integer" 541 format: "int64" 542 MemorySwap: 543 description: | 544 Total memory limit (memory + swap). Set as `-1` to enable unlimited 545 swap. 546 type: "integer" 547 format: "int64" 548 MemorySwappiness: 549 description: | 550 Tune a container's memory swappiness behavior. Accepts an integer 551 between 0 and 100. 552 type: "integer" 553 format: "int64" 554 minimum: 0 555 maximum: 100 556 NanoCpus: 557 description: "CPU quota in units of 10<sup>-9</sup> CPUs." 558 type: "integer" 559 format: "int64" 560 OomKillDisable: 561 description: "Disable OOM Killer for the container." 562 type: "boolean" 563 Init: 564 description: | 565 Run an init inside the container that forwards signals and reaps 566 processes. This field is omitted if empty, and the default (as 567 configured on the daemon) is used. 568 type: "boolean" 569 x-nullable: true 570 PidsLimit: 571 description: | 572 Tune a container's PIDs limit. Set `0` or `-1` for unlimited, or `null` 573 to not change. 574 type: "integer" 575 format: "int64" 576 Ulimits: 577 description: | 578 A list of resource limits to set in the container. For example: 579 580 ``` 581 {"Name": "nofile", "Soft": 1024, "Hard": 2048} 582 ``` 583 type: "array" 584 items: 585 type: "object" 586 properties: 587 Name: 588 description: "Name of ulimit" 589 type: "string" 590 Soft: 591 description: "Soft limit" 592 type: "integer" 593 Hard: 594 description: "Hard limit" 595 type: "integer" 596 # Applicable to Windows 597 CpuCount: 598 description: | 599 The number of usable CPUs (Windows only). 600 601 On Windows Server containers, the processor resource controls are 602 mutually exclusive. The order of precedence is `CPUCount` first, then 603 `CPUShares`, and `CPUPercent` last. 604 type: "integer" 605 format: "int64" 606 CpuPercent: 607 description: | 608 The usable percentage of the available CPUs (Windows only). 609 610 On Windows Server containers, the processor resource controls are 611 mutually exclusive. The order of precedence is `CPUCount` first, then 612 `CPUShares`, and `CPUPercent` last. 613 type: "integer" 614 format: "int64" 615 IOMaximumIOps: 616 description: "Maximum IOps for the container system drive (Windows only)" 617 type: "integer" 618 format: "int64" 619 IOMaximumBandwidth: 620 description: | 621 Maximum IO in bytes per second for the container system drive 622 (Windows only). 623 type: "integer" 624 format: "int64" 625 626 ResourceObject: 627 description: | 628 An object describing the resources which can be advertised by a node and 629 requested by a task. 630 type: "object" 631 properties: 632 NanoCPUs: 633 type: "integer" 634 format: "int64" 635 example: 4000000000 636 MemoryBytes: 637 type: "integer" 638 format: "int64" 639 example: 8272408576 640 GenericResources: 641 $ref: "#/definitions/GenericResources" 642 643 GenericResources: 644 description: | 645 User-defined resources can be either Integer resources (e.g, `SSD=3`) or 646 String resources (e.g, `GPU=UUID1`). 647 type: "array" 648 items: 649 type: "object" 650 properties: 651 NamedResourceSpec: 652 type: "object" 653 properties: 654 Kind: 655 type: "string" 656 Value: 657 type: "string" 658 DiscreteResourceSpec: 659 type: "object" 660 properties: 661 Kind: 662 type: "string" 663 Value: 664 type: "integer" 665 format: "int64" 666 example: 667 - DiscreteResourceSpec: 668 Kind: "SSD" 669 Value: 3 670 - NamedResourceSpec: 671 Kind: "GPU" 672 Value: "UUID1" 673 - NamedResourceSpec: 674 Kind: "GPU" 675 Value: "UUID2" 676 677 HealthConfig: 678 description: "A test to perform to check that the container is healthy." 679 type: "object" 680 properties: 681 Test: 682 description: | 683 The test to perform. Possible values are: 684 685 - `[]` inherit healthcheck from image or parent image 686 - `["NONE"]` disable healthcheck 687 - `["CMD", args...]` exec arguments directly 688 - `["CMD-SHELL", command]` run command with system's default shell 689 type: "array" 690 items: 691 type: "string" 692 Interval: 693 description: | 694 The time to wait between checks in nanoseconds. It should be 0 or at 695 least 1000000 (1 ms). 0 means inherit. 696 type: "integer" 697 Timeout: 698 description: | 699 The time to wait before considering the check to have hung. It should 700 be 0 or at least 1000000 (1 ms). 0 means inherit. 701 type: "integer" 702 Retries: 703 description: | 704 The number of consecutive failures needed to consider a container as 705 unhealthy. 0 means inherit. 706 type: "integer" 707 StartPeriod: 708 description: | 709 Start period for the container to initialize before starting 710 health-retries countdown in nanoseconds. It should be 0 or at least 711 1000000 (1 ms). 0 means inherit. 712 type: "integer" 713 714 Health: 715 description: | 716 Health stores information about the container's healthcheck results. 717 type: "object" 718 properties: 719 Status: 720 description: | 721 Status is one of `none`, `starting`, `healthy` or `unhealthy` 722 723 - "none" Indicates there is no healthcheck 724 - "starting" Starting indicates that the container is not yet ready 725 - "healthy" Healthy indicates that the container is running correctly 726 - "unhealthy" Unhealthy indicates that the container has a problem 727 type: "string" 728 enum: 729 - "none" 730 - "starting" 731 - "healthy" 732 - "unhealthy" 733 example: "healthy" 734 FailingStreak: 735 description: "FailingStreak is the number of consecutive failures" 736 type: "integer" 737 example: 0 738 Log: 739 type: "array" 740 description: | 741 Log contains the last few results (oldest first) 742 items: 743 x-nullable: true 744 $ref: "#/definitions/HealthcheckResult" 745 746 HealthcheckResult: 747 description: | 748 HealthcheckResult stores information about a single run of a healthcheck probe 749 type: "object" 750 properties: 751 Start: 752 description: | 753 Date and time at which this check started in 754 [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds. 755 type: "string" 756 format: "date-time" 757 example: "2020-01-04T10:44:24.496525531Z" 758 End: 759 description: | 760 Date and time at which this check ended in 761 [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds. 762 type: "string" 763 format: "dateTime" 764 example: "2020-01-04T10:45:21.364524523Z" 765 ExitCode: 766 description: | 767 ExitCode meanings: 768 769 - `0` healthy 770 - `1` unhealthy 771 - `2` reserved (considered unhealthy) 772 - other values: error running probe 773 type: "integer" 774 example: 0 775 Output: 776 description: "Output from last check" 777 type: "string" 778 779 HostConfig: 780 description: "Container configuration that depends on the host we are running on" 781 allOf: 782 - $ref: "#/definitions/Resources" 783 - type: "object" 784 properties: 785 # Applicable to all platforms 786 Binds: 787 type: "array" 788 description: | 789 A list of volume bindings for this container. Each volume binding 790 is a string in one of these forms: 791 792 - `host-src:container-dest[:options]` to bind-mount a host path 793 into the container. Both `host-src`, and `container-dest` must 794 be an _absolute_ path. 795 - `volume-name:container-dest[:options]` to bind-mount a volume 796 managed by a volume driver into the container. `container-dest` 797 must be an _absolute_ path. 798 799 `options` is an optional, comma-delimited list of: 800 801 - `nocopy` disables automatic copying of data from the container 802 path to the volume. The `nocopy` flag only applies to named volumes. 803 - `[ro|rw]` mounts a volume read-only or read-write, respectively. 804 If omitted or set to `rw`, volumes are mounted read-write. 805 - `[z|Z]` applies SELinux labels to allow or deny multiple containers 806 to read and write to the same volume. 807 - `z`: a _shared_ content label is applied to the content. This 808 label indicates that multiple containers can share the volume 809 content, for both reading and writing. 810 - `Z`: a _private unshared_ label is applied to the content. 811 This label indicates that only the current container can use 812 a private volume. Labeling systems such as SELinux require 813 proper labels to be placed on volume content that is mounted 814 into a container. Without a label, the security system can 815 prevent a container's processes from using the content. By 816 default, the labels set by the host operating system are not 817 modified. 818 - `[[r]shared|[r]slave|[r]private]` specifies mount 819 [propagation behavior](https://www.kernel.org/doc/Documentation/filesystems/sharedsubtree.txt). 820 This only applies to bind-mounted volumes, not internal volumes 821 or named volumes. Mount propagation requires the source mount 822 point (the location where the source directory is mounted in the 823 host operating system) to have the correct propagation properties. 824 For shared volumes, the source mount point must be set to `shared`. 825 For slave volumes, the mount must be set to either `shared` or 826 `slave`. 827 items: 828 type: "string" 829 ContainerIDFile: 830 type: "string" 831 description: "Path to a file where the container ID is written" 832 LogConfig: 833 type: "object" 834 description: "The logging configuration for this container" 835 properties: 836 Type: 837 type: "string" 838 enum: 839 - "json-file" 840 - "syslog" 841 - "journald" 842 - "gelf" 843 - "fluentd" 844 - "awslogs" 845 - "splunk" 846 - "etwlogs" 847 - "none" 848 Config: 849 type: "object" 850 additionalProperties: 851 type: "string" 852 NetworkMode: 853 type: "string" 854 description: | 855 Network mode to use for this container. Supported standard values 856 are: `bridge`, `host`, `none`, and `container:<name|id>`. Any 857 other value is taken as a custom network's name to which this 858 container should connect to. 859 PortBindings: 860 $ref: "#/definitions/PortMap" 861 RestartPolicy: 862 $ref: "#/definitions/RestartPolicy" 863 AutoRemove: 864 type: "boolean" 865 description: | 866 Automatically remove the container when the container's process 867 exits. This has no effect if `RestartPolicy` is set. 868 VolumeDriver: 869 type: "string" 870 description: "Driver that this container uses to mount volumes." 871 VolumesFrom: 872 type: "array" 873 description: | 874 A list of volumes to inherit from another container, specified in 875 the form `<container name>[:<ro|rw>]`. 876 items: 877 type: "string" 878 Mounts: 879 description: | 880 Specification for mounts to be added to the container. 881 type: "array" 882 items: 883 $ref: "#/definitions/Mount" 884 885 # Applicable to UNIX platforms 886 CapAdd: 887 type: "array" 888 description: | 889 A list of kernel capabilities to add to the container. Conflicts 890 with option 'Capabilities'. 891 items: 892 type: "string" 893 CapDrop: 894 type: "array" 895 description: | 896 A list of kernel capabilities to drop from the container. Conflicts 897 with option 'Capabilities'. 898 items: 899 type: "string" 900 Dns: 901 type: "array" 902 description: "A list of DNS servers for the container to use." 903 items: 904 type: "string" 905 DnsOptions: 906 type: "array" 907 description: "A list of DNS options." 908 items: 909 type: "string" 910 DnsSearch: 911 type: "array" 912 description: "A list of DNS search domains." 913 items: 914 type: "string" 915 ExtraHosts: 916 type: "array" 917 description: | 918 A list of hostnames/IP mappings to add to the container's `/etc/hosts` 919 file. Specified in the form `["hostname:IP"]`. 920 items: 921 type: "string" 922 GroupAdd: 923 type: "array" 924 description: | 925 A list of additional groups that the container process will run as. 926 items: 927 type: "string" 928 IpcMode: 929 type: "string" 930 description: | 931 IPC sharing mode for the container. Possible values are: 932 933 - `"none"`: own private IPC namespace, with /dev/shm not mounted 934 - `"private"`: own private IPC namespace 935 - `"shareable"`: own private IPC namespace, with a possibility to share it with other containers 936 - `"container:<name|id>"`: join another (shareable) container's IPC namespace 937 - `"host"`: use the host system's IPC namespace 938 939 If not specified, daemon default is used, which can either be `"private"` 940 or `"shareable"`, depending on daemon version and configuration. 941 Cgroup: 942 type: "string" 943 description: "Cgroup to use for the container." 944 Links: 945 type: "array" 946 description: | 947 A list of links for the container in the form `container_name:alias`. 948 items: 949 type: "string" 950 OomScoreAdj: 951 type: "integer" 952 description: | 953 An integer value containing the score given to the container in 954 order to tune OOM killer preferences. 955 example: 500 956 PidMode: 957 type: "string" 958 description: | 959 Set the PID (Process) Namespace mode for the container. It can be 960 either: 961 962 - `"container:<name|id>"`: joins another container's PID namespace 963 - `"host"`: use the host's PID namespace inside the container 964 Privileged: 965 type: "boolean" 966 description: "Gives the container full access to the host." 967 PublishAllPorts: 968 type: "boolean" 969 description: | 970 Allocates an ephemeral host port for all of a container's 971 exposed ports. 972 973 Ports are de-allocated when the container stops and allocated when 974 the container starts. The allocated port might be changed when 975 restarting the container. 976 977 The port is selected from the ephemeral port range that depends on 978 the kernel. For example, on Linux the range is defined by 979 `/proc/sys/net/ipv4/ip_local_port_range`. 980 ReadonlyRootfs: 981 type: "boolean" 982 description: "Mount the container's root filesystem as read only." 983 SecurityOpt: 984 type: "array" 985 description: | 986 A list of string values to customize labels for MLS systems, such 987 as SELinux. 988 items: 989 type: "string" 990 StorageOpt: 991 type: "object" 992 description: | 993 Storage driver options for this container, in the form `{"size": "120G"}`. 994 additionalProperties: 995 type: "string" 996 Tmpfs: 997 type: "object" 998 description: | 999 A map of container directories which should be replaced by tmpfs 1000 mounts, and their corresponding mount options. For example: 1001 1002 ``` 1003 { "/run": "rw,noexec,nosuid,size=65536k" } 1004 ``` 1005 additionalProperties: 1006 type: "string" 1007 UTSMode: 1008 type: "string" 1009 description: "UTS namespace to use for the container." 1010 UsernsMode: 1011 type: "string" 1012 description: | 1013 Sets the usernamespace mode for the container when usernamespace 1014 remapping option is enabled. 1015 ShmSize: 1016 type: "integer" 1017 description: | 1018 Size of `/dev/shm` in bytes. If omitted, the system uses 64MB. 1019 minimum: 0 1020 Sysctls: 1021 type: "object" 1022 description: | 1023 A list of kernel parameters (sysctls) to set in the container. 1024 For example: 1025 1026 ``` 1027 {"net.ipv4.ip_forward": "1"} 1028 ``` 1029 additionalProperties: 1030 type: "string" 1031 Runtime: 1032 type: "string" 1033 description: "Runtime to use with this container." 1034 # Applicable to Windows 1035 ConsoleSize: 1036 type: "array" 1037 description: | 1038 Initial console size, as an `[height, width]` array. (Windows only) 1039 minItems: 2 1040 maxItems: 2 1041 items: 1042 type: "integer" 1043 minimum: 0 1044 Isolation: 1045 type: "string" 1046 description: | 1047 Isolation technology of the container. (Windows only) 1048 enum: 1049 - "default" 1050 - "process" 1051 - "hyperv" 1052 MaskedPaths: 1053 type: "array" 1054 description: | 1055 The list of paths to be masked inside the container (this overrides 1056 the default set of paths). 1057 items: 1058 type: "string" 1059 ReadonlyPaths: 1060 type: "array" 1061 description: | 1062 The list of paths to be set as read-only inside the container 1063 (this overrides the default set of paths). 1064 items: 1065 type: "string" 1066 1067 ContainerConfig: 1068 description: | 1069 Configuration for a container that is portable between hosts. 1070 1071 When used as `ContainerConfig` field in an image, `ContainerConfig` is an 1072 optional field containing the configuration of the container that was last 1073 committed when creating the image. 1074 1075 Previous versions of Docker builder used this field to store build cache, 1076 and it is not in active use anymore. 1077 type: "object" 1078 properties: 1079 Hostname: 1080 description: | 1081 The hostname to use for the container, as a valid RFC 1123 hostname. 1082 type: "string" 1083 example: "439f4e91bd1d" 1084 Domainname: 1085 description: | 1086 The domain name to use for the container. 1087 type: "string" 1088 User: 1089 description: "The user that commands are run as inside the container." 1090 type: "string" 1091 AttachStdin: 1092 description: "Whether to attach to `stdin`." 1093 type: "boolean" 1094 default: false 1095 AttachStdout: 1096 description: "Whether to attach to `stdout`." 1097 type: "boolean" 1098 default: true 1099 AttachStderr: 1100 description: "Whether to attach to `stderr`." 1101 type: "boolean" 1102 default: true 1103 ExposedPorts: 1104 description: | 1105 An object mapping ports to an empty object in the form: 1106 1107 `{"<port>/<tcp|udp|sctp>": {}}` 1108 type: "object" 1109 x-nullable: true 1110 additionalProperties: 1111 type: "object" 1112 enum: 1113 - {} 1114 default: {} 1115 example: { 1116 "80/tcp": {}, 1117 "443/tcp": {} 1118 } 1119 Tty: 1120 description: | 1121 Attach standard streams to a TTY, including `stdin` if it is not closed. 1122 type: "boolean" 1123 default: false 1124 OpenStdin: 1125 description: "Open `stdin`" 1126 type: "boolean" 1127 default: false 1128 StdinOnce: 1129 description: "Close `stdin` after one attached client disconnects" 1130 type: "boolean" 1131 default: false 1132 Env: 1133 description: | 1134 A list of environment variables to set inside the container in the 1135 form `["VAR=value", ...]`. A variable without `=` is removed from the 1136 environment, rather than to have an empty value. 1137 type: "array" 1138 items: 1139 type: "string" 1140 example: 1141 - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" 1142 Cmd: 1143 description: | 1144 Command to run specified as a string or an array of strings. 1145 type: "array" 1146 items: 1147 type: "string" 1148 example: ["/bin/sh"] 1149 Healthcheck: 1150 $ref: "#/definitions/HealthConfig" 1151 ArgsEscaped: 1152 description: "Command is already escaped (Windows only)" 1153 type: "boolean" 1154 default: false 1155 example: false 1156 x-nullable: true 1157 Image: 1158 description: | 1159 The name (or reference) of the image to use when creating the container, 1160 or which was used when the container was created. 1161 type: "string" 1162 example: "example-image:1.0" 1163 Volumes: 1164 description: | 1165 An object mapping mount point paths inside the container to empty 1166 objects. 1167 type: "object" 1168 additionalProperties: 1169 type: "object" 1170 enum: 1171 - {} 1172 default: {} 1173 WorkingDir: 1174 description: "The working directory for commands to run in." 1175 type: "string" 1176 example: "/public/" 1177 Entrypoint: 1178 description: | 1179 The entry point for the container as a string or an array of strings. 1180 1181 If the array consists of exactly one empty string (`[""]`) then the 1182 entry point is reset to system default (i.e., the entry point used by 1183 docker when there is no `ENTRYPOINT` instruction in the `Dockerfile`). 1184 type: "array" 1185 items: 1186 type: "string" 1187 example: [] 1188 NetworkDisabled: 1189 description: "Disable networking for the container." 1190 type: "boolean" 1191 x-nullable: true 1192 MacAddress: 1193 description: "MAC address of the container." 1194 type: "string" 1195 x-nullable: true 1196 OnBuild: 1197 description: | 1198 `ONBUILD` metadata that were defined in the image's `Dockerfile`. 1199 type: "array" 1200 x-nullable: true 1201 items: 1202 type: "string" 1203 example: [] 1204 Labels: 1205 description: "User-defined key/value metadata." 1206 type: "object" 1207 additionalProperties: 1208 type: "string" 1209 example: 1210 com.example.some-label: "some-value" 1211 com.example.some-other-label: "some-other-value" 1212 StopSignal: 1213 description: | 1214 Signal to stop a container as a string or unsigned integer. 1215 type: "string" 1216 example: "SIGTERM" 1217 x-nullable: true 1218 StopTimeout: 1219 description: "Timeout to stop a container in seconds." 1220 type: "integer" 1221 default: 10 1222 x-nullable: true 1223 Shell: 1224 description: | 1225 Shell for when `RUN`, `CMD`, and `ENTRYPOINT` uses a shell. 1226 type: "array" 1227 x-nullable: true 1228 items: 1229 type: "string" 1230 example: ["/bin/sh", "-c"] 1231 1232 NetworkingConfig: 1233 description: | 1234 NetworkingConfig represents the container's networking configuration for 1235 each of its interfaces. 1236 It is used for the networking configs specified in the `docker create` 1237 and `docker network connect` commands. 1238 type: "object" 1239 properties: 1240 EndpointsConfig: 1241 description: | 1242 A mapping of network name to endpoint configuration for that network. 1243 type: "object" 1244 additionalProperties: 1245 $ref: "#/definitions/EndpointSettings" 1246 example: 1247 # putting an example here, instead of using the example values from 1248 # /definitions/EndpointSettings, because containers/create currently 1249 # does not support attaching to multiple networks, so the example request 1250 # would be confusing if it showed that multiple networks can be contained 1251 # in the EndpointsConfig. 1252 # TODO remove once we support multiple networks on container create (see https://github.com/moby/moby/blob/07e6b843594e061f82baa5fa23c2ff7d536c2a05/daemon/create.go#L323) 1253 EndpointsConfig: 1254 isolated_nw: 1255 IPAMConfig: 1256 IPv4Address: "172.20.30.33" 1257 IPv6Address: "2001:db8:abcd::3033" 1258 LinkLocalIPs: 1259 - "169.254.34.68" 1260 - "fe80::3468" 1261 Links: 1262 - "container_1" 1263 - "container_2" 1264 Aliases: 1265 - "server_x" 1266 - "server_y" 1267 1268 NetworkSettings: 1269 description: "NetworkSettings exposes the network settings in the API" 1270 type: "object" 1271 properties: 1272 Bridge: 1273 description: Name of the network's bridge (for example, `docker0`). 1274 type: "string" 1275 example: "docker0" 1276 SandboxID: 1277 description: SandboxID uniquely represents a container's network stack. 1278 type: "string" 1279 example: "9d12daf2c33f5959c8bf90aa513e4f65b561738661003029ec84830cd503a0c3" 1280 HairpinMode: 1281 description: | 1282 Indicates if hairpin NAT should be enabled on the virtual interface. 1283 type: "boolean" 1284 example: false 1285 LinkLocalIPv6Address: 1286 description: IPv6 unicast address using the link-local prefix. 1287 type: "string" 1288 example: "fe80::42:acff:fe11:1" 1289 LinkLocalIPv6PrefixLen: 1290 description: Prefix length of the IPv6 unicast address. 1291 type: "integer" 1292 example: "64" 1293 Ports: 1294 $ref: "#/definitions/PortMap" 1295 SandboxKey: 1296 description: SandboxKey identifies the sandbox 1297 type: "string" 1298 example: "/var/run/docker/netns/8ab54b426c38" 1299 1300 # TODO is SecondaryIPAddresses actually used? 1301 SecondaryIPAddresses: 1302 description: "" 1303 type: "array" 1304 items: 1305 $ref: "#/definitions/Address" 1306 x-nullable: true 1307 1308 # TODO is SecondaryIPv6Addresses actually used? 1309 SecondaryIPv6Addresses: 1310 description: "" 1311 type: "array" 1312 items: 1313 $ref: "#/definitions/Address" 1314 x-nullable: true 1315 1316 # TODO properties below are part of DefaultNetworkSettings, which is 1317 # marked as deprecated since Docker 1.9 and to be removed in Docker v17.12 1318 EndpointID: 1319 description: | 1320 EndpointID uniquely represents a service endpoint in a Sandbox. 1321 1322 <p><br /></p> 1323 1324 > **Deprecated**: This field is only propagated when attached to the 1325 > default "bridge" network. Use the information from the "bridge" 1326 > network inside the `Networks` map instead, which contains the same 1327 > information. This field was deprecated in Docker 1.9 and is scheduled 1328 > to be removed in Docker 17.12.0 1329 type: "string" 1330 example: "b88f5b905aabf2893f3cbc4ee42d1ea7980bbc0a92e2c8922b1e1795298afb0b" 1331 Gateway: 1332 description: | 1333 Gateway address for the default "bridge" network. 1334 1335 <p><br /></p> 1336 1337 > **Deprecated**: This field is only propagated when attached to the 1338 > default "bridge" network. Use the information from the "bridge" 1339 > network inside the `Networks` map instead, which contains the same 1340 > information. This field was deprecated in Docker 1.9 and is scheduled 1341 > to be removed in Docker 17.12.0 1342 type: "string" 1343 example: "172.17.0.1" 1344 GlobalIPv6Address: 1345 description: | 1346 Global IPv6 address for the default "bridge" network. 1347 1348 <p><br /></p> 1349 1350 > **Deprecated**: This field is only propagated when attached to the 1351 > default "bridge" network. Use the information from the "bridge" 1352 > network inside the `Networks` map instead, which contains the same 1353 > information. This field was deprecated in Docker 1.9 and is scheduled 1354 > to be removed in Docker 17.12.0 1355 type: "string" 1356 example: "2001:db8::5689" 1357 GlobalIPv6PrefixLen: 1358 description: | 1359 Mask length of the global IPv6 address. 1360 1361 <p><br /></p> 1362 1363 > **Deprecated**: This field is only propagated when attached to the 1364 > default "bridge" network. Use the information from the "bridge" 1365 > network inside the `Networks` map instead, which contains the same 1366 > information. This field was deprecated in Docker 1.9 and is scheduled 1367 > to be removed in Docker 17.12.0 1368 type: "integer" 1369 example: 64 1370 IPAddress: 1371 description: | 1372 IPv4 address for the default "bridge" network. 1373 1374 <p><br /></p> 1375 1376 > **Deprecated**: This field is only propagated when attached to the 1377 > default "bridge" network. Use the information from the "bridge" 1378 > network inside the `Networks` map instead, which contains the same 1379 > information. This field was deprecated in Docker 1.9 and is scheduled 1380 > to be removed in Docker 17.12.0 1381 type: "string" 1382 example: "172.17.0.4" 1383 IPPrefixLen: 1384 description: | 1385 Mask length of the IPv4 address. 1386 1387 <p><br /></p> 1388 1389 > **Deprecated**: This field is only propagated when attached to the 1390 > default "bridge" network. Use the information from the "bridge" 1391 > network inside the `Networks` map instead, which contains the same 1392 > information. This field was deprecated in Docker 1.9 and is scheduled 1393 > to be removed in Docker 17.12.0 1394 type: "integer" 1395 example: 16 1396 IPv6Gateway: 1397 description: | 1398 IPv6 gateway address for this network. 1399 1400 <p><br /></p> 1401 1402 > **Deprecated**: This field is only propagated when attached to the 1403 > default "bridge" network. Use the information from the "bridge" 1404 > network inside the `Networks` map instead, which contains the same 1405 > information. This field was deprecated in Docker 1.9 and is scheduled 1406 > to be removed in Docker 17.12.0 1407 type: "string" 1408 example: "2001:db8:2::100" 1409 MacAddress: 1410 description: | 1411 MAC address for the container on the default "bridge" network. 1412 1413 <p><br /></p> 1414 1415 > **Deprecated**: This field is only propagated when attached to the 1416 > default "bridge" network. Use the information from the "bridge" 1417 > network inside the `Networks` map instead, which contains the same 1418 > information. This field was deprecated in Docker 1.9 and is scheduled 1419 > to be removed in Docker 17.12.0 1420 type: "string" 1421 example: "02:42:ac:11:00:04" 1422 Networks: 1423 description: | 1424 Information about all networks that the container is connected to. 1425 type: "object" 1426 additionalProperties: 1427 $ref: "#/definitions/EndpointSettings" 1428 1429 Address: 1430 description: Address represents an IPv4 or IPv6 IP address. 1431 type: "object" 1432 properties: 1433 Addr: 1434 description: IP address. 1435 type: "string" 1436 PrefixLen: 1437 description: Mask length of the IP address. 1438 type: "integer" 1439 1440 PortMap: 1441 description: | 1442 PortMap describes the mapping of container ports to host ports, using the 1443 container's port-number and protocol as key in the format `<port>/<protocol>`, 1444 for example, `80/udp`. 1445 1446 If a container's port is mapped for multiple protocols, separate entries 1447 are added to the mapping table. 1448 type: "object" 1449 additionalProperties: 1450 type: "array" 1451 x-nullable: true 1452 items: 1453 $ref: "#/definitions/PortBinding" 1454 example: 1455 "443/tcp": 1456 - HostIp: "127.0.0.1" 1457 HostPort: "4443" 1458 "80/tcp": 1459 - HostIp: "0.0.0.0" 1460 HostPort: "80" 1461 - HostIp: "0.0.0.0" 1462 HostPort: "8080" 1463 "80/udp": 1464 - HostIp: "0.0.0.0" 1465 HostPort: "80" 1466 "53/udp": 1467 - HostIp: "0.0.0.0" 1468 HostPort: "53" 1469 "2377/tcp": null 1470 1471 PortBinding: 1472 description: | 1473 PortBinding represents a binding between a host IP address and a host 1474 port. 1475 type: "object" 1476 properties: 1477 HostIp: 1478 description: "Host IP address that the container's port is mapped to." 1479 type: "string" 1480 example: "127.0.0.1" 1481 HostPort: 1482 description: "Host port number that the container's port is mapped to." 1483 type: "string" 1484 example: "4443" 1485 1486 GraphDriverData: 1487 description: | 1488 Information about the storage driver used to store the container's and 1489 image's filesystem. 1490 type: "object" 1491 required: [Name, Data] 1492 properties: 1493 Name: 1494 description: "Name of the storage driver." 1495 type: "string" 1496 x-nullable: false 1497 example: "overlay2" 1498 Data: 1499 description: | 1500 Low-level storage metadata, provided as key/value pairs. 1501 1502 This information is driver-specific, and depends on the storage-driver 1503 in use, and should be used for informational purposes only. 1504 type: "object" 1505 x-nullable: false 1506 additionalProperties: 1507 type: "string" 1508 example: { 1509 "MergedDir": "/var/lib/docker/overlay2/ef749362d13333e65fc95c572eb525abbe0052e16e086cb64bc3b98ae9aa6d74/merged", 1510 "UpperDir": "/var/lib/docker/overlay2/ef749362d13333e65fc95c572eb525abbe0052e16e086cb64bc3b98ae9aa6d74/diff", 1511 "WorkDir": "/var/lib/docker/overlay2/ef749362d13333e65fc95c572eb525abbe0052e16e086cb64bc3b98ae9aa6d74/work" 1512 } 1513 1514 ImageInspect: 1515 description: | 1516 Information about an image in the local image cache. 1517 type: "object" 1518 properties: 1519 Id: 1520 description: | 1521 ID is the content-addressable ID of an image. 1522 1523 This identifier is a content-addressable digest calculated from the 1524 image's configuration (which includes the digests of layers used by 1525 the image). 1526 1527 Note that this digest differs from the `RepoDigests` below, which 1528 holds digests of image manifests that reference the image. 1529 type: "string" 1530 x-nullable: false 1531 example: "sha256:ec3f0931a6e6b6855d76b2d7b0be30e81860baccd891b2e243280bf1cd8ad710" 1532 RepoTags: 1533 description: | 1534 List of image names/tags in the local image cache that reference this 1535 image. 1536 1537 Multiple image tags can refer to the same imagem and this list may be 1538 empty if no tags reference the image, in which case the image is 1539 "untagged", in which case it can still be referenced by its ID. 1540 type: "array" 1541 items: 1542 type: "string" 1543 example: 1544 - "example:1.0" 1545 - "example:latest" 1546 - "example:stable" 1547 - "internal.registry.example.com:5000/example:1.0" 1548 RepoDigests: 1549 description: | 1550 List of content-addressable digests of locally available image manifests 1551 that the image is referenced from. Multiple manifests can refer to the 1552 same image. 1553 1554 These digests are usually only available if the image was either pulled 1555 from a registry, or if the image was pushed to a registry, which is when 1556 the manifest is generated and its digest calculated. 1557 type: "array" 1558 items: 1559 type: "string" 1560 example: 1561 - "example@sha256:afcc7f1ac1b49db317a7196c902e61c6c3c4607d63599ee1a82d702d249a0ccb" 1562 - "internal.registry.example.com:5000/example@sha256:b69959407d21e8a062e0416bf13405bb2b71ed7a84dde4158ebafacfa06f5578" 1563 Parent: 1564 description: | 1565 ID of the parent image. 1566 1567 Depending on how the image was created, this field may be empty and 1568 is only set for images that were built/created locally. This field 1569 is empty if the image was pulled from an image registry. 1570 type: "string" 1571 x-nullable: false 1572 example: "" 1573 Comment: 1574 description: | 1575 Optional message that was set when committing or importing the image. 1576 type: "string" 1577 x-nullable: false 1578 example: "" 1579 Created: 1580 description: | 1581 Date and time at which the image was created, formatted in 1582 [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds. 1583 type: "string" 1584 x-nullable: false 1585 example: "2022-02-04T21:20:12.497794809Z" 1586 Container: 1587 description: | 1588 The ID of the container that was used to create the image. 1589 1590 Depending on how the image was created, this field may be empty. 1591 type: "string" 1592 x-nullable: false 1593 example: "65974bc86f1770ae4bff79f651ebdbce166ae9aada632ee3fa9af3a264911735" 1594 ContainerConfig: 1595 $ref: "#/definitions/ContainerConfig" 1596 DockerVersion: 1597 description: | 1598 The version of Docker that was used to build the image. 1599 1600 Depending on how the image was created, this field may be empty. 1601 type: "string" 1602 x-nullable: false 1603 example: "20.10.7" 1604 Author: 1605 description: | 1606 Name of the author that was specified when committing the image, or as 1607 specified through MAINTAINER (deprecated) in the Dockerfile. 1608 type: "string" 1609 x-nullable: false 1610 example: "" 1611 Config: 1612 $ref: "#/definitions/ContainerConfig" 1613 Architecture: 1614 description: | 1615 Hardware CPU architecture that the image runs on. 1616 type: "string" 1617 x-nullable: false 1618 example: "arm" 1619 Variant: 1620 description: | 1621 CPU architecture variant (presently ARM-only). 1622 type: "string" 1623 x-nullable: true 1624 example: "v7" 1625 Os: 1626 description: | 1627 Operating System the image is built to run on. 1628 type: "string" 1629 x-nullable: false 1630 example: "linux" 1631 OsVersion: 1632 description: | 1633 Operating System version the image is built to run on (especially 1634 for Windows). 1635 type: "string" 1636 example: "" 1637 x-nullable: true 1638 Size: 1639 description: | 1640 Total size of the image including all layers it is composed of. 1641 type: "integer" 1642 format: "int64" 1643 x-nullable: false 1644 example: 1239828 1645 VirtualSize: 1646 description: | 1647 Total size of the image including all layers it is composed of. 1648 1649 In versions of Docker before v1.10, this field was calculated from 1650 the image itself and all of its parent images. Docker v1.10 and up 1651 store images self-contained, and no longer use a parent-chain, making 1652 this field an equivalent of the Size field. 1653 1654 This field is kept for backward compatibility, but may be removed in 1655 a future version of the API. 1656 type: "integer" 1657 format: "int64" 1658 x-nullable: false 1659 example: 1239828 1660 GraphDriver: 1661 $ref: "#/definitions/GraphDriverData" 1662 RootFS: 1663 description: | 1664 Information about the image's RootFS, including the layer IDs. 1665 type: "object" 1666 required: [Type] 1667 properties: 1668 Type: 1669 type: "string" 1670 x-nullable: false 1671 example: "layers" 1672 Layers: 1673 type: "array" 1674 items: 1675 type: "string" 1676 example: 1677 - "sha256:1834950e52ce4d5a88a1bbd131c537f4d0e56d10ff0dd69e66be3b7dfa9df7e6" 1678 - "sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef" 1679 Metadata: 1680 description: | 1681 Additional metadata of the image in the local cache. This information 1682 is local to the daemon, and not part of the image itself. 1683 type: "object" 1684 properties: 1685 LastTagTime: 1686 description: | 1687 Date and time at which the image was last tagged in 1688 [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds. 1689 1690 This information is only available if the image was tagged locally, 1691 and omitted otherwise. 1692 type: "string" 1693 format: "dateTime" 1694 example: "2022-02-28T14:40:02.623929178Z" 1695 x-nullable: true 1696 ImageSummary: 1697 type: "object" 1698 required: 1699 - Id 1700 - ParentId 1701 - RepoTags 1702 - RepoDigests 1703 - Created 1704 - Size 1705 - SharedSize 1706 - VirtualSize 1707 - Labels 1708 - Containers 1709 properties: 1710 Id: 1711 description: | 1712 ID is the content-addressable ID of an image. 1713 1714 This identifier is a content-addressable digest calculated from the 1715 image's configuration (which includes the digests of layers used by 1716 the image). 1717 1718 Note that this digest differs from the `RepoDigests` below, which 1719 holds digests of image manifests that reference the image. 1720 type: "string" 1721 x-nullable: false 1722 example: "sha256:ec3f0931a6e6b6855d76b2d7b0be30e81860baccd891b2e243280bf1cd8ad710" 1723 ParentId: 1724 description: | 1725 ID of the parent image. 1726 1727 Depending on how the image was created, this field may be empty and 1728 is only set for images that were built/created locally. This field 1729 is empty if the image was pulled from an image registry. 1730 type: "string" 1731 x-nullable: false 1732 example: "" 1733 RepoTags: 1734 description: | 1735 List of image names/tags in the local image cache that reference this 1736 image. 1737 1738 Multiple image tags can refer to the same imagem and this list may be 1739 empty if no tags reference the image, in which case the image is 1740 "untagged", in which case it can still be referenced by its ID. 1741 type: "array" 1742 x-nullable: false 1743 items: 1744 type: "string" 1745 example: 1746 - "example:1.0" 1747 - "example:latest" 1748 - "example:stable" 1749 - "internal.registry.example.com:5000/example:1.0" 1750 RepoDigests: 1751 description: | 1752 List of content-addressable digests of locally available image manifests 1753 that the image is referenced from. Multiple manifests can refer to the 1754 same image. 1755 1756 These digests are usually only available if the image was either pulled 1757 from a registry, or if the image was pushed to a registry, which is when 1758 the manifest is generated and its digest calculated. 1759 type: "array" 1760 x-nullable: false 1761 items: 1762 type: "string" 1763 example: 1764 - "example@sha256:afcc7f1ac1b49db317a7196c902e61c6c3c4607d63599ee1a82d702d249a0ccb" 1765 - "internal.registry.example.com:5000/example@sha256:b69959407d21e8a062e0416bf13405bb2b71ed7a84dde4158ebafacfa06f5578" 1766 Created: 1767 description: | 1768 Date and time at which the image was created as a Unix timestamp 1769 (number of seconds sinds EPOCH). 1770 type: "integer" 1771 x-nullable: false 1772 example: "1644009612" 1773 Size: 1774 description: | 1775 Total size of the image including all layers it is composed of. 1776 type: "integer" 1777 format: "int64" 1778 x-nullable: false 1779 example: 172064416 1780 SharedSize: 1781 description: | 1782 Total size of image layers that are shared between this image and other 1783 images. 1784 1785 This size is not calculated by default. `-1` indicates that the value 1786 has not been set / calculated. 1787 type: "integer" 1788 x-nullable: false 1789 example: 1239828 1790 VirtualSize: 1791 description: | 1792 Total size of the image including all layers it is composed of. 1793 1794 In versions of Docker before v1.10, this field was calculated from 1795 the image itself and all of its parent images. Docker v1.10 and up 1796 store images self-contained, and no longer use a parent-chain, making 1797 this field an equivalent of the Size field. 1798 1799 This field is kept for backward compatibility, but may be removed in 1800 a future version of the API. 1801 type: "integer" 1802 format: "int64" 1803 x-nullable: false 1804 example: 172064416 1805 Labels: 1806 description: "User-defined key/value metadata." 1807 type: "object" 1808 x-nullable: false 1809 additionalProperties: 1810 type: "string" 1811 example: 1812 com.example.some-label: "some-value" 1813 com.example.some-other-label: "some-other-value" 1814 Containers: 1815 description: | 1816 Number of containers using this image. Includes both stopped and running 1817 containers. 1818 1819 This size is not calculated by default, and depends on which API endpoint 1820 is used. `-1` indicates that the value has not been set / calculated. 1821 x-nullable: false 1822 type: "integer" 1823 example: 2 1824 1825 AuthConfig: 1826 type: "object" 1827 properties: 1828 username: 1829 type: "string" 1830 password: 1831 type: "string" 1832 email: 1833 type: "string" 1834 serveraddress: 1835 type: "string" 1836 example: 1837 username: "hannibal" 1838 password: "xxxx" 1839 serveraddress: "https://index.docker.io/v1/" 1840 1841 ProcessConfig: 1842 type: "object" 1843 properties: 1844 privileged: 1845 type: "boolean" 1846 user: 1847 type: "string" 1848 tty: 1849 type: "boolean" 1850 entrypoint: 1851 type: "string" 1852 arguments: 1853 type: "array" 1854 items: 1855 type: "string" 1856 1857 Volume: 1858 type: "object" 1859 required: [Name, Driver, Mountpoint, Labels, Scope, Options] 1860 properties: 1861 Name: 1862 type: "string" 1863 description: "Name of the volume." 1864 x-nullable: false 1865 example: "tardis" 1866 Driver: 1867 type: "string" 1868 description: "Name of the volume driver used by the volume." 1869 x-nullable: false 1870 example: "custom" 1871 Mountpoint: 1872 type: "string" 1873 description: "Mount path of the volume on the host." 1874 x-nullable: false 1875 example: "/var/lib/docker/volumes/tardis" 1876 CreatedAt: 1877 type: "string" 1878 format: "dateTime" 1879 description: "Date/Time the volume was created." 1880 example: "2016-06-07T20:31:11.853781916Z" 1881 Status: 1882 type: "object" 1883 description: | 1884 Low-level details about the volume, provided by the volume driver. 1885 Details are returned as a map with key/value pairs: 1886 `{"key":"value","key2":"value2"}`. 1887 1888 The `Status` field is optional, and is omitted if the volume driver 1889 does not support this feature. 1890 additionalProperties: 1891 type: "object" 1892 example: 1893 hello: "world" 1894 Labels: 1895 type: "object" 1896 description: "User-defined key/value metadata." 1897 x-nullable: false 1898 additionalProperties: 1899 type: "string" 1900 example: 1901 com.example.some-label: "some-value" 1902 com.example.some-other-label: "some-other-value" 1903 Scope: 1904 type: "string" 1905 description: | 1906 The level at which the volume exists. Either `global` for cluster-wide, 1907 or `local` for machine level. 1908 default: "local" 1909 x-nullable: false 1910 enum: ["local", "global"] 1911 example: "local" 1912 Options: 1913 type: "object" 1914 description: | 1915 The driver specific options used when creating the volume. 1916 additionalProperties: 1917 type: "string" 1918 example: 1919 device: "tmpfs" 1920 o: "size=100m,uid=1000" 1921 type: "tmpfs" 1922 UsageData: 1923 type: "object" 1924 x-nullable: true 1925 required: [Size, RefCount] 1926 description: | 1927 Usage details about the volume. This information is used by the 1928 `GET /system/df` endpoint, and omitted in other endpoints. 1929 properties: 1930 Size: 1931 type: "integer" 1932 default: -1 1933 description: | 1934 Amount of disk space used by the volume (in bytes). This information 1935 is only available for volumes created with the `"local"` volume 1936 driver. For volumes created with other volume drivers, this field 1937 is set to `-1` ("not available") 1938 x-nullable: false 1939 RefCount: 1940 type: "integer" 1941 default: -1 1942 description: | 1943 The number of containers referencing this volume. This field 1944 is set to `-1` if the reference-count is not available. 1945 x-nullable: false 1946 1947 VolumeCreateOptions: 1948 description: "Volume configuration" 1949 type: "object" 1950 title: "VolumeConfig" 1951 x-go-name: "VolumeCreateBody" 1952 properties: 1953 Name: 1954 description: | 1955 The new volume's name. If not specified, Docker generates a name. 1956 type: "string" 1957 x-nullable: false 1958 example: "tardis" 1959 Driver: 1960 description: "Name of the volume driver to use." 1961 type: "string" 1962 default: "local" 1963 x-nullable: false 1964 example: "custom" 1965 DriverOpts: 1966 description: | 1967 A mapping of driver options and values. These options are 1968 passed directly to the driver and are driver specific. 1969 type: "object" 1970 additionalProperties: 1971 type: "string" 1972 example: 1973 device: "tmpfs" 1974 o: "size=100m,uid=1000" 1975 type: "tmpfs" 1976 Labels: 1977 description: "User-defined key/value metadata." 1978 type: "object" 1979 additionalProperties: 1980 type: "string" 1981 example: 1982 com.example.some-label: "some-value" 1983 com.example.some-other-label: "some-other-value" 1984 1985 VolumeListResponse: 1986 type: "object" 1987 title: "VolumeListResponse" 1988 x-go-name: "VolumeListOKBody" 1989 description: "Volume list response" 1990 properties: 1991 Volumes: 1992 type: "array" 1993 description: "List of volumes" 1994 items: 1995 $ref: "#/definitions/Volume" 1996 Warnings: 1997 type: "array" 1998 description: | 1999 Warnings that occurred when fetching the list of volumes. 2000 items: 2001 type: "string" 2002 example: [] 2003 2004 Network: 2005 type: "object" 2006 properties: 2007 Name: 2008 type: "string" 2009 Id: 2010 type: "string" 2011 Created: 2012 type: "string" 2013 format: "dateTime" 2014 Scope: 2015 type: "string" 2016 Driver: 2017 type: "string" 2018 EnableIPv6: 2019 type: "boolean" 2020 IPAM: 2021 $ref: "#/definitions/IPAM" 2022 Internal: 2023 type: "boolean" 2024 Attachable: 2025 type: "boolean" 2026 Ingress: 2027 type: "boolean" 2028 Containers: 2029 type: "object" 2030 additionalProperties: 2031 $ref: "#/definitions/NetworkContainer" 2032 Options: 2033 type: "object" 2034 additionalProperties: 2035 type: "string" 2036 Labels: 2037 type: "object" 2038 additionalProperties: 2039 type: "string" 2040 example: 2041 Name: "net01" 2042 Id: "7d86d31b1478e7cca9ebed7e73aa0fdeec46c5ca29497431d3007d2d9e15ed99" 2043 Created: "2016-10-19T04:33:30.360899459Z" 2044 Scope: "local" 2045 Driver: "bridge" 2046 EnableIPv6: false 2047 IPAM: 2048 Driver: "default" 2049 Config: 2050 - Subnet: "172.19.0.0/16" 2051 Gateway: "172.19.0.1" 2052 Options: 2053 foo: "bar" 2054 Internal: false 2055 Attachable: false 2056 Ingress: false 2057 Containers: 2058 19a4d5d687db25203351ed79d478946f861258f018fe384f229f2efa4b23513c: 2059 Name: "test" 2060 EndpointID: "628cadb8bcb92de107b2a1e516cbffe463e321f548feb37697cce00ad694f21a" 2061 MacAddress: "02:42:ac:13:00:02" 2062 IPv4Address: "172.19.0.2/16" 2063 IPv6Address: "" 2064 Options: 2065 com.docker.network.bridge.default_bridge: "true" 2066 com.docker.network.bridge.enable_icc: "true" 2067 com.docker.network.bridge.enable_ip_masquerade: "true" 2068 com.docker.network.bridge.host_binding_ipv4: "0.0.0.0" 2069 com.docker.network.bridge.name: "docker0" 2070 com.docker.network.driver.mtu: "1500" 2071 Labels: 2072 com.example.some-label: "some-value" 2073 com.example.some-other-label: "some-other-value" 2074 IPAM: 2075 type: "object" 2076 properties: 2077 Driver: 2078 description: "Name of the IPAM driver to use." 2079 type: "string" 2080 default: "default" 2081 Config: 2082 description: | 2083 List of IPAM configuration options, specified as a map: 2084 2085 ``` 2086 {"Subnet": <CIDR>, "IPRange": <CIDR>, "Gateway": <IP address>, "AuxAddress": <device_name:IP address>} 2087 ``` 2088 type: "array" 2089 items: 2090 type: "object" 2091 additionalProperties: 2092 type: "string" 2093 Options: 2094 description: "Driver-specific options, specified as a map." 2095 type: "object" 2096 additionalProperties: 2097 type: "string" 2098 2099 NetworkContainer: 2100 type: "object" 2101 properties: 2102 Name: 2103 type: "string" 2104 EndpointID: 2105 type: "string" 2106 MacAddress: 2107 type: "string" 2108 IPv4Address: 2109 type: "string" 2110 IPv6Address: 2111 type: "string" 2112 2113 BuildInfo: 2114 type: "object" 2115 properties: 2116 id: 2117 type: "string" 2118 stream: 2119 type: "string" 2120 error: 2121 type: "string" 2122 errorDetail: 2123 $ref: "#/definitions/ErrorDetail" 2124 status: 2125 type: "string" 2126 progress: 2127 type: "string" 2128 progressDetail: 2129 $ref: "#/definitions/ProgressDetail" 2130 aux: 2131 $ref: "#/definitions/ImageID" 2132 2133 BuildCache: 2134 type: "object" 2135 description: | 2136 BuildCache contains information about a build cache record. 2137 properties: 2138 ID: 2139 type: "string" 2140 description: | 2141 Unique ID of the build cache record. 2142 example: "ndlpt0hhvkqcdfkputsk4cq9c" 2143 Parent: 2144 description: | 2145 ID of the parent build cache record. 2146 type: "string" 2147 example: "hw53o5aio51xtltp5xjp8v7fx" 2148 Type: 2149 type: "string" 2150 description: | 2151 Cache record type. 2152 example: "regular" 2153 # see https://github.com/moby/buildkit/blob/fce4a32258dc9d9664f71a4831d5de10f0670677/client/diskusage.go#L75-L84 2154 enum: 2155 - "internal" 2156 - "frontend" 2157 - "source.local" 2158 - "source.git.checkout" 2159 - "exec.cachemount" 2160 - "regular" 2161 Description: 2162 type: "string" 2163 description: | 2164 Description of the build-step that produced the build cache. 2165 example: "mount / from exec /bin/sh -c echo 'Binary::apt::APT::Keep-Downloaded-Packages \"true\";' > /etc/apt/apt.conf.d/keep-cache" 2166 InUse: 2167 type: "boolean" 2168 description: | 2169 Indicates if the build cache is in use. 2170 example: false 2171 Shared: 2172 type: "boolean" 2173 description: | 2174 Indicates if the build cache is shared. 2175 example: true 2176 Size: 2177 description: | 2178 Amount of disk space used by the build cache (in bytes). 2179 type: "integer" 2180 example: 51 2181 CreatedAt: 2182 description: | 2183 Date and time at which the build cache was created in 2184 [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds. 2185 type: "string" 2186 format: "dateTime" 2187 example: "2016-08-18T10:44:24.496525531Z" 2188 LastUsedAt: 2189 description: | 2190 Date and time at which the build cache was last used in 2191 [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds. 2192 type: "string" 2193 format: "dateTime" 2194 x-nullable: true 2195 example: "2017-08-09T07:09:37.632105588Z" 2196 UsageCount: 2197 type: "integer" 2198 example: 26 2199 2200 ImageID: 2201 type: "object" 2202 description: "Image ID or Digest" 2203 properties: 2204 ID: 2205 type: "string" 2206 example: 2207 ID: "sha256:85f05633ddc1c50679be2b16a0479ab6f7637f8884e0cfe0f4d20e1ebb3d6e7c" 2208 2209 CreateImageInfo: 2210 type: "object" 2211 properties: 2212 id: 2213 type: "string" 2214 error: 2215 type: "string" 2216 status: 2217 type: "string" 2218 progress: 2219 type: "string" 2220 progressDetail: 2221 $ref: "#/definitions/ProgressDetail" 2222 2223 PushImageInfo: 2224 type: "object" 2225 properties: 2226 error: 2227 type: "string" 2228 status: 2229 type: "string" 2230 progress: 2231 type: "string" 2232 progressDetail: 2233 $ref: "#/definitions/ProgressDetail" 2234 2235 ErrorDetail: 2236 type: "object" 2237 properties: 2238 code: 2239 type: "integer" 2240 message: 2241 type: "string" 2242 2243 ProgressDetail: 2244 type: "object" 2245 properties: 2246 current: 2247 type: "integer" 2248 total: 2249 type: "integer" 2250 2251 ErrorResponse: 2252 description: "Represents an error." 2253 type: "object" 2254 required: ["message"] 2255 properties: 2256 message: 2257 description: "The error message." 2258 type: "string" 2259 x-nullable: false 2260 example: 2261 message: "Something went wrong." 2262 2263 IdResponse: 2264 description: "Response to an API call that returns just an Id" 2265 type: "object" 2266 required: ["Id"] 2267 properties: 2268 Id: 2269 description: "The id of the newly created object." 2270 type: "string" 2271 x-nullable: false 2272 2273 EndpointSettings: 2274 description: "Configuration for a network endpoint." 2275 type: "object" 2276 properties: 2277 # Configurations 2278 IPAMConfig: 2279 $ref: "#/definitions/EndpointIPAMConfig" 2280 Links: 2281 type: "array" 2282 items: 2283 type: "string" 2284 example: 2285 - "container_1" 2286 - "container_2" 2287 Aliases: 2288 type: "array" 2289 items: 2290 type: "string" 2291 example: 2292 - "server_x" 2293 - "server_y" 2294 2295 # Operational data 2296 NetworkID: 2297 description: | 2298 Unique ID of the network. 2299 type: "string" 2300 example: "08754567f1f40222263eab4102e1c733ae697e8e354aa9cd6e18d7402835292a" 2301 EndpointID: 2302 description: | 2303 Unique ID for the service endpoint in a Sandbox. 2304 type: "string" 2305 example: "b88f5b905aabf2893f3cbc4ee42d1ea7980bbc0a92e2c8922b1e1795298afb0b" 2306 Gateway: 2307 description: | 2308 Gateway address for this network. 2309 type: "string" 2310 example: "172.17.0.1" 2311 IPAddress: 2312 description: | 2313 IPv4 address. 2314 type: "string" 2315 example: "172.17.0.4" 2316 IPPrefixLen: 2317 description: | 2318 Mask length of the IPv4 address. 2319 type: "integer" 2320 example: 16 2321 IPv6Gateway: 2322 description: | 2323 IPv6 gateway address. 2324 type: "string" 2325 example: "2001:db8:2::100" 2326 GlobalIPv6Address: 2327 description: | 2328 Global IPv6 address. 2329 type: "string" 2330 example: "2001:db8::5689" 2331 GlobalIPv6PrefixLen: 2332 description: | 2333 Mask length of the global IPv6 address. 2334 type: "integer" 2335 format: "int64" 2336 example: 64 2337 MacAddress: 2338 description: | 2339 MAC address for the endpoint on this network. 2340 type: "string" 2341 example: "02:42:ac:11:00:04" 2342 DriverOpts: 2343 description: | 2344 DriverOpts is a mapping of driver options and values. These options 2345 are passed directly to the driver and are driver specific. 2346 type: "object" 2347 x-nullable: true 2348 additionalProperties: 2349 type: "string" 2350 example: 2351 com.example.some-label: "some-value" 2352 com.example.some-other-label: "some-other-value" 2353 2354 EndpointIPAMConfig: 2355 description: | 2356 EndpointIPAMConfig represents an endpoint's IPAM configuration. 2357 type: "object" 2358 x-nullable: true 2359 properties: 2360 IPv4Address: 2361 type: "string" 2362 example: "172.20.30.33" 2363 IPv6Address: 2364 type: "string" 2365 example: "2001:db8:abcd::3033" 2366 LinkLocalIPs: 2367 type: "array" 2368 items: 2369 type: "string" 2370 example: 2371 - "169.254.34.68" 2372 - "fe80::3468" 2373 2374 PluginMount: 2375 type: "object" 2376 x-nullable: false 2377 required: [Name, Description, Settable, Source, Destination, Type, Options] 2378 properties: 2379 Name: 2380 type: "string" 2381 x-nullable: false 2382 example: "some-mount" 2383 Description: 2384 type: "string" 2385 x-nullable: false 2386 example: "This is a mount that's used by the plugin." 2387 Settable: 2388 type: "array" 2389 items: 2390 type: "string" 2391 Source: 2392 type: "string" 2393 example: "/var/lib/docker/plugins/" 2394 Destination: 2395 type: "string" 2396 x-nullable: false 2397 example: "/mnt/state" 2398 Type: 2399 type: "string" 2400 x-nullable: false 2401 example: "bind" 2402 Options: 2403 type: "array" 2404 items: 2405 type: "string" 2406 example: 2407 - "rbind" 2408 - "rw" 2409 2410 PluginDevice: 2411 type: "object" 2412 required: [Name, Description, Settable, Path] 2413 x-nullable: false 2414 properties: 2415 Name: 2416 type: "string" 2417 x-nullable: false 2418 Description: 2419 type: "string" 2420 x-nullable: false 2421 Settable: 2422 type: "array" 2423 items: 2424 type: "string" 2425 Path: 2426 type: "string" 2427 example: "/dev/fuse" 2428 2429 PluginEnv: 2430 type: "object" 2431 x-nullable: false 2432 required: [Name, Description, Settable, Value] 2433 properties: 2434 Name: 2435 x-nullable: false 2436 type: "string" 2437 Description: 2438 x-nullable: false 2439 type: "string" 2440 Settable: 2441 type: "array" 2442 items: 2443 type: "string" 2444 Value: 2445 type: "string" 2446 2447 PluginInterfaceType: 2448 type: "object" 2449 x-nullable: false 2450 required: [Prefix, Capability, Version] 2451 properties: 2452 Prefix: 2453 type: "string" 2454 x-nullable: false 2455 Capability: 2456 type: "string" 2457 x-nullable: false 2458 Version: 2459 type: "string" 2460 x-nullable: false 2461 2462 Plugin: 2463 description: "A plugin for the Engine API" 2464 type: "object" 2465 required: [Settings, Enabled, Config, Name] 2466 properties: 2467 Id: 2468 type: "string" 2469 example: "5724e2c8652da337ab2eedd19fc6fc0ec908e4bd907c7421bf6a8dfc70c4c078" 2470 Name: 2471 type: "string" 2472 x-nullable: false 2473 example: "tiborvass/sample-volume-plugin" 2474 Enabled: 2475 description: 2476 True if the plugin is running. False if the plugin is not running, 2477 only installed. 2478 type: "boolean" 2479 x-nullable: false 2480 example: true 2481 Settings: 2482 description: "Settings that can be modified by users." 2483 type: "object" 2484 x-nullable: false 2485 required: [Args, Devices, Env, Mounts] 2486 properties: 2487 Mounts: 2488 type: "array" 2489 items: 2490 $ref: "#/definitions/PluginMount" 2491 Env: 2492 type: "array" 2493 items: 2494 type: "string" 2495 example: 2496 - "DEBUG=0" 2497 Args: 2498 type: "array" 2499 items: 2500 type: "string" 2501 Devices: 2502 type: "array" 2503 items: 2504 $ref: "#/definitions/PluginDevice" 2505 PluginReference: 2506 description: "plugin remote reference used to push/pull the plugin" 2507 type: "string" 2508 x-nullable: false 2509 example: "localhost:5000/tiborvass/sample-volume-plugin:latest" 2510 Config: 2511 description: "The config of a plugin." 2512 type: "object" 2513 x-nullable: false 2514 required: 2515 - Description 2516 - Documentation 2517 - Interface 2518 - Entrypoint 2519 - WorkDir 2520 - Network 2521 - Linux 2522 - PidHost 2523 - PropagatedMount 2524 - IpcHost 2525 - Mounts 2526 - Env 2527 - Args 2528 properties: 2529 DockerVersion: 2530 description: "Docker Version used to create the plugin" 2531 type: "string" 2532 x-nullable: false 2533 example: "17.06.0-ce" 2534 Description: 2535 type: "string" 2536 x-nullable: false 2537 example: "A sample volume plugin for Docker" 2538 Documentation: 2539 type: "string" 2540 x-nullable: false 2541 example: "https://docs.docker.com/engine/extend/plugins/" 2542 Interface: 2543 description: "The interface between Docker and the plugin" 2544 x-nullable: false 2545 type: "object" 2546 required: [Types, Socket] 2547 properties: 2548 Types: 2549 type: "array" 2550 items: 2551 $ref: "#/definitions/PluginInterfaceType" 2552 example: 2553 - "docker.volumedriver/1.0" 2554 Socket: 2555 type: "string" 2556 x-nullable: false 2557 example: "plugins.sock" 2558 ProtocolScheme: 2559 type: "string" 2560 example: "some.protocol/v1.0" 2561 description: "Protocol to use for clients connecting to the plugin." 2562 enum: 2563 - "" 2564 - "moby.plugins.http/v1" 2565 Entrypoint: 2566 type: "array" 2567 items: 2568 type: "string" 2569 example: 2570 - "/usr/bin/sample-volume-plugin" 2571 - "/data" 2572 WorkDir: 2573 type: "string" 2574 x-nullable: false 2575 example: "/bin/" 2576 User: 2577 type: "object" 2578 x-nullable: false 2579 properties: 2580 UID: 2581 type: "integer" 2582 format: "uint32" 2583 example: 1000 2584 GID: 2585 type: "integer" 2586 format: "uint32" 2587 example: 1000 2588 Network: 2589 type: "object" 2590 x-nullable: false 2591 required: [Type] 2592 properties: 2593 Type: 2594 x-nullable: false 2595 type: "string" 2596 example: "host" 2597 Linux: 2598 type: "object" 2599 x-nullable: false 2600 required: [Capabilities, AllowAllDevices, Devices] 2601 properties: 2602 Capabilities: 2603 type: "array" 2604 items: 2605 type: "string" 2606 example: 2607 - "CAP_SYS_ADMIN" 2608 - "CAP_SYSLOG" 2609 AllowAllDevices: 2610 type: "boolean" 2611 x-nullable: false 2612 example: false 2613 Devices: 2614 type: "array" 2615 items: 2616 $ref: "#/definitions/PluginDevice" 2617 PropagatedMount: 2618 type: "string" 2619 x-nullable: false 2620 example: "/mnt/volumes" 2621 IpcHost: 2622 type: "boolean" 2623 x-nullable: false 2624 example: false 2625 PidHost: 2626 type: "boolean" 2627 x-nullable: false 2628 example: false 2629 Mounts: 2630 type: "array" 2631 items: 2632 $ref: "#/definitions/PluginMount" 2633 Env: 2634 type: "array" 2635 items: 2636 $ref: "#/definitions/PluginEnv" 2637 example: 2638 - Name: "DEBUG" 2639 Description: "If set, prints debug messages" 2640 Settable: null 2641 Value: "0" 2642 Args: 2643 type: "object" 2644 x-nullable: false 2645 required: [Name, Description, Settable, Value] 2646 properties: 2647 Name: 2648 x-nullable: false 2649 type: "string" 2650 example: "args" 2651 Description: 2652 x-nullable: false 2653 type: "string" 2654 example: "command line arguments" 2655 Settable: 2656 type: "array" 2657 items: 2658 type: "string" 2659 Value: 2660 type: "array" 2661 items: 2662 type: "string" 2663 rootfs: 2664 type: "object" 2665 properties: 2666 type: 2667 type: "string" 2668 example: "layers" 2669 diff_ids: 2670 type: "array" 2671 items: 2672 type: "string" 2673 example: 2674 - "sha256:675532206fbf3030b8458f88d6e26d4eb1577688a25efec97154c94e8b6b4887" 2675 - "sha256:e216a057b1cb1efc11f8a268f37ef62083e70b1b38323ba252e25ac88904a7e8" 2676 2677 ObjectVersion: 2678 description: | 2679 The version number of the object such as node, service, etc. This is needed 2680 to avoid conflicting writes. The client must send the version number along 2681 with the modified specification when updating these objects. 2682 2683 This approach ensures safe concurrency and determinism in that the change 2684 on the object may not be applied if the version number has changed from the 2685 last read. In other words, if two update requests specify the same base 2686 version, only one of the requests can succeed. As a result, two separate 2687 update requests that happen at the same time will not unintentionally 2688 overwrite each other. 2689 type: "object" 2690 properties: 2691 Index: 2692 type: "integer" 2693 format: "uint64" 2694 example: 373531 2695 2696 NodeSpec: 2697 type: "object" 2698 properties: 2699 Name: 2700 description: "Name for the node." 2701 type: "string" 2702 example: "my-node" 2703 Labels: 2704 description: "User-defined key/value metadata." 2705 type: "object" 2706 additionalProperties: 2707 type: "string" 2708 Role: 2709 description: "Role of the node." 2710 type: "string" 2711 enum: 2712 - "worker" 2713 - "manager" 2714 example: "manager" 2715 Availability: 2716 description: "Availability of the node." 2717 type: "string" 2718 enum: 2719 - "active" 2720 - "pause" 2721 - "drain" 2722 example: "active" 2723 example: 2724 Availability: "active" 2725 Name: "node-name" 2726 Role: "manager" 2727 Labels: 2728 foo: "bar" 2729 2730 Node: 2731 type: "object" 2732 properties: 2733 ID: 2734 type: "string" 2735 example: "24ifsmvkjbyhk" 2736 Version: 2737 $ref: "#/definitions/ObjectVersion" 2738 CreatedAt: 2739 description: | 2740 Date and time at which the node was added to the swarm in 2741 [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds. 2742 type: "string" 2743 format: "dateTime" 2744 example: "2016-08-18T10:44:24.496525531Z" 2745 UpdatedAt: 2746 description: | 2747 Date and time at which the node was last updated in 2748 [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds. 2749 type: "string" 2750 format: "dateTime" 2751 example: "2017-08-09T07:09:37.632105588Z" 2752 Spec: 2753 $ref: "#/definitions/NodeSpec" 2754 Description: 2755 $ref: "#/definitions/NodeDescription" 2756 Status: 2757 $ref: "#/definitions/NodeStatus" 2758 ManagerStatus: 2759 $ref: "#/definitions/ManagerStatus" 2760 2761 NodeDescription: 2762 description: | 2763 NodeDescription encapsulates the properties of the Node as reported by the 2764 agent. 2765 type: "object" 2766 properties: 2767 Hostname: 2768 type: "string" 2769 example: "bf3067039e47" 2770 Platform: 2771 $ref: "#/definitions/Platform" 2772 Resources: 2773 $ref: "#/definitions/ResourceObject" 2774 Engine: 2775 $ref: "#/definitions/EngineDescription" 2776 TLSInfo: 2777 $ref: "#/definitions/TLSInfo" 2778 2779 Platform: 2780 description: | 2781 Platform represents the platform (Arch/OS). 2782 type: "object" 2783 properties: 2784 Architecture: 2785 description: | 2786 Architecture represents the hardware architecture (for example, 2787 `x86_64`). 2788 type: "string" 2789 example: "x86_64" 2790 OS: 2791 description: | 2792 OS represents the Operating System (for example, `linux` or `windows`). 2793 type: "string" 2794 example: "linux" 2795 2796 EngineDescription: 2797 description: "EngineDescription provides information about an engine." 2798 type: "object" 2799 properties: 2800 EngineVersion: 2801 type: "string" 2802 example: "17.06.0" 2803 Labels: 2804 type: "object" 2805 additionalProperties: 2806 type: "string" 2807 example: 2808 foo: "bar" 2809 Plugins: 2810 type: "array" 2811 items: 2812 type: "object" 2813 properties: 2814 Type: 2815 type: "string" 2816 Name: 2817 type: "string" 2818 example: 2819 - Type: "Log" 2820 Name: "awslogs" 2821 - Type: "Log" 2822 Name: "fluentd" 2823 - Type: "Log" 2824 Name: "gcplogs" 2825 - Type: "Log" 2826 Name: "gelf" 2827 - Type: "Log" 2828 Name: "journald" 2829 - Type: "Log" 2830 Name: "json-file" 2831 - Type: "Log" 2832 Name: "logentries" 2833 - Type: "Log" 2834 Name: "splunk" 2835 - Type: "Log" 2836 Name: "syslog" 2837 - Type: "Network" 2838 Name: "bridge" 2839 - Type: "Network" 2840 Name: "host" 2841 - Type: "Network" 2842 Name: "ipvlan" 2843 - Type: "Network" 2844 Name: "macvlan" 2845 - Type: "Network" 2846 Name: "null" 2847 - Type: "Network" 2848 Name: "overlay" 2849 - Type: "Volume" 2850 Name: "local" 2851 - Type: "Volume" 2852 Name: "localhost:5000/vieux/sshfs:latest" 2853 - Type: "Volume" 2854 Name: "vieux/sshfs:latest" 2855 2856 TLSInfo: 2857 description: | 2858 Information about the issuer of leaf TLS certificates and the trusted root 2859 CA certificate. 2860 type: "object" 2861 properties: 2862 TrustRoot: 2863 description: | 2864 The root CA certificate(s) that are used to validate leaf TLS 2865 certificates. 2866 type: "string" 2867 CertIssuerSubject: 2868 description: 2869 The base64-url-safe-encoded raw subject bytes of the issuer. 2870 type: "string" 2871 CertIssuerPublicKey: 2872 description: | 2873 The base64-url-safe-encoded raw public key bytes of the issuer. 2874 type: "string" 2875 example: 2876 TrustRoot: | 2877 -----BEGIN CERTIFICATE----- 2878 MIIBajCCARCgAwIBAgIUbYqrLSOSQHoxD8CwG6Bi2PJi9c8wCgYIKoZIzj0EAwIw 2879 EzERMA8GA1UEAxMIc3dhcm0tY2EwHhcNMTcwNDI0MjE0MzAwWhcNMzcwNDE5MjE0 2880 MzAwWjATMREwDwYDVQQDEwhzd2FybS1jYTBZMBMGByqGSM49AgEGCCqGSM49AwEH 2881 A0IABJk/VyMPYdaqDXJb/VXh5n/1Yuv7iNrxV3Qb3l06XD46seovcDWs3IZNV1lf 2882 3Skyr0ofcchipoiHkXBODojJydSjQjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMB 2883 Af8EBTADAQH/MB0GA1UdDgQWBBRUXxuRcnFjDfR/RIAUQab8ZV/n4jAKBggqhkjO 2884 PQQDAgNIADBFAiAy+JTe6Uc3KyLCMiqGl2GyWGQqQDEcO3/YG36x7om65AIhAJvz 2885 pxv6zFeVEkAEEkqIYi0omA9+CjanB/6Bz4n1uw8H 2886 -----END CERTIFICATE----- 2887 CertIssuerSubject: "MBMxETAPBgNVBAMTCHN3YXJtLWNh" 2888 CertIssuerPublicKey: "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEmT9XIw9h1qoNclv9VeHmf/Vi6/uI2vFXdBveXTpcPjqx6i9wNazchk1XWV/dKTKvSh9xyGKmiIeRcE4OiMnJ1A==" 2889 2890 NodeStatus: 2891 description: | 2892 NodeStatus represents the status of a node. 2893 2894 It provides the current status of the node, as seen by the manager. 2895 type: "object" 2896 properties: 2897 State: 2898 $ref: "#/definitions/NodeState" 2899 Message: 2900 type: "string" 2901 example: "" 2902 Addr: 2903 description: "IP address of the node." 2904 type: "string" 2905 example: "172.17.0.2" 2906 2907 NodeState: 2908 description: "NodeState represents the state of a node." 2909 type: "string" 2910 enum: 2911 - "unknown" 2912 - "down" 2913 - "ready" 2914 - "disconnected" 2915 example: "ready" 2916 2917 ManagerStatus: 2918 description: | 2919 ManagerStatus represents the status of a manager. 2920 2921 It provides the current status of a node's manager component, if the node 2922 is a manager. 2923 x-nullable: true 2924 type: "object" 2925 properties: 2926 Leader: 2927 type: "boolean" 2928 default: false 2929 example: true 2930 Reachability: 2931 $ref: "#/definitions/Reachability" 2932 Addr: 2933 description: | 2934 The IP address and port at which the manager is reachable. 2935 type: "string" 2936 example: "10.0.0.46:2377" 2937 2938 Reachability: 2939 description: "Reachability represents the reachability of a node." 2940 type: "string" 2941 enum: 2942 - "unknown" 2943 - "unreachable" 2944 - "reachable" 2945 example: "reachable" 2946 2947 SwarmSpec: 2948 description: "User modifiable swarm configuration." 2949 type: "object" 2950 properties: 2951 Name: 2952 description: "Name of the swarm." 2953 type: "string" 2954 example: "default" 2955 Labels: 2956 description: "User-defined key/value metadata." 2957 type: "object" 2958 additionalProperties: 2959 type: "string" 2960 example: 2961 com.example.corp.type: "production" 2962 com.example.corp.department: "engineering" 2963 Orchestration: 2964 description: "Orchestration configuration." 2965 type: "object" 2966 x-nullable: true 2967 properties: 2968 TaskHistoryRetentionLimit: 2969 description: | 2970 The number of historic tasks to keep per instance or node. If 2971 negative, never remove completed or failed tasks. 2972 type: "integer" 2973 format: "int64" 2974 example: 10 2975 Raft: 2976 description: "Raft configuration." 2977 type: "object" 2978 properties: 2979 SnapshotInterval: 2980 description: "The number of log entries between snapshots." 2981 type: "integer" 2982 format: "uint64" 2983 example: 10000 2984 KeepOldSnapshots: 2985 description: | 2986 The number of snapshots to keep beyond the current snapshot. 2987 type: "integer" 2988 format: "uint64" 2989 LogEntriesForSlowFollowers: 2990 description: | 2991 The number of log entries to keep around to sync up slow followers 2992 after a snapshot is created. 2993 type: "integer" 2994 format: "uint64" 2995 example: 500 2996 ElectionTick: 2997 description: | 2998 The number of ticks that a follower will wait for a message from 2999 the leader before becoming a candidate and starting an election. 3000 `ElectionTick` must be greater than `HeartbeatTick`. 3001 3002 A tick currently defaults to one second, so these translate 3003 directly to seconds currently, but this is NOT guaranteed. 3004 type: "integer" 3005 example: 3 3006 HeartbeatTick: 3007 description: | 3008 The number of ticks between heartbeats. Every HeartbeatTick ticks, 3009 the leader will send a heartbeat to the followers. 3010 3011 A tick currently defaults to one second, so these translate 3012 directly to seconds currently, but this is NOT guaranteed. 3013 type: "integer" 3014 example: 1 3015 Dispatcher: 3016 description: "Dispatcher configuration." 3017 type: "object" 3018 x-nullable: true 3019 properties: 3020 HeartbeatPeriod: 3021 description: | 3022 The delay for an agent to send a heartbeat to the dispatcher. 3023 type: "integer" 3024 format: "int64" 3025 example: 5000000000 3026 CAConfig: 3027 description: "CA configuration." 3028 type: "object" 3029 x-nullable: true 3030 properties: 3031 NodeCertExpiry: 3032 description: "The duration node certificates are issued for." 3033 type: "integer" 3034 format: "int64" 3035 example: 7776000000000000 3036 ExternalCAs: 3037 description: | 3038 Configuration for forwarding signing requests to an external 3039 certificate authority. 3040 type: "array" 3041 items: 3042 type: "object" 3043 properties: 3044 Protocol: 3045 description: | 3046 Protocol for communication with the external CA (currently 3047 only `cfssl` is supported). 3048 type: "string" 3049 enum: 3050 - "cfssl" 3051 default: "cfssl" 3052 URL: 3053 description: | 3054 URL where certificate signing requests should be sent. 3055 type: "string" 3056 Options: 3057 description: | 3058 An object with key/value pairs that are interpreted as 3059 protocol-specific options for the external CA driver. 3060 type: "object" 3061 additionalProperties: 3062 type: "string" 3063 CACert: 3064 description: | 3065 The root CA certificate (in PEM format) this external CA uses 3066 to issue TLS certificates (assumed to be to the current swarm 3067 root CA certificate if not provided). 3068 type: "string" 3069 SigningCACert: 3070 description: | 3071 The desired signing CA certificate for all swarm node TLS leaf 3072 certificates, in PEM format. 3073 type: "string" 3074 SigningCAKey: 3075 description: | 3076 The desired signing CA key for all swarm node TLS leaf certificates, 3077 in PEM format. 3078 type: "string" 3079 ForceRotate: 3080 description: | 3081 An integer whose purpose is to force swarm to generate a new 3082 signing CA certificate and key, if none have been specified in 3083 `SigningCACert` and `SigningCAKey` 3084 format: "uint64" 3085 type: "integer" 3086 EncryptionConfig: 3087 description: "Parameters related to encryption-at-rest." 3088 type: "object" 3089 properties: 3090 AutoLockManagers: 3091 description: | 3092 If set, generate a key and use it to lock data stored on the 3093 managers. 3094 type: "boolean" 3095 example: false 3096 TaskDefaults: 3097 description: "Defaults for creating tasks in this cluster." 3098 type: "object" 3099 properties: 3100 LogDriver: 3101 description: | 3102 The log driver to use for tasks created in the orchestrator if 3103 unspecified by a service. 3104 3105 Updating this value only affects new tasks. Existing tasks continue 3106 to use their previously configured log driver until recreated. 3107 type: "object" 3108 properties: 3109 Name: 3110 description: | 3111 The log driver to use as a default for new tasks. 3112 type: "string" 3113 example: "json-file" 3114 Options: 3115 description: | 3116 Driver-specific options for the selectd log driver, specified 3117 as key/value pairs. 3118 type: "object" 3119 additionalProperties: 3120 type: "string" 3121 example: 3122 "max-file": "10" 3123 "max-size": "100m" 3124 3125 # The Swarm information for `GET /info`. It is the same as `GET /swarm`, but 3126 # without `JoinTokens`. 3127 ClusterInfo: 3128 description: | 3129 ClusterInfo represents information about the swarm as is returned by the 3130 "/info" endpoint. Join-tokens are not included. 3131 x-nullable: true 3132 type: "object" 3133 properties: 3134 ID: 3135 description: "The ID of the swarm." 3136 type: "string" 3137 example: "abajmipo7b4xz5ip2nrla6b11" 3138 Version: 3139 $ref: "#/definitions/ObjectVersion" 3140 CreatedAt: 3141 description: | 3142 Date and time at which the swarm was initialised in 3143 [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds. 3144 type: "string" 3145 format: "dateTime" 3146 example: "2016-08-18T10:44:24.496525531Z" 3147 UpdatedAt: 3148 description: | 3149 Date and time at which the swarm was last updated in 3150 [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds. 3151 type: "string" 3152 format: "dateTime" 3153 example: "2017-08-09T07:09:37.632105588Z" 3154 Spec: 3155 $ref: "#/definitions/SwarmSpec" 3156 TLSInfo: 3157 $ref: "#/definitions/TLSInfo" 3158 RootRotationInProgress: 3159 description: | 3160 Whether there is currently a root CA rotation in progress for the swarm 3161 type: "boolean" 3162 example: false 3163 DefaultAddrPool: 3164 description: | 3165 Default Address Pool specifies default subnet pools for global scope 3166 networks. 3167 type: "array" 3168 items: 3169 type: "string" 3170 format: "CIDR" 3171 example: ["10.10.0.0/16", "20.20.0.0/16"] 3172 SubnetSize: 3173 description: | 3174 SubnetSize specifies the subnet size of the networks created from the 3175 default subnet pool. 3176 type: "integer" 3177 format: "uint32" 3178 maximum: 29 3179 default: 24 3180 example: 24 3181 3182 JoinTokens: 3183 description: | 3184 JoinTokens contains the tokens workers and managers need to join the swarm. 3185 type: "object" 3186 properties: 3187 Worker: 3188 description: | 3189 The token workers can use to join the swarm. 3190 type: "string" 3191 example: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-1awxwuwd3z9j1z3puu7rcgdbx" 3192 Manager: 3193 description: | 3194 The token managers can use to join the swarm. 3195 type: "string" 3196 example: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-7p73s1dx5in4tatdymyhg9hu2" 3197 3198 Swarm: 3199 type: "object" 3200 allOf: 3201 - $ref: "#/definitions/ClusterInfo" 3202 - type: "object" 3203 properties: 3204 JoinTokens: 3205 $ref: "#/definitions/JoinTokens" 3206 3207 TaskSpec: 3208 description: "User modifiable task configuration." 3209 type: "object" 3210 properties: 3211 PluginSpec: 3212 type: "object" 3213 description: | 3214 Plugin spec for the service. *(Experimental release only.)* 3215 3216 <p><br /></p> 3217 3218 > **Note**: ContainerSpec, NetworkAttachmentSpec, and PluginSpec are 3219 > mutually exclusive. PluginSpec is only used when the Runtime field 3220 > is set to `plugin`. NetworkAttachmentSpec is used when the Runtime 3221 > field is set to `attachment`. 3222 properties: 3223 Name: 3224 description: "The name or 'alias' to use for the plugin." 3225 type: "string" 3226 Remote: 3227 description: "The plugin image reference to use." 3228 type: "string" 3229 Disabled: 3230 description: "Disable the plugin once scheduled." 3231 type: "boolean" 3232 PluginPrivilege: 3233 type: "array" 3234 items: 3235 description: | 3236 Describes a permission accepted by the user upon installing the 3237 plugin. 3238 type: "object" 3239 properties: 3240 Name: 3241 type: "string" 3242 Description: 3243 type: "string" 3244 Value: 3245 type: "array" 3246 items: 3247 type: "string" 3248 ContainerSpec: 3249 type: "object" 3250 description: | 3251 Container spec for the service. 3252 3253 <p><br /></p> 3254 3255 > **Note**: ContainerSpec, NetworkAttachmentSpec, and PluginSpec are 3256 > mutually exclusive. PluginSpec is only used when the Runtime field 3257 > is set to `plugin`. NetworkAttachmentSpec is used when the Runtime 3258 > field is set to `attachment`. 3259 properties: 3260 Image: 3261 description: "The image name to use for the container" 3262 type: "string" 3263 Labels: 3264 description: "User-defined key/value data." 3265 type: "object" 3266 additionalProperties: 3267 type: "string" 3268 Command: 3269 description: "The command to be run in the image." 3270 type: "array" 3271 items: 3272 type: "string" 3273 Args: 3274 description: "Arguments to the command." 3275 type: "array" 3276 items: 3277 type: "string" 3278 Hostname: 3279 description: | 3280 The hostname to use for the container, as a valid 3281 [RFC 1123](https://tools.ietf.org/html/rfc1123) hostname. 3282 type: "string" 3283 Env: 3284 description: | 3285 A list of environment variables in the form `VAR=value`. 3286 type: "array" 3287 items: 3288 type: "string" 3289 Dir: 3290 description: "The working directory for commands to run in." 3291 type: "string" 3292 User: 3293 description: "The user inside the container." 3294 type: "string" 3295 Groups: 3296 type: "array" 3297 description: | 3298 A list of additional groups that the container process will run as. 3299 items: 3300 type: "string" 3301 Privileges: 3302 type: "object" 3303 description: "Security options for the container" 3304 properties: 3305 CredentialSpec: 3306 type: "object" 3307 description: "CredentialSpec for managed service account (Windows only)" 3308 properties: 3309 File: 3310 type: "string" 3311 example: "spec.json" 3312 description: | 3313 Load credential spec from this file. The file is read by 3314 the daemon, and must be present in the `CredentialSpecs` 3315 subdirectory in the docker data directory, which defaults 3316 to `C:\ProgramData\Docker\` on Windows. 3317 3318 For example, specifying `spec.json` loads 3319 `C:\ProgramData\Docker\CredentialSpecs\spec.json`. 3320 3321 <p><br /></p> 3322 3323 > **Note**: `CredentialSpec.File` and `CredentialSpec.Registry` 3324 > are mutually exclusive. 3325 Registry: 3326 type: "string" 3327 description: | 3328 Load credential spec from this value in the Windows 3329 registry. The specified registry value must be located in: 3330 3331 `HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Virtualization\Containers\CredentialSpecs` 3332 3333 <p><br /></p> 3334 3335 3336 > **Note**: `CredentialSpec.File` and `CredentialSpec.Registry` 3337 > are mutually exclusive. 3338 SELinuxContext: 3339 type: "object" 3340 description: "SELinux labels of the container" 3341 properties: 3342 Disable: 3343 type: "boolean" 3344 description: "Disable SELinux" 3345 User: 3346 type: "string" 3347 description: "SELinux user label" 3348 Role: 3349 type: "string" 3350 description: "SELinux role label" 3351 Type: 3352 type: "string" 3353 description: "SELinux type label" 3354 Level: 3355 type: "string" 3356 description: "SELinux level label" 3357 TTY: 3358 description: "Whether a pseudo-TTY should be allocated." 3359 type: "boolean" 3360 OpenStdin: 3361 description: "Open `stdin`" 3362 type: "boolean" 3363 ReadOnly: 3364 description: "Mount the container's root filesystem as read only." 3365 type: "boolean" 3366 Mounts: 3367 description: | 3368 Specification for mounts to be added to containers created as part 3369 of the service. 3370 type: "array" 3371 items: 3372 $ref: "#/definitions/Mount" 3373 StopSignal: 3374 description: "Signal to stop the container." 3375 type: "string" 3376 StopGracePeriod: 3377 description: | 3378 Amount of time to wait for the container to terminate before 3379 forcefully killing it. 3380 type: "integer" 3381 format: "int64" 3382 HealthCheck: 3383 $ref: "#/definitions/HealthConfig" 3384 Hosts: 3385 type: "array" 3386 description: | 3387 A list of hostname/IP mappings to add to the container's `hosts` 3388 file. The format of extra hosts is specified in the 3389 [hosts(5)](http://man7.org/linux/man-pages/man5/hosts.5.html) 3390 man page: 3391 3392 IP_address canonical_hostname [aliases...] 3393 items: 3394 type: "string" 3395 DNSConfig: 3396 description: | 3397 Specification for DNS related configurations in resolver configuration 3398 file (`resolv.conf`). 3399 type: "object" 3400 properties: 3401 Nameservers: 3402 description: "The IP addresses of the name servers." 3403 type: "array" 3404 items: 3405 type: "string" 3406 Search: 3407 description: "A search list for host-name lookup." 3408 type: "array" 3409 items: 3410 type: "string" 3411 Options: 3412 description: | 3413 A list of internal resolver variables to be modified (e.g., 3414 `debug`, `ndots:3`, etc.). 3415 type: "array" 3416 items: 3417 type: "string" 3418 Secrets: 3419 description: | 3420 Secrets contains references to zero or more secrets that will be 3421 exposed to the service. 3422 type: "array" 3423 items: 3424 type: "object" 3425 properties: 3426 File: 3427 description: | 3428 File represents a specific target that is backed by a file. 3429 type: "object" 3430 properties: 3431 Name: 3432 description: | 3433 Name represents the final filename in the filesystem. 3434 type: "string" 3435 UID: 3436 description: "UID represents the file UID." 3437 type: "string" 3438 GID: 3439 description: "GID represents the file GID." 3440 type: "string" 3441 Mode: 3442 description: "Mode represents the FileMode of the file." 3443 type: "integer" 3444 format: "uint32" 3445 SecretID: 3446 description: | 3447 SecretID represents the ID of the specific secret that we're 3448 referencing. 3449 type: "string" 3450 SecretName: 3451 description: | 3452 SecretName is the name of the secret that this references, 3453 but this is just provided for lookup/display purposes. The 3454 secret in the reference will be identified by its ID. 3455 type: "string" 3456 Configs: 3457 description: | 3458 Configs contains references to zero or more configs that will be 3459 exposed to the service. 3460 type: "array" 3461 items: 3462 type: "object" 3463 properties: 3464 File: 3465 description: | 3466 File represents a specific target that is backed by a file. 3467 type: "object" 3468 properties: 3469 Name: 3470 description: | 3471 Name represents the final filename in the filesystem. 3472 type: "string" 3473 UID: 3474 description: "UID represents the file UID." 3475 type: "string" 3476 GID: 3477 description: "GID represents the file GID." 3478 type: "string" 3479 Mode: 3480 description: "Mode represents the FileMode of the file." 3481 type: "integer" 3482 format: "uint32" 3483 ConfigID: 3484 description: | 3485 ConfigID represents the ID of the specific config that we're 3486 referencing. 3487 type: "string" 3488 ConfigName: 3489 description: | 3490 ConfigName is the name of the config that this references, 3491 but this is just provided for lookup/display purposes. The 3492 config in the reference will be identified by its ID. 3493 type: "string" 3494 Isolation: 3495 type: "string" 3496 description: | 3497 Isolation technology of the containers running the service. 3498 (Windows only) 3499 enum: 3500 - "default" 3501 - "process" 3502 - "hyperv" 3503 Init: 3504 description: | 3505 Run an init inside the container that forwards signals and reaps 3506 processes. This field is omitted if empty, and the default (as 3507 configured on the daemon) is used. 3508 type: "boolean" 3509 x-nullable: true 3510 NetworkAttachmentSpec: 3511 description: | 3512 Read-only spec type for non-swarm containers attached to swarm overlay 3513 networks. 3514 3515 <p><br /></p> 3516 3517 > **Note**: ContainerSpec, NetworkAttachmentSpec, and PluginSpec are 3518 > mutually exclusive. PluginSpec is only used when the Runtime field 3519 > is set to `plugin`. NetworkAttachmentSpec is used when the Runtime 3520 > field is set to `attachment`. 3521 type: "object" 3522 properties: 3523 ContainerID: 3524 description: "ID of the container represented by this task" 3525 type: "string" 3526 Resources: 3527 description: | 3528 Resource requirements which apply to each individual container created 3529 as part of the service. 3530 type: "object" 3531 properties: 3532 Limits: 3533 description: "Define resources limits." 3534 $ref: "#/definitions/ResourceObject" 3535 Reservations: 3536 description: "Define resources reservation." 3537 $ref: "#/definitions/ResourceObject" 3538 RestartPolicy: 3539 description: | 3540 Specification for the restart policy which applies to containers 3541 created as part of this service. 3542 type: "object" 3543 properties: 3544 Condition: 3545 description: "Condition for restart." 3546 type: "string" 3547 enum: 3548 - "none" 3549 - "on-failure" 3550 - "any" 3551 Delay: 3552 description: "Delay between restart attempts." 3553 type: "integer" 3554 format: "int64" 3555 MaxAttempts: 3556 description: | 3557 Maximum attempts to restart a given container before giving up 3558 (default value is 0, which is ignored). 3559 type: "integer" 3560 format: "int64" 3561 default: 0 3562 Window: 3563 description: | 3564 Windows is the time window used to evaluate the restart policy 3565 (default value is 0, which is unbounded). 3566 type: "integer" 3567 format: "int64" 3568 default: 0 3569 Placement: 3570 type: "object" 3571 properties: 3572 Constraints: 3573 description: | 3574 An array of constraint expressions to limit the set of nodes where 3575 a task can be scheduled. Constraint expressions can either use a 3576 _match_ (`==`) or _exclude_ (`!=`) rule. Multiple constraints find 3577 nodes that satisfy every expression (AND match). Constraints can 3578 match node or Docker Engine labels as follows: 3579 3580 node attribute | matches | example 3581 ---------------------|--------------------------------|----------------------------------------------- 3582 `node.id` | Node ID | `node.id==2ivku8v2gvtg4` 3583 `node.hostname` | Node hostname | `node.hostname!=node-2` 3584 `node.role` | Node role (`manager`/`worker`) | `node.role==manager` 3585 `node.labels` | User-defined node labels | `node.labels.security==high` 3586 `engine.labels` | Docker Engine's labels | `engine.labels.operatingsystem==ubuntu-14.04` 3587 3588 `engine.labels` apply to Docker Engine labels like operating system, 3589 drivers, etc. Swarm administrators add `node.labels` for operational 3590 purposes by using the [`node update endpoint`](#operation/NodeUpdate). 3591 3592 type: "array" 3593 items: 3594 type: "string" 3595 example: 3596 - "node.hostname!=node3.corp.example.com" 3597 - "node.role!=manager" 3598 - "node.labels.type==production" 3599 Preferences: 3600 description: | 3601 Preferences provide a way to make the scheduler aware of factors 3602 such as topology. They are provided in order from highest to 3603 lowest precedence. 3604 type: "array" 3605 items: 3606 type: "object" 3607 properties: 3608 Spread: 3609 type: "object" 3610 properties: 3611 SpreadDescriptor: 3612 description: | 3613 label descriptor, such as `engine.labels.az`. 3614 type: "string" 3615 example: 3616 - Spread: 3617 SpreadDescriptor: "node.labels.datacenter" 3618 - Spread: 3619 SpreadDescriptor: "node.labels.rack" 3620 Platforms: 3621 description: | 3622 Platforms stores all the platforms that the service's image can 3623 run on. This field is used in the platform filter for scheduling. 3624 If empty, then the platform filter is off, meaning there are no 3625 scheduling restrictions. 3626 type: "array" 3627 items: 3628 $ref: "#/definitions/Platform" 3629 ForceUpdate: 3630 description: | 3631 A counter that triggers an update even if no relevant parameters have 3632 been changed. 3633 type: "integer" 3634 Runtime: 3635 description: | 3636 Runtime is the type of runtime specified for the task executor. 3637 type: "string" 3638 Networks: 3639 description: "Specifies which networks the service should attach to." 3640 type: "array" 3641 items: 3642 $ref: "#/definitions/NetworkAttachmentConfig" 3643 LogDriver: 3644 description: | 3645 Specifies the log driver to use for tasks created from this spec. If 3646 not present, the default one for the swarm will be used, finally 3647 falling back to the engine default if not specified. 3648 type: "object" 3649 properties: 3650 Name: 3651 type: "string" 3652 Options: 3653 type: "object" 3654 additionalProperties: 3655 type: "string" 3656 3657 TaskState: 3658 type: "string" 3659 enum: 3660 - "new" 3661 - "allocated" 3662 - "pending" 3663 - "assigned" 3664 - "accepted" 3665 - "preparing" 3666 - "ready" 3667 - "starting" 3668 - "running" 3669 - "complete" 3670 - "shutdown" 3671 - "failed" 3672 - "rejected" 3673 - "remove" 3674 - "orphaned" 3675 3676 Task: 3677 type: "object" 3678 properties: 3679 ID: 3680 description: "The ID of the task." 3681 type: "string" 3682 Version: 3683 $ref: "#/definitions/ObjectVersion" 3684 CreatedAt: 3685 type: "string" 3686 format: "dateTime" 3687 UpdatedAt: 3688 type: "string" 3689 format: "dateTime" 3690 Name: 3691 description: "Name of the task." 3692 type: "string" 3693 Labels: 3694 description: "User-defined key/value metadata." 3695 type: "object" 3696 additionalProperties: 3697 type: "string" 3698 Spec: 3699 $ref: "#/definitions/TaskSpec" 3700 ServiceID: 3701 description: "The ID of the service this task is part of." 3702 type: "string" 3703 Slot: 3704 type: "integer" 3705 NodeID: 3706 description: "The ID of the node that this task is on." 3707 type: "string" 3708 AssignedGenericResources: 3709 $ref: "#/definitions/GenericResources" 3710 Status: 3711 type: "object" 3712 properties: 3713 Timestamp: 3714 type: "string" 3715 format: "dateTime" 3716 State: 3717 $ref: "#/definitions/TaskState" 3718 Message: 3719 type: "string" 3720 Err: 3721 type: "string" 3722 ContainerStatus: 3723 type: "object" 3724 properties: 3725 ContainerID: 3726 type: "string" 3727 PID: 3728 type: "integer" 3729 ExitCode: 3730 type: "integer" 3731 DesiredState: 3732 $ref: "#/definitions/TaskState" 3733 example: 3734 ID: "0kzzo1i0y4jz6027t0k7aezc7" 3735 Version: 3736 Index: 71 3737 CreatedAt: "2016-06-07T21:07:31.171892745Z" 3738 UpdatedAt: "2016-06-07T21:07:31.376370513Z" 3739 Spec: 3740 ContainerSpec: 3741 Image: "redis" 3742 Resources: 3743 Limits: {} 3744 Reservations: {} 3745 RestartPolicy: 3746 Condition: "any" 3747 MaxAttempts: 0 3748 Placement: {} 3749 ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz" 3750 Slot: 1 3751 NodeID: "60gvrl6tm78dmak4yl7srz94v" 3752 Status: 3753 Timestamp: "2016-06-07T21:07:31.290032978Z" 3754 State: "running" 3755 Message: "started" 3756 ContainerStatus: 3757 ContainerID: "e5d62702a1b48d01c3e02ca1e0212a250801fa8d67caca0b6f35919ebc12f035" 3758 PID: 677 3759 DesiredState: "running" 3760 NetworksAttachments: 3761 - Network: 3762 ID: "4qvuz4ko70xaltuqbt8956gd1" 3763 Version: 3764 Index: 18 3765 CreatedAt: "2016-06-07T20:31:11.912919752Z" 3766 UpdatedAt: "2016-06-07T21:07:29.955277358Z" 3767 Spec: 3768 Name: "ingress" 3769 Labels: 3770 com.docker.swarm.internal: "true" 3771 DriverConfiguration: {} 3772 IPAMOptions: 3773 Driver: {} 3774 Configs: 3775 - Subnet: "10.255.0.0/16" 3776 Gateway: "10.255.0.1" 3777 DriverState: 3778 Name: "overlay" 3779 Options: 3780 com.docker.network.driver.overlay.vxlanid_list: "256" 3781 IPAMOptions: 3782 Driver: 3783 Name: "default" 3784 Configs: 3785 - Subnet: "10.255.0.0/16" 3786 Gateway: "10.255.0.1" 3787 Addresses: 3788 - "10.255.0.10/16" 3789 AssignedGenericResources: 3790 - DiscreteResourceSpec: 3791 Kind: "SSD" 3792 Value: 3 3793 - NamedResourceSpec: 3794 Kind: "GPU" 3795 Value: "UUID1" 3796 - NamedResourceSpec: 3797 Kind: "GPU" 3798 Value: "UUID2" 3799 3800 ServiceSpec: 3801 description: "User modifiable configuration for a service." 3802 type: object 3803 properties: 3804 Name: 3805 description: "Name of the service." 3806 type: "string" 3807 Labels: 3808 description: "User-defined key/value metadata." 3809 type: "object" 3810 additionalProperties: 3811 type: "string" 3812 TaskTemplate: 3813 $ref: "#/definitions/TaskSpec" 3814 Mode: 3815 description: "Scheduling mode for the service." 3816 type: "object" 3817 properties: 3818 Replicated: 3819 type: "object" 3820 properties: 3821 Replicas: 3822 type: "integer" 3823 format: "int64" 3824 Global: 3825 type: "object" 3826 UpdateConfig: 3827 description: "Specification for the update strategy of the service." 3828 type: "object" 3829 properties: 3830 Parallelism: 3831 description: | 3832 Maximum number of tasks to be updated in one iteration (0 means 3833 unlimited parallelism). 3834 type: "integer" 3835 format: "int64" 3836 Delay: 3837 description: "Amount of time between updates, in nanoseconds." 3838 type: "integer" 3839 format: "int64" 3840 FailureAction: 3841 description: | 3842 Action to take if an updated task fails to run, or stops running 3843 during the update. 3844 type: "string" 3845 enum: 3846 - "continue" 3847 - "pause" 3848 - "rollback" 3849 Monitor: 3850 description: | 3851 Amount of time to monitor each updated task for failures, in 3852 nanoseconds. 3853 type: "integer" 3854 format: "int64" 3855 MaxFailureRatio: 3856 description: | 3857 The fraction of tasks that may fail during an update before the 3858 failure action is invoked, specified as a floating point number 3859 between 0 and 1. 3860 type: "number" 3861 default: 0 3862 Order: 3863 description: | 3864 The order of operations when rolling out an updated task. Either 3865 the old task is shut down before the new task is started, or the 3866 new task is started before the old task is shut down. 3867 type: "string" 3868 enum: 3869 - "stop-first" 3870 - "start-first" 3871 RollbackConfig: 3872 description: "Specification for the rollback strategy of the service." 3873 type: "object" 3874 properties: 3875 Parallelism: 3876 description: | 3877 Maximum number of tasks to be rolled back in one iteration (0 means 3878 unlimited parallelism). 3879 type: "integer" 3880 format: "int64" 3881 Delay: 3882 description: | 3883 Amount of time between rollback iterations, in nanoseconds. 3884 type: "integer" 3885 format: "int64" 3886 FailureAction: 3887 description: | 3888 Action to take if an rolled back task fails to run, or stops 3889 running during the rollback. 3890 type: "string" 3891 enum: 3892 - "continue" 3893 - "pause" 3894 Monitor: 3895 description: | 3896 Amount of time to monitor each rolled back task for failures, in 3897 nanoseconds. 3898 type: "integer" 3899 format: "int64" 3900 MaxFailureRatio: 3901 description: | 3902 The fraction of tasks that may fail during a rollback before the 3903 failure action is invoked, specified as a floating point number 3904 between 0 and 1. 3905 type: "number" 3906 default: 0 3907 Order: 3908 description: | 3909 The order of operations when rolling back a task. Either the old 3910 task is shut down before the new task is started, or the new task 3911 is started before the old task is shut down. 3912 type: "string" 3913 enum: 3914 - "stop-first" 3915 - "start-first" 3916 Networks: 3917 description: "Specifies which networks the service should attach to." 3918 type: "array" 3919 items: 3920 $ref: "#/definitions/NetworkAttachmentConfig" 3921 3922 EndpointSpec: 3923 $ref: "#/definitions/EndpointSpec" 3924 3925 EndpointPortConfig: 3926 type: "object" 3927 properties: 3928 Name: 3929 type: "string" 3930 Protocol: 3931 type: "string" 3932 enum: 3933 - "tcp" 3934 - "udp" 3935 - "sctp" 3936 TargetPort: 3937 description: "The port inside the container." 3938 type: "integer" 3939 PublishedPort: 3940 description: "The port on the swarm hosts." 3941 type: "integer" 3942 PublishMode: 3943 description: | 3944 The mode in which port is published. 3945 3946 <p><br /></p> 3947 3948 - "ingress" makes the target port accessible on every node, 3949 regardless of whether there is a task for the service running on 3950 that node or not. 3951 - "host" bypasses the routing mesh and publish the port directly on 3952 the swarm node where that service is running. 3953 3954 type: "string" 3955 enum: 3956 - "ingress" 3957 - "host" 3958 default: "ingress" 3959 example: "ingress" 3960 3961 EndpointSpec: 3962 description: "Properties that can be configured to access and load balance a service." 3963 type: "object" 3964 properties: 3965 Mode: 3966 description: | 3967 The mode of resolution to use for internal load balancing between tasks. 3968 type: "string" 3969 enum: 3970 - "vip" 3971 - "dnsrr" 3972 default: "vip" 3973 Ports: 3974 description: | 3975 List of exposed ports that this service is accessible on from the 3976 outside. Ports can only be provided if `vip` resolution mode is used. 3977 type: "array" 3978 items: 3979 $ref: "#/definitions/EndpointPortConfig" 3980 3981 Service: 3982 type: "object" 3983 properties: 3984 ID: 3985 type: "string" 3986 Version: 3987 $ref: "#/definitions/ObjectVersion" 3988 CreatedAt: 3989 type: "string" 3990 format: "dateTime" 3991 UpdatedAt: 3992 type: "string" 3993 format: "dateTime" 3994 Spec: 3995 $ref: "#/definitions/ServiceSpec" 3996 Endpoint: 3997 type: "object" 3998 properties: 3999 Spec: 4000 $ref: "#/definitions/EndpointSpec" 4001 Ports: 4002 type: "array" 4003 items: 4004 $ref: "#/definitions/EndpointPortConfig" 4005 VirtualIPs: 4006 type: "array" 4007 items: 4008 type: "object" 4009 properties: 4010 NetworkID: 4011 type: "string" 4012 Addr: 4013 type: "string" 4014 UpdateStatus: 4015 description: "The status of a service update." 4016 type: "object" 4017 properties: 4018 State: 4019 type: "string" 4020 enum: 4021 - "updating" 4022 - "paused" 4023 - "completed" 4024 StartedAt: 4025 type: "string" 4026 format: "dateTime" 4027 CompletedAt: 4028 type: "string" 4029 format: "dateTime" 4030 Message: 4031 type: "string" 4032 example: 4033 ID: "9mnpnzenvg8p8tdbtq4wvbkcz" 4034 Version: 4035 Index: 19 4036 CreatedAt: "2016-06-07T21:05:51.880065305Z" 4037 UpdatedAt: "2016-06-07T21:07:29.962229872Z" 4038 Spec: 4039 Name: "hopeful_cori" 4040 TaskTemplate: 4041 ContainerSpec: 4042 Image: "redis" 4043 Resources: 4044 Limits: {} 4045 Reservations: {} 4046 RestartPolicy: 4047 Condition: "any" 4048 MaxAttempts: 0 4049 Placement: {} 4050 ForceUpdate: 0 4051 Mode: 4052 Replicated: 4053 Replicas: 1 4054 UpdateConfig: 4055 Parallelism: 1 4056 Delay: 1000000000 4057 FailureAction: "pause" 4058 Monitor: 15000000000 4059 MaxFailureRatio: 0.15 4060 RollbackConfig: 4061 Parallelism: 1 4062 Delay: 1000000000 4063 FailureAction: "pause" 4064 Monitor: 15000000000 4065 MaxFailureRatio: 0.15 4066 EndpointSpec: 4067 Mode: "vip" 4068 Ports: 4069 - 4070 Protocol: "tcp" 4071 TargetPort: 6379 4072 PublishedPort: 30001 4073 Endpoint: 4074 Spec: 4075 Mode: "vip" 4076 Ports: 4077 - 4078 Protocol: "tcp" 4079 TargetPort: 6379 4080 PublishedPort: 30001 4081 Ports: 4082 - 4083 Protocol: "tcp" 4084 TargetPort: 6379 4085 PublishedPort: 30001 4086 VirtualIPs: 4087 - 4088 NetworkID: "4qvuz4ko70xaltuqbt8956gd1" 4089 Addr: "10.255.0.2/16" 4090 - 4091 NetworkID: "4qvuz4ko70xaltuqbt8956gd1" 4092 Addr: "10.255.0.3/16" 4093 4094 ImageDeleteResponseItem: 4095 type: "object" 4096 properties: 4097 Untagged: 4098 description: "The image ID of an image that was untagged" 4099 type: "string" 4100 Deleted: 4101 description: "The image ID of an image that was deleted" 4102 type: "string" 4103 4104 ServiceUpdateResponse: 4105 type: "object" 4106 properties: 4107 Warnings: 4108 description: "Optional warning messages" 4109 type: "array" 4110 items: 4111 type: "string" 4112 example: 4113 Warning: "unable to pin image doesnotexist:latest to digest: image library/doesnotexist:latest not found" 4114 4115 ContainerSummary: 4116 type: "array" 4117 items: 4118 type: "object" 4119 properties: 4120 Id: 4121 description: "The ID of this container" 4122 type: "string" 4123 x-go-name: "ID" 4124 Names: 4125 description: "The names that this container has been given" 4126 type: "array" 4127 items: 4128 type: "string" 4129 Image: 4130 description: "The name of the image used when creating this container" 4131 type: "string" 4132 ImageID: 4133 description: "The ID of the image that this container was created from" 4134 type: "string" 4135 Command: 4136 description: "Command to run when starting the container" 4137 type: "string" 4138 Created: 4139 description: "When the container was created" 4140 type: "integer" 4141 format: "int64" 4142 Ports: 4143 description: "The ports exposed by this container" 4144 type: "array" 4145 items: 4146 $ref: "#/definitions/Port" 4147 SizeRw: 4148 description: "The size of files that have been created or changed by this container" 4149 type: "integer" 4150 format: "int64" 4151 SizeRootFs: 4152 description: "The total size of all the files in this container" 4153 type: "integer" 4154 format: "int64" 4155 Labels: 4156 description: "User-defined key/value metadata." 4157 type: "object" 4158 additionalProperties: 4159 type: "string" 4160 State: 4161 description: "The state of this container (e.g. `Exited`)" 4162 type: "string" 4163 Status: 4164 description: "Additional human-readable status of this container (e.g. `Exit 0`)" 4165 type: "string" 4166 HostConfig: 4167 type: "object" 4168 properties: 4169 NetworkMode: 4170 type: "string" 4171 NetworkSettings: 4172 description: "A summary of the container's network settings" 4173 type: "object" 4174 properties: 4175 Networks: 4176 type: "object" 4177 additionalProperties: 4178 $ref: "#/definitions/EndpointSettings" 4179 Mounts: 4180 type: "array" 4181 items: 4182 $ref: "#/definitions/MountPoint" 4183 4184 Driver: 4185 description: "Driver represents a driver (network, logging, secrets)." 4186 type: "object" 4187 required: [Name] 4188 properties: 4189 Name: 4190 description: "Name of the driver." 4191 type: "string" 4192 x-nullable: false 4193 example: "some-driver" 4194 Options: 4195 description: "Key/value map of driver-specific options." 4196 type: "object" 4197 x-nullable: false 4198 additionalProperties: 4199 type: "string" 4200 example: 4201 OptionA: "value for driver-specific option A" 4202 OptionB: "value for driver-specific option B" 4203 4204 SecretSpec: 4205 type: "object" 4206 properties: 4207 Name: 4208 description: "User-defined name of the secret." 4209 type: "string" 4210 Labels: 4211 description: "User-defined key/value metadata." 4212 type: "object" 4213 additionalProperties: 4214 type: "string" 4215 example: 4216 com.example.some-label: "some-value" 4217 com.example.some-other-label: "some-other-value" 4218 Data: 4219 description: | 4220 Base64-url-safe-encoded ([RFC 4648](https://tools.ietf.org/html/rfc4648#section-5)) 4221 data to store as secret. 4222 4223 This field is only used to _create_ a secret, and is not returned by 4224 other endpoints. 4225 type: "string" 4226 example: "" 4227 Driver: 4228 description: | 4229 Name of the secrets driver used to fetch the secret's value from an 4230 external secret store. 4231 $ref: "#/definitions/Driver" 4232 Templating: 4233 description: | 4234 Templating driver, if applicable 4235 4236 Templating controls whether and how to evaluate the config payload as 4237 a template. If no driver is set, no templating is used. 4238 $ref: "#/definitions/Driver" 4239 4240 Secret: 4241 type: "object" 4242 properties: 4243 ID: 4244 type: "string" 4245 example: "blt1owaxmitz71s9v5zh81zun" 4246 Version: 4247 $ref: "#/definitions/ObjectVersion" 4248 CreatedAt: 4249 type: "string" 4250 format: "dateTime" 4251 example: "2017-07-20T13:55:28.678958722Z" 4252 UpdatedAt: 4253 type: "string" 4254 format: "dateTime" 4255 example: "2017-07-20T13:55:28.678958722Z" 4256 Spec: 4257 $ref: "#/definitions/SecretSpec" 4258 4259 ConfigSpec: 4260 type: "object" 4261 properties: 4262 Name: 4263 description: "User-defined name of the config." 4264 type: "string" 4265 Labels: 4266 description: "User-defined key/value metadata." 4267 type: "object" 4268 additionalProperties: 4269 type: "string" 4270 Data: 4271 description: | 4272 Base64-url-safe-encoded ([RFC 4648](https://tools.ietf.org/html/rfc4648#section-5)) 4273 config data. 4274 type: "string" 4275 Templating: 4276 description: | 4277 Templating driver, if applicable 4278 4279 Templating controls whether and how to evaluate the config payload as 4280 a template. If no driver is set, no templating is used. 4281 $ref: "#/definitions/Driver" 4282 4283 Config: 4284 type: "object" 4285 properties: 4286 ID: 4287 type: "string" 4288 Version: 4289 $ref: "#/definitions/ObjectVersion" 4290 CreatedAt: 4291 type: "string" 4292 format: "dateTime" 4293 UpdatedAt: 4294 type: "string" 4295 format: "dateTime" 4296 Spec: 4297 $ref: "#/definitions/ConfigSpec" 4298 4299 ContainerState: 4300 description: | 4301 ContainerState stores container's running state. It's part of ContainerJSONBase 4302 and will be returned by the "inspect" command. 4303 type: "object" 4304 properties: 4305 Status: 4306 description: | 4307 String representation of the container state. Can be one of "created", 4308 "running", "paused", "restarting", "removing", "exited", or "dead". 4309 type: "string" 4310 enum: ["created", "running", "paused", "restarting", "removing", "exited", "dead"] 4311 example: "running" 4312 Running: 4313 description: | 4314 Whether this container is running. 4315 4316 Note that a running container can be _paused_. The `Running` and `Paused` 4317 booleans are not mutually exclusive: 4318 4319 When pausing a container (on Linux), the freezer cgroup is used to suspend 4320 all processes in the container. Freezing the process requires the process to 4321 be running. As a result, paused containers are both `Running` _and_ `Paused`. 4322 4323 Use the `Status` field instead to determine if a container's state is "running". 4324 type: "boolean" 4325 example: true 4326 Paused: 4327 description: "Whether this container is paused." 4328 type: "boolean" 4329 example: false 4330 Restarting: 4331 description: "Whether this container is restarting." 4332 type: "boolean" 4333 example: false 4334 OOMKilled: 4335 description: | 4336 Whether this container has been killed because it ran out of memory. 4337 type: "boolean" 4338 example: false 4339 Dead: 4340 type: "boolean" 4341 example: false 4342 Pid: 4343 description: "The process ID of this container" 4344 type: "integer" 4345 example: 1234 4346 ExitCode: 4347 description: "The last exit code of this container" 4348 type: "integer" 4349 example: 0 4350 Error: 4351 type: "string" 4352 StartedAt: 4353 description: "The time when this container was last started." 4354 type: "string" 4355 example: "2020-01-06T09:06:59.461876391Z" 4356 FinishedAt: 4357 description: "The time when this container last exited." 4358 type: "string" 4359 example: "2020-01-06T09:07:59.461876391Z" 4360 Health: 4361 x-nullable: true 4362 $ref: "#/definitions/Health" 4363 4364 ContainerWaitResponse: 4365 description: "OK response to ContainerWait operation" 4366 type: "object" 4367 x-go-name: "ContainerWaitOKBody" 4368 title: "ContainerWaitResponse" 4369 required: [StatusCode] 4370 properties: 4371 StatusCode: 4372 description: "Exit code of the container" 4373 type: "integer" 4374 x-nullable: false 4375 Error: 4376 $ref: "#/definitions/ContainerWaitExitError" 4377 4378 ContainerWaitExitError: 4379 description: "container waiting error, if any" 4380 type: "object" 4381 x-go-name: "ContainerWaitOKBodyError" 4382 properties: 4383 Message: 4384 description: "Details of an error" 4385 type: "string" 4386 4387 SystemVersion: 4388 type: "object" 4389 description: | 4390 Response of Engine API: GET "/version" 4391 properties: 4392 Platform: 4393 type: "object" 4394 required: [Name] 4395 properties: 4396 Name: 4397 type: "string" 4398 Components: 4399 type: "array" 4400 description: | 4401 Information about system components 4402 items: 4403 type: "object" 4404 x-go-name: ComponentVersion 4405 required: [Name, Version] 4406 properties: 4407 Name: 4408 description: | 4409 Name of the component 4410 type: "string" 4411 example: "Engine" 4412 Version: 4413 description: | 4414 Version of the component 4415 type: "string" 4416 x-nullable: false 4417 example: "19.03.12" 4418 Details: 4419 description: | 4420 Key/value pairs of strings with additional information about the 4421 component. These values are intended for informational purposes 4422 only, and their content is not defined, and not part of the API 4423 specification. 4424 4425 These messages can be printed by the client as information to the user. 4426 type: "object" 4427 x-nullable: true 4428 Version: 4429 description: "The version of the daemon" 4430 type: "string" 4431 example: "19.03.12" 4432 ApiVersion: 4433 description: | 4434 The default (and highest) API version that is supported by the daemon 4435 type: "string" 4436 example: "1.40" 4437 MinAPIVersion: 4438 description: | 4439 The minimum API version that is supported by the daemon 4440 type: "string" 4441 example: "1.12" 4442 GitCommit: 4443 description: | 4444 The Git commit of the source code that was used to build the daemon 4445 type: "string" 4446 example: "48a66213fe" 4447 GoVersion: 4448 description: | 4449 The version Go used to compile the daemon, and the version of the Go 4450 runtime in use. 4451 type: "string" 4452 example: "go1.13.14" 4453 Os: 4454 description: | 4455 The operating system that the daemon is running on ("linux" or "windows") 4456 type: "string" 4457 example: "linux" 4458 Arch: 4459 description: | 4460 The architecture that the daemon is running on 4461 type: "string" 4462 example: "amd64" 4463 KernelVersion: 4464 description: | 4465 The kernel version (`uname -r`) that the daemon is running on. 4466 4467 This field is omitted when empty. 4468 type: "string" 4469 example: "4.19.76-linuxkit" 4470 Experimental: 4471 description: | 4472 Indicates if the daemon is started with experimental features enabled. 4473 4474 This field is omitted when empty / false. 4475 type: "boolean" 4476 example: true 4477 BuildTime: 4478 description: | 4479 The date and time that the daemon was compiled. 4480 type: "string" 4481 example: "2020-06-22T15:49:27.000000000+00:00" 4482 4483 4484 SystemInfo: 4485 type: "object" 4486 properties: 4487 ID: 4488 description: | 4489 Unique identifier of the daemon. 4490 4491 <p><br /></p> 4492 4493 > **Note**: The format of the ID itself is not part of the API, and 4494 > should not be considered stable. 4495 type: "string" 4496 example: "7TRN:IPZB:QYBB:VPBQ:UMPP:KARE:6ZNR:XE6T:7EWV:PKF4:ZOJD:TPYS" 4497 Containers: 4498 description: "Total number of containers on the host." 4499 type: "integer" 4500 example: 14 4501 ContainersRunning: 4502 description: | 4503 Number of containers with status `"running"`. 4504 type: "integer" 4505 example: 3 4506 ContainersPaused: 4507 description: | 4508 Number of containers with status `"paused"`. 4509 type: "integer" 4510 example: 1 4511 ContainersStopped: 4512 description: | 4513 Number of containers with status `"stopped"`. 4514 type: "integer" 4515 example: 10 4516 Images: 4517 description: | 4518 Total number of images on the host. 4519 4520 Both _tagged_ and _untagged_ (dangling) images are counted. 4521 type: "integer" 4522 example: 508 4523 Driver: 4524 description: "Name of the storage driver in use." 4525 type: "string" 4526 example: "overlay2" 4527 DriverStatus: 4528 description: | 4529 Information specific to the storage driver, provided as 4530 "label" / "value" pairs. 4531 4532 This information is provided by the storage driver, and formatted 4533 in a way consistent with the output of `docker info` on the command 4534 line. 4535 4536 <p><br /></p> 4537 4538 > **Note**: The information returned in this field, including the 4539 > formatting of values and labels, should not be considered stable, 4540 > and may change without notice. 4541 type: "array" 4542 items: 4543 type: "array" 4544 items: 4545 type: "string" 4546 example: 4547 - ["Backing Filesystem", "extfs"] 4548 - ["Supports d_type", "true"] 4549 - ["Native Overlay Diff", "true"] 4550 DockerRootDir: 4551 description: | 4552 Root directory of persistent Docker state. 4553 4554 Defaults to `/var/lib/docker` on Linux, and `C:\ProgramData\docker` 4555 on Windows. 4556 type: "string" 4557 example: "/var/lib/docker" 4558 SystemStatus: 4559 description: | 4560 Status information about this node (standalone Swarm API). 4561 4562 <p><br /></p> 4563 4564 > **Note**: The information returned in this field is only propagated 4565 > by the Swarm standalone API, and is empty (`null`) when using 4566 > built-in swarm mode. 4567 type: "array" 4568 items: 4569 type: "array" 4570 items: 4571 type: "string" 4572 example: 4573 - ["Role", "primary"] 4574 - ["State", "Healthy"] 4575 - ["Strategy", "spread"] 4576 - ["Filters", "health, port, containerslots, dependency, affinity, constraint, whitelist"] 4577 - ["Nodes", "2"] 4578 - [" swarm-agent-00", "192.168.99.102:2376"] 4579 - [" └ ID", "5CT6:FBGO:RVGO:CZL4:PB2K:WCYN:2JSV:KSHH:GGFW:QOPG:6J5Q:IOZ2|192.168.99.102:2376"] 4580 - [" └ Status", "Healthy"] 4581 - [" └ Containers", "1 (1 Running, 0 Paused, 0 Stopped)"] 4582 - [" └ Reserved CPUs", "0 / 1"] 4583 - [" └ Reserved Memory", "0 B / 1.021 GiB"] 4584 - [" └ Labels", "kernelversion=4.4.74-boot2docker, operatingsystem=Boot2Docker 17.06.0-ce (TCL 7.2); HEAD : 0672754 - Thu Jun 29 00:06:31 UTC 2017, ostype=linux, provider=virtualbox, storagedriver=aufs"] 4585 - [" └ UpdatedAt", "2017-08-09T10:03:46Z"] 4586 - [" └ ServerVersion", "17.06.0-ce"] 4587 - [" swarm-manager", "192.168.99.101:2376"] 4588 - [" └ ID", "TAMD:7LL3:SEF7:LW2W:4Q2X:WVFH:RTXX:JSYS:XY2P:JEHL:ZMJK:JGIW|192.168.99.101:2376"] 4589 - [" └ Status", "Healthy"] 4590 - [" └ Containers", "2 (2 Running, 0 Paused, 0 Stopped)"] 4591 - [" └ Reserved CPUs", "0 / 1"] 4592 - [" └ Reserved Memory", "0 B / 1.021 GiB"] 4593 - [" └ Labels", "kernelversion=4.4.74-boot2docker, operatingsystem=Boot2Docker 17.06.0-ce (TCL 7.2); HEAD : 0672754 - Thu Jun 29 00:06:31 UTC 2017, ostype=linux, provider=virtualbox, storagedriver=aufs"] 4594 - [" └ UpdatedAt", "2017-08-09T10:04:11Z"] 4595 - [" └ ServerVersion", "17.06.0-ce"] 4596 Plugins: 4597 $ref: "#/definitions/PluginsInfo" 4598 MemoryLimit: 4599 description: "Indicates if the host has memory limit support enabled." 4600 type: "boolean" 4601 example: true 4602 SwapLimit: 4603 description: "Indicates if the host has memory swap limit support enabled." 4604 type: "boolean" 4605 example: true 4606 KernelMemory: 4607 description: "Indicates if the host has kernel memory limit support enabled." 4608 type: "boolean" 4609 example: true 4610 CpuCfsPeriod: 4611 description: | 4612 Indicates if CPU CFS(Completely Fair Scheduler) period is supported by 4613 the host. 4614 type: "boolean" 4615 example: true 4616 CpuCfsQuota: 4617 description: | 4618 Indicates if CPU CFS(Completely Fair Scheduler) quota is supported by 4619 the host. 4620 type: "boolean" 4621 example: true 4622 CPUShares: 4623 description: | 4624 Indicates if CPU Shares limiting is supported by the host. 4625 type: "boolean" 4626 example: true 4627 CPUSet: 4628 description: | 4629 Indicates if CPUsets (cpuset.cpus, cpuset.mems) are supported by the host. 4630 4631 See [cpuset(7)](https://www.kernel.org/doc/Documentation/cgroup-v1/cpusets.txt) 4632 type: "boolean" 4633 example: true 4634 OomKillDisable: 4635 description: "Indicates if OOM killer disable is supported on the host." 4636 type: "boolean" 4637 IPv4Forwarding: 4638 description: "Indicates IPv4 forwarding is enabled." 4639 type: "boolean" 4640 example: true 4641 BridgeNfIptables: 4642 description: "Indicates if `bridge-nf-call-iptables` is available on the host." 4643 type: "boolean" 4644 example: true 4645 BridgeNfIp6tables: 4646 description: "Indicates if `bridge-nf-call-ip6tables` is available on the host." 4647 type: "boolean" 4648 example: true 4649 Debug: 4650 description: | 4651 Indicates if the daemon is running in debug-mode / with debug-level 4652 logging enabled. 4653 type: "boolean" 4654 example: true 4655 NFd: 4656 description: | 4657 The total number of file Descriptors in use by the daemon process. 4658 4659 This information is only returned if debug-mode is enabled. 4660 type: "integer" 4661 example: 64 4662 NGoroutines: 4663 description: | 4664 The number of goroutines that currently exist. 4665 4666 This information is only returned if debug-mode is enabled. 4667 type: "integer" 4668 example: 174 4669 SystemTime: 4670 description: | 4671 Current system-time in [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) 4672 format with nano-seconds. 4673 type: "string" 4674 example: "2017-08-08T20:28:29.06202363Z" 4675 LoggingDriver: 4676 description: | 4677 The logging driver to use as a default for new containers. 4678 type: "string" 4679 CgroupDriver: 4680 description: | 4681 The driver to use for managing cgroups. 4682 type: "string" 4683 enum: ["cgroupfs", "systemd"] 4684 default: "cgroupfs" 4685 example: "cgroupfs" 4686 NEventsListener: 4687 description: "Number of event listeners subscribed." 4688 type: "integer" 4689 example: 30 4690 KernelVersion: 4691 description: | 4692 Kernel version of the host. 4693 4694 On Linux, this information obtained from `uname`. On Windows this 4695 information is queried from the <kbd>HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\</kbd> 4696 registry value, for example _"10.0 14393 (14393.1198.amd64fre.rs1_release_sec.170427-1353)"_. 4697 type: "string" 4698 example: "4.9.38-moby" 4699 OperatingSystem: 4700 description: | 4701 Name of the host's operating system, for example: "Ubuntu 16.04.2 LTS" 4702 or "Windows Server 2016 Datacenter" 4703 type: "string" 4704 example: "Alpine Linux v3.5" 4705 OSType: 4706 description: | 4707 Generic type of the operating system of the host, as returned by the 4708 Go runtime (`GOOS`). 4709 4710 Currently returned values are "linux" and "windows". A full list of 4711 possible values can be found in the [Go documentation](https://golang.org/doc/install/source#environment). 4712 type: "string" 4713 example: "linux" 4714 Architecture: 4715 description: | 4716 Hardware architecture of the host, as returned by the Go runtime 4717 (`GOARCH`). 4718 4719 A full list of possible values can be found in the [Go documentation](https://golang.org/doc/install/source#environment). 4720 type: "string" 4721 example: "x86_64" 4722 NCPU: 4723 description: | 4724 The number of logical CPUs usable by the daemon. 4725 4726 The number of available CPUs is checked by querying the operating 4727 system when the daemon starts. Changes to operating system CPU 4728 allocation after the daemon is started are not reflected. 4729 type: "integer" 4730 example: 4 4731 MemTotal: 4732 description: | 4733 Total amount of physical memory available on the host, in bytes. 4734 type: "integer" 4735 format: "int64" 4736 example: 2095882240 4737 4738 IndexServerAddress: 4739 description: | 4740 Address / URL of the index server that is used for image search, 4741 and as a default for user authentication for Docker Hub and Docker Cloud. 4742 default: "https://index.docker.io/v1/" 4743 type: "string" 4744 example: "https://index.docker.io/v1/" 4745 RegistryConfig: 4746 $ref: "#/definitions/RegistryServiceConfig" 4747 GenericResources: 4748 $ref: "#/definitions/GenericResources" 4749 HttpProxy: 4750 description: | 4751 HTTP-proxy configured for the daemon. This value is obtained from the 4752 [`HTTP_PROXY`](https://www.gnu.org/software/wget/manual/html_node/Proxies.html) environment variable. 4753 Credentials ([user info component](https://tools.ietf.org/html/rfc3986#section-3.2.1)) in the proxy URL 4754 are masked in the API response. 4755 4756 Containers do not automatically inherit this configuration. 4757 type: "string" 4758 example: "http://xxxxx:xxxxx@proxy.corp.example.com:8080" 4759 HttpsProxy: 4760 description: | 4761 HTTPS-proxy configured for the daemon. This value is obtained from the 4762 [`HTTPS_PROXY`](https://www.gnu.org/software/wget/manual/html_node/Proxies.html) environment variable. 4763 Credentials ([user info component](https://tools.ietf.org/html/rfc3986#section-3.2.1)) in the proxy URL 4764 are masked in the API response. 4765 4766 Containers do not automatically inherit this configuration. 4767 type: "string" 4768 example: "https://xxxxx:xxxxx@proxy.corp.example.com:4443" 4769 NoProxy: 4770 description: | 4771 Comma-separated list of domain extensions for which no proxy should be 4772 used. This value is obtained from the [`NO_PROXY`](https://www.gnu.org/software/wget/manual/html_node/Proxies.html) 4773 environment variable. 4774 4775 Containers do not automatically inherit this configuration. 4776 type: "string" 4777 example: "*.local, 169.254/16" 4778 Name: 4779 description: "Hostname of the host." 4780 type: "string" 4781 example: "node5.corp.example.com" 4782 Labels: 4783 description: | 4784 User-defined labels (key/value metadata) as set on the daemon. 4785 4786 <p><br /></p> 4787 4788 > **Note**: When part of a Swarm, nodes can both have _daemon_ labels, 4789 > set through the daemon configuration, and _node_ labels, set from a 4790 > manager node in the Swarm. Node labels are not included in this 4791 > field. Node labels can be retrieved using the `/nodes/(id)` endpoint 4792 > on a manager node in the Swarm. 4793 type: "array" 4794 items: 4795 type: "string" 4796 example: ["storage=ssd", "production"] 4797 ExperimentalBuild: 4798 description: | 4799 Indicates if experimental features are enabled on the daemon. 4800 type: "boolean" 4801 example: true 4802 ServerVersion: 4803 description: | 4804 Version string of the daemon. 4805 4806 > **Note**: the [standalone Swarm API](https://docs.docker.com/swarm/swarm-api/) 4807 > returns the Swarm version instead of the daemon version, for example 4808 > `swarm/1.2.8`. 4809 type: "string" 4810 example: "17.06.0-ce" 4811 ClusterStore: 4812 description: | 4813 URL of the distributed storage backend. 4814 4815 4816 The storage backend is used for multihost networking (to store 4817 network and endpoint information) and by the node discovery mechanism. 4818 4819 <p><br /></p> 4820 4821 > **Note**: This field is only propagated when using standalone Swarm 4822 > mode, and overlay networking using an external k/v store. Overlay 4823 > networks with Swarm mode enabled use the built-in raft store, and 4824 > this field will be empty. 4825 type: "string" 4826 example: "consul://consul.corp.example.com:8600/some/path" 4827 ClusterAdvertise: 4828 description: | 4829 The network endpoint that the Engine advertises for the purpose of 4830 node discovery. ClusterAdvertise is a `host:port` combination on which 4831 the daemon is reachable by other hosts. 4832 4833 <p><br /></p> 4834 4835 > **Note**: This field is only propagated when using standalone Swarm 4836 > mode, and overlay networking using an external k/v store. Overlay 4837 > networks with Swarm mode enabled use the built-in raft store, and 4838 > this field will be empty. 4839 type: "string" 4840 example: "node5.corp.example.com:8000" 4841 Runtimes: 4842 description: | 4843 List of [OCI compliant](https://github.com/opencontainers/runtime-spec) 4844 runtimes configured on the daemon. Keys hold the "name" used to 4845 reference the runtime. 4846 4847 The Docker daemon relies on an OCI compliant runtime (invoked via the 4848 `containerd` daemon) as its interface to the Linux kernel namespaces, 4849 cgroups, and SELinux. 4850 4851 The default runtime is `runc`, and automatically configured. Additional 4852 runtimes can be configured by the user and will be listed here. 4853 type: "object" 4854 additionalProperties: 4855 $ref: "#/definitions/Runtime" 4856 default: 4857 runc: 4858 path: "runc" 4859 example: 4860 runc: 4861 path: "runc" 4862 runc-master: 4863 path: "/go/bin/runc" 4864 custom: 4865 path: "/usr/local/bin/my-oci-runtime" 4866 runtimeArgs: ["--debug", "--systemd-cgroup=false"] 4867 DefaultRuntime: 4868 description: | 4869 Name of the default OCI runtime that is used when starting containers. 4870 4871 The default can be overridden per-container at create time. 4872 type: "string" 4873 default: "runc" 4874 example: "runc" 4875 Swarm: 4876 $ref: "#/definitions/SwarmInfo" 4877 LiveRestoreEnabled: 4878 description: | 4879 Indicates if live restore is enabled. 4880 4881 If enabled, containers are kept running when the daemon is shutdown 4882 or upon daemon start if running containers are detected. 4883 type: "boolean" 4884 default: false 4885 example: false 4886 Isolation: 4887 description: | 4888 Represents the isolation technology to use as a default for containers. 4889 The supported values are platform-specific. 4890 4891 If no isolation value is specified on daemon start, on Windows client, 4892 the default is `hyperv`, and on Windows server, the default is `process`. 4893 4894 This option is currently not used on other platforms. 4895 default: "default" 4896 type: "string" 4897 enum: 4898 - "default" 4899 - "hyperv" 4900 - "process" 4901 InitBinary: 4902 description: | 4903 Name and, optional, path of the `docker-init` binary. 4904 4905 If the path is omitted, the daemon searches the host's `$PATH` for the 4906 binary and uses the first result. 4907 type: "string" 4908 example: "docker-init" 4909 ContainerdCommit: 4910 $ref: "#/definitions/Commit" 4911 RuncCommit: 4912 $ref: "#/definitions/Commit" 4913 InitCommit: 4914 $ref: "#/definitions/Commit" 4915 SecurityOptions: 4916 description: | 4917 List of security features that are enabled on the daemon, such as 4918 apparmor, seccomp, SELinux, and user-namespaces (userns). 4919 4920 Additional configuration options for each security feature may 4921 be present, and are included as a comma-separated list of key/value 4922 pairs. 4923 type: "array" 4924 items: 4925 type: "string" 4926 example: 4927 - "name=apparmor" 4928 - "name=seccomp,profile=default" 4929 - "name=selinux" 4930 - "name=userns" 4931 ProductLicense: 4932 description: | 4933 Reports a summary of the product license on the daemon. 4934 4935 If a commercial license has been applied to the daemon, information 4936 such as number of nodes, and expiration are included. 4937 type: "string" 4938 example: "Community Engine" 4939 Warnings: 4940 description: | 4941 List of warnings / informational messages about missing features, or 4942 issues related to the daemon configuration. 4943 4944 These messages can be printed by the client as information to the user. 4945 type: "array" 4946 items: 4947 type: "string" 4948 example: 4949 - "WARNING: No memory limit support" 4950 - "WARNING: bridge-nf-call-iptables is disabled" 4951 - "WARNING: bridge-nf-call-ip6tables is disabled" 4952 4953 4954 # PluginsInfo is a temp struct holding Plugins name 4955 # registered with docker daemon. It is used by Info struct 4956 PluginsInfo: 4957 description: | 4958 Available plugins per type. 4959 4960 <p><br /></p> 4961 4962 > **Note**: Only unmanaged (V1) plugins are included in this list. 4963 > V1 plugins are "lazily" loaded, and are not returned in this list 4964 > if there is no resource using the plugin. 4965 type: "object" 4966 properties: 4967 Volume: 4968 description: "Names of available volume-drivers, and network-driver plugins." 4969 type: "array" 4970 items: 4971 type: "string" 4972 example: ["local"] 4973 Network: 4974 description: "Names of available network-drivers, and network-driver plugins." 4975 type: "array" 4976 items: 4977 type: "string" 4978 example: ["bridge", "host", "ipvlan", "macvlan", "null", "overlay"] 4979 Authorization: 4980 description: "Names of available authorization plugins." 4981 type: "array" 4982 items: 4983 type: "string" 4984 example: ["img-authz-plugin", "hbm"] 4985 Log: 4986 description: "Names of available logging-drivers, and logging-driver plugins." 4987 type: "array" 4988 items: 4989 type: "string" 4990 example: ["awslogs", "fluentd", "gcplogs", "gelf", "journald", "json-file", "logentries", "splunk", "syslog"] 4991 4992 4993 RegistryServiceConfig: 4994 description: | 4995 RegistryServiceConfig stores daemon registry services configuration. 4996 type: "object" 4997 x-nullable: true 4998 properties: 4999 AllowNondistributableArtifactsCIDRs: 5000 description: | 5001 List of IP ranges to which nondistributable artifacts can be pushed, 5002 using the CIDR syntax [RFC 4632](https://tools.ietf.org/html/4632). 5003 5004 Some images (for example, Windows base images) contain artifacts 5005 whose distribution is restricted by license. When these images are 5006 pushed to a registry, restricted artifacts are not included. 5007 5008 This configuration override this behavior, and enables the daemon to 5009 push nondistributable artifacts to all registries whose resolved IP 5010 address is within the subnet described by the CIDR syntax. 5011 5012 This option is useful when pushing images containing 5013 nondistributable artifacts to a registry on an air-gapped network so 5014 hosts on that network can pull the images without connecting to 5015 another server. 5016 5017 > **Warning**: Nondistributable artifacts typically have restrictions 5018 > on how and where they can be distributed and shared. Only use this 5019 > feature to push artifacts to private registries and ensure that you 5020 > are in compliance with any terms that cover redistributing 5021 > nondistributable artifacts. 5022 5023 type: "array" 5024 items: 5025 type: "string" 5026 example: ["::1/128", "127.0.0.0/8"] 5027 AllowNondistributableArtifactsHostnames: 5028 description: | 5029 List of registry hostnames to which nondistributable artifacts can be 5030 pushed, using the format `<hostname>[:<port>]` or `<IP address>[:<port>]`. 5031 5032 Some images (for example, Windows base images) contain artifacts 5033 whose distribution is restricted by license. When these images are 5034 pushed to a registry, restricted artifacts are not included. 5035 5036 This configuration override this behavior for the specified 5037 registries. 5038 5039 This option is useful when pushing images containing 5040 nondistributable artifacts to a registry on an air-gapped network so 5041 hosts on that network can pull the images without connecting to 5042 another server. 5043 5044 > **Warning**: Nondistributable artifacts typically have restrictions 5045 > on how and where they can be distributed and shared. Only use this 5046 > feature to push artifacts to private registries and ensure that you 5047 > are in compliance with any terms that cover redistributing 5048 > nondistributable artifacts. 5049 type: "array" 5050 items: 5051 type: "string" 5052 example: ["registry.internal.corp.example.com:3000", "[2001:db8:a0b:12f0::1]:443"] 5053 InsecureRegistryCIDRs: 5054 description: | 5055 List of IP ranges of insecure registries, using the CIDR syntax 5056 ([RFC 4632](https://tools.ietf.org/html/4632)). Insecure registries 5057 accept un-encrypted (HTTP) and/or untrusted (HTTPS with certificates 5058 from unknown CAs) communication. 5059 5060 By default, local registries (`127.0.0.0/8`) are configured as 5061 insecure. All other registries are secure. Communicating with an 5062 insecure registry is not possible if the daemon assumes that registry 5063 is secure. 5064 5065 This configuration override this behavior, insecure communication with 5066 registries whose resolved IP address is within the subnet described by 5067 the CIDR syntax. 5068 5069 Registries can also be marked insecure by hostname. Those registries 5070 are listed under `IndexConfigs` and have their `Secure` field set to 5071 `false`. 5072 5073 > **Warning**: Using this option can be useful when running a local 5074 > registry, but introduces security vulnerabilities. This option 5075 > should therefore ONLY be used for testing purposes. For increased 5076 > security, users should add their CA to their system's list of trusted 5077 > CAs instead of enabling this option. 5078 type: "array" 5079 items: 5080 type: "string" 5081 example: ["::1/128", "127.0.0.0/8"] 5082 IndexConfigs: 5083 type: "object" 5084 additionalProperties: 5085 $ref: "#/definitions/IndexInfo" 5086 example: 5087 "127.0.0.1:5000": 5088 "Name": "127.0.0.1:5000" 5089 "Mirrors": [] 5090 "Secure": false 5091 "Official": false 5092 "[2001:db8:a0b:12f0::1]:80": 5093 "Name": "[2001:db8:a0b:12f0::1]:80" 5094 "Mirrors": [] 5095 "Secure": false 5096 "Official": false 5097 "docker.io": 5098 Name: "docker.io" 5099 Mirrors: ["https://hub-mirror.corp.example.com:5000/"] 5100 Secure: true 5101 Official: true 5102 "registry.internal.corp.example.com:3000": 5103 Name: "registry.internal.corp.example.com:3000" 5104 Mirrors: [] 5105 Secure: false 5106 Official: false 5107 Mirrors: 5108 description: | 5109 List of registry URLs that act as a mirror for the official 5110 (`docker.io`) registry. 5111 5112 type: "array" 5113 items: 5114 type: "string" 5115 example: 5116 - "https://hub-mirror.corp.example.com:5000/" 5117 - "https://[2001:db8:a0b:12f0::1]/" 5118 5119 IndexInfo: 5120 description: 5121 IndexInfo contains information about a registry. 5122 type: "object" 5123 x-nullable: true 5124 properties: 5125 Name: 5126 description: | 5127 Name of the registry, such as "docker.io". 5128 type: "string" 5129 example: "docker.io" 5130 Mirrors: 5131 description: | 5132 List of mirrors, expressed as URIs. 5133 type: "array" 5134 items: 5135 type: "string" 5136 example: 5137 - "https://hub-mirror.corp.example.com:5000/" 5138 - "https://registry-2.docker.io/" 5139 - "https://registry-3.docker.io/" 5140 Secure: 5141 description: | 5142 Indicates if the registry is part of the list of insecure 5143 registries. 5144 5145 If `false`, the registry is insecure. Insecure registries accept 5146 un-encrypted (HTTP) and/or untrusted (HTTPS with certificates from 5147 unknown CAs) communication. 5148 5149 > **Warning**: Insecure registries can be useful when running a local 5150 > registry. However, because its use creates security vulnerabilities 5151 > it should ONLY be enabled for testing purposes. For increased 5152 > security, users should add their CA to their system's list of 5153 > trusted CAs instead of enabling this option. 5154 type: "boolean" 5155 example: true 5156 Official: 5157 description: | 5158 Indicates whether this is an official registry (i.e., Docker Hub / docker.io) 5159 type: "boolean" 5160 example: true 5161 5162 Runtime: 5163 description: | 5164 Runtime describes an [OCI compliant](https://github.com/opencontainers/runtime-spec) 5165 runtime. 5166 5167 The runtime is invoked by the daemon via the `containerd` daemon. OCI 5168 runtimes act as an interface to the Linux kernel namespaces, cgroups, 5169 and SELinux. 5170 type: "object" 5171 properties: 5172 path: 5173 description: | 5174 Name and, optional, path, of the OCI executable binary. 5175 5176 If the path is omitted, the daemon searches the host's `$PATH` for the 5177 binary and uses the first result. 5178 type: "string" 5179 example: "/usr/local/bin/my-oci-runtime" 5180 runtimeArgs: 5181 description: | 5182 List of command-line arguments to pass to the runtime when invoked. 5183 type: "array" 5184 x-nullable: true 5185 items: 5186 type: "string" 5187 example: ["--debug", "--systemd-cgroup=false"] 5188 5189 Commit: 5190 description: | 5191 Commit holds the Git-commit (SHA1) that a binary was built from, as 5192 reported in the version-string of external tools, such as `containerd`, 5193 or `runC`. 5194 type: "object" 5195 properties: 5196 ID: 5197 description: "Actual commit ID of external tool." 5198 type: "string" 5199 example: "cfb82a876ecc11b5ca0977d1733adbe58599088a" 5200 Expected: 5201 description: | 5202 Commit ID of external tool expected by dockerd as set at build time. 5203 type: "string" 5204 example: "2d41c047c83e09a6d61d464906feb2a2f3c52aa4" 5205 5206 SwarmInfo: 5207 description: | 5208 Represents generic information about swarm. 5209 type: "object" 5210 properties: 5211 NodeID: 5212 description: "Unique identifier of for this node in the swarm." 5213 type: "string" 5214 default: "" 5215 example: "k67qz4598weg5unwwffg6z1m1" 5216 NodeAddr: 5217 description: | 5218 IP address at which this node can be reached by other nodes in the 5219 swarm. 5220 type: "string" 5221 default: "" 5222 example: "10.0.0.46" 5223 LocalNodeState: 5224 $ref: "#/definitions/LocalNodeState" 5225 ControlAvailable: 5226 type: "boolean" 5227 default: false 5228 example: true 5229 Error: 5230 type: "string" 5231 default: "" 5232 RemoteManagers: 5233 description: | 5234 List of ID's and addresses of other managers in the swarm. 5235 type: "array" 5236 default: null 5237 x-nullable: true 5238 items: 5239 $ref: "#/definitions/PeerNode" 5240 example: 5241 - NodeID: "71izy0goik036k48jg985xnds" 5242 Addr: "10.0.0.158:2377" 5243 - NodeID: "79y6h1o4gv8n120drcprv5nmc" 5244 Addr: "10.0.0.159:2377" 5245 - NodeID: "k67qz4598weg5unwwffg6z1m1" 5246 Addr: "10.0.0.46:2377" 5247 Nodes: 5248 description: "Total number of nodes in the swarm." 5249 type: "integer" 5250 x-nullable: true 5251 example: 4 5252 Managers: 5253 description: "Total number of managers in the swarm." 5254 type: "integer" 5255 x-nullable: true 5256 example: 3 5257 Cluster: 5258 $ref: "#/definitions/ClusterInfo" 5259 5260 LocalNodeState: 5261 description: "Current local status of this node." 5262 type: "string" 5263 default: "" 5264 enum: 5265 - "" 5266 - "inactive" 5267 - "pending" 5268 - "active" 5269 - "error" 5270 - "locked" 5271 example: "active" 5272 5273 PeerNode: 5274 description: "Represents a peer-node in the swarm" 5275 type: "object" 5276 properties: 5277 NodeID: 5278 description: "Unique identifier of for this node in the swarm." 5279 type: "string" 5280 Addr: 5281 description: | 5282 IP address and ports at which this node can be reached. 5283 type: "string" 5284 5285 NetworkAttachmentConfig: 5286 description: | 5287 Specifies how a service should be attached to a particular network. 5288 type: "object" 5289 properties: 5290 Target: 5291 description: | 5292 The target network for attachment. Must be a network name or ID. 5293 type: "string" 5294 Aliases: 5295 description: | 5296 Discoverable alternate names for the service on this network. 5297 type: "array" 5298 items: 5299 type: "string" 5300 DriverOpts: 5301 description: | 5302 Driver attachment options for the network target. 5303 type: "object" 5304 additionalProperties: 5305 type: "string" 5306 5307 paths: 5308 /containers/json: 5309 get: 5310 summary: "List containers" 5311 description: | 5312 Returns a list of containers. For details on the format, see the 5313 [inspect endpoint](#operation/ContainerInspect). 5314 5315 Note that it uses a different, smaller representation of a container 5316 than inspecting a single container. For example, the list of linked 5317 containers is not propagated . 5318 operationId: "ContainerList" 5319 produces: 5320 - "application/json" 5321 parameters: 5322 - name: "all" 5323 in: "query" 5324 description: | 5325 Return all containers. By default, only running containers are shown. 5326 type: "boolean" 5327 default: false 5328 - name: "limit" 5329 in: "query" 5330 description: | 5331 Return this number of most recently created containers, including 5332 non-running ones. 5333 type: "integer" 5334 - name: "size" 5335 in: "query" 5336 description: | 5337 Return the size of container as fields `SizeRw` and `SizeRootFs`. 5338 type: "boolean" 5339 default: false 5340 - name: "filters" 5341 in: "query" 5342 description: | 5343 Filters to process on the container list, encoded as JSON (a 5344 `map[string][]string`). For example, `{"status": ["paused"]}` will 5345 only return paused containers. 5346 5347 Available filters: 5348 5349 - `ancestor`=(`<image-name>[:<tag>]`, `<image id>`, or `<image@digest>`) 5350 - `before`=(`<container id>` or `<container name>`) 5351 - `expose`=(`<port>[/<proto>]`|`<startport-endport>/[<proto>]`) 5352 - `exited=<int>` containers with exit code of `<int>` 5353 - `health`=(`starting`|`healthy`|`unhealthy`|`none`) 5354 - `id=<ID>` a container's ID 5355 - `isolation=`(`default`|`process`|`hyperv`) (Windows daemon only) 5356 - `is-task=`(`true`|`false`) 5357 - `label=key` or `label="key=value"` of a container label 5358 - `name=<name>` a container's name 5359 - `network`=(`<network id>` or `<network name>`) 5360 - `publish`=(`<port>[/<proto>]`|`<startport-endport>/[<proto>]`) 5361 - `since`=(`<container id>` or `<container name>`) 5362 - `status=`(`created`|`restarting`|`running`|`removing`|`paused`|`exited`|`dead`) 5363 - `volume`=(`<volume name>` or `<mount point destination>`) 5364 type: "string" 5365 responses: 5366 200: 5367 description: "no error" 5368 schema: 5369 $ref: "#/definitions/ContainerSummary" 5370 examples: 5371 application/json: 5372 - Id: "8dfafdbc3a40" 5373 Names: 5374 - "/boring_feynman" 5375 Image: "ubuntu:latest" 5376 ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82" 5377 Command: "echo 1" 5378 Created: 1367854155 5379 State: "Exited" 5380 Status: "Exit 0" 5381 Ports: 5382 - PrivatePort: 2222 5383 PublicPort: 3333 5384 Type: "tcp" 5385 Labels: 5386 com.example.vendor: "Acme" 5387 com.example.license: "GPL" 5388 com.example.version: "1.0" 5389 SizeRw: 12288 5390 SizeRootFs: 0 5391 HostConfig: 5392 NetworkMode: "default" 5393 NetworkSettings: 5394 Networks: 5395 bridge: 5396 NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812" 5397 EndpointID: "2cdc4edb1ded3631c81f57966563e5c8525b81121bb3706a9a9a3ae102711f3f" 5398 Gateway: "172.17.0.1" 5399 IPAddress: "172.17.0.2" 5400 IPPrefixLen: 16 5401 IPv6Gateway: "" 5402 GlobalIPv6Address: "" 5403 GlobalIPv6PrefixLen: 0 5404 MacAddress: "02:42:ac:11:00:02" 5405 Mounts: 5406 - Name: "fac362...80535" 5407 Source: "/data" 5408 Destination: "/data" 5409 Driver: "local" 5410 Mode: "ro,Z" 5411 RW: false 5412 Propagation: "" 5413 - Id: "9cd87474be90" 5414 Names: 5415 - "/coolName" 5416 Image: "ubuntu:latest" 5417 ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82" 5418 Command: "echo 222222" 5419 Created: 1367854155 5420 State: "Exited" 5421 Status: "Exit 0" 5422 Ports: [] 5423 Labels: {} 5424 SizeRw: 12288 5425 SizeRootFs: 0 5426 HostConfig: 5427 NetworkMode: "default" 5428 NetworkSettings: 5429 Networks: 5430 bridge: 5431 NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812" 5432 EndpointID: "88eaed7b37b38c2a3f0c4bc796494fdf51b270c2d22656412a2ca5d559a64d7a" 5433 Gateway: "172.17.0.1" 5434 IPAddress: "172.17.0.8" 5435 IPPrefixLen: 16 5436 IPv6Gateway: "" 5437 GlobalIPv6Address: "" 5438 GlobalIPv6PrefixLen: 0 5439 MacAddress: "02:42:ac:11:00:08" 5440 Mounts: [] 5441 - Id: "3176a2479c92" 5442 Names: 5443 - "/sleepy_dog" 5444 Image: "ubuntu:latest" 5445 ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82" 5446 Command: "echo 3333333333333333" 5447 Created: 1367854154 5448 State: "Exited" 5449 Status: "Exit 0" 5450 Ports: [] 5451 Labels: {} 5452 SizeRw: 12288 5453 SizeRootFs: 0 5454 HostConfig: 5455 NetworkMode: "default" 5456 NetworkSettings: 5457 Networks: 5458 bridge: 5459 NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812" 5460 EndpointID: "8b27c041c30326d59cd6e6f510d4f8d1d570a228466f956edf7815508f78e30d" 5461 Gateway: "172.17.0.1" 5462 IPAddress: "172.17.0.6" 5463 IPPrefixLen: 16 5464 IPv6Gateway: "" 5465 GlobalIPv6Address: "" 5466 GlobalIPv6PrefixLen: 0 5467 MacAddress: "02:42:ac:11:00:06" 5468 Mounts: [] 5469 - Id: "4cb07b47f9fb" 5470 Names: 5471 - "/running_cat" 5472 Image: "ubuntu:latest" 5473 ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82" 5474 Command: "echo 444444444444444444444444444444444" 5475 Created: 1367854152 5476 State: "Exited" 5477 Status: "Exit 0" 5478 Ports: [] 5479 Labels: {} 5480 SizeRw: 12288 5481 SizeRootFs: 0 5482 HostConfig: 5483 NetworkMode: "default" 5484 NetworkSettings: 5485 Networks: 5486 bridge: 5487 NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812" 5488 EndpointID: "d91c7b2f0644403d7ef3095985ea0e2370325cd2332ff3a3225c4247328e66e9" 5489 Gateway: "172.17.0.1" 5490 IPAddress: "172.17.0.5" 5491 IPPrefixLen: 16 5492 IPv6Gateway: "" 5493 GlobalIPv6Address: "" 5494 GlobalIPv6PrefixLen: 0 5495 MacAddress: "02:42:ac:11:00:05" 5496 Mounts: [] 5497 400: 5498 description: "bad parameter" 5499 schema: 5500 $ref: "#/definitions/ErrorResponse" 5501 500: 5502 description: "server error" 5503 schema: 5504 $ref: "#/definitions/ErrorResponse" 5505 tags: ["Container"] 5506 /containers/create: 5507 post: 5508 summary: "Create a container" 5509 operationId: "ContainerCreate" 5510 consumes: 5511 - "application/json" 5512 - "application/octet-stream" 5513 produces: 5514 - "application/json" 5515 parameters: 5516 - name: "name" 5517 in: "query" 5518 description: | 5519 Assign the specified name to the container. Must match 5520 `/?[a-zA-Z0-9][a-zA-Z0-9_.-]+`. 5521 type: "string" 5522 pattern: "^/?[a-zA-Z0-9][a-zA-Z0-9_.-]+$" 5523 - name: "body" 5524 in: "body" 5525 description: "Container to create" 5526 schema: 5527 allOf: 5528 - $ref: "#/definitions/ContainerConfig" 5529 - type: "object" 5530 properties: 5531 HostConfig: 5532 $ref: "#/definitions/HostConfig" 5533 NetworkingConfig: 5534 $ref: "#/definitions/NetworkingConfig" 5535 example: 5536 Hostname: "" 5537 Domainname: "" 5538 User: "" 5539 AttachStdin: false 5540 AttachStdout: true 5541 AttachStderr: true 5542 Tty: false 5543 OpenStdin: false 5544 StdinOnce: false 5545 Env: 5546 - "FOO=bar" 5547 - "BAZ=quux" 5548 Cmd: 5549 - "date" 5550 Entrypoint: "" 5551 Image: "ubuntu" 5552 Labels: 5553 com.example.vendor: "Acme" 5554 com.example.license: "GPL" 5555 com.example.version: "1.0" 5556 Volumes: 5557 /volumes/data: {} 5558 WorkingDir: "" 5559 NetworkDisabled: false 5560 MacAddress: "12:34:56:78:9a:bc" 5561 ExposedPorts: 5562 22/tcp: {} 5563 StopSignal: "SIGTERM" 5564 StopTimeout: 10 5565 HostConfig: 5566 Binds: 5567 - "/tmp:/tmp" 5568 Links: 5569 - "redis3:redis" 5570 Memory: 0 5571 MemorySwap: 0 5572 MemoryReservation: 0 5573 KernelMemory: 0 5574 NanoCpus: 500000 5575 CpuPercent: 80 5576 CpuShares: 512 5577 CpuPeriod: 100000 5578 CpuRealtimePeriod: 1000000 5579 CpuRealtimeRuntime: 10000 5580 CpuQuota: 50000 5581 CpusetCpus: "0,1" 5582 CpusetMems: "0,1" 5583 MaximumIOps: 0 5584 MaximumIOBps: 0 5585 BlkioWeight: 300 5586 BlkioWeightDevice: 5587 - {} 5588 BlkioDeviceReadBps: 5589 - {} 5590 BlkioDeviceReadIOps: 5591 - {} 5592 BlkioDeviceWriteBps: 5593 - {} 5594 BlkioDeviceWriteIOps: 5595 - {} 5596 MemorySwappiness: 60 5597 OomKillDisable: false 5598 OomScoreAdj: 500 5599 PidMode: "" 5600 PidsLimit: -1 5601 PortBindings: 5602 22/tcp: 5603 - HostPort: "11022" 5604 PublishAllPorts: false 5605 Privileged: false 5606 ReadonlyRootfs: false 5607 Dns: 5608 - "8.8.8.8" 5609 DnsOptions: 5610 - "" 5611 DnsSearch: 5612 - "" 5613 VolumesFrom: 5614 - "parent" 5615 - "other:ro" 5616 CapAdd: 5617 - "NET_ADMIN" 5618 CapDrop: 5619 - "MKNOD" 5620 GroupAdd: 5621 - "newgroup" 5622 RestartPolicy: 5623 Name: "" 5624 MaximumRetryCount: 0 5625 AutoRemove: true 5626 NetworkMode: "bridge" 5627 Devices: [] 5628 Ulimits: 5629 - {} 5630 LogConfig: 5631 Type: "json-file" 5632 Config: {} 5633 SecurityOpt: [] 5634 StorageOpt: {} 5635 CgroupParent: "" 5636 VolumeDriver: "" 5637 ShmSize: 67108864 5638 NetworkingConfig: 5639 EndpointsConfig: 5640 isolated_nw: 5641 IPAMConfig: 5642 IPv4Address: "172.20.30.33" 5643 IPv6Address: "2001:db8:abcd::3033" 5644 LinkLocalIPs: 5645 - "169.254.34.68" 5646 - "fe80::3468" 5647 Links: 5648 - "container_1" 5649 - "container_2" 5650 Aliases: 5651 - "server_x" 5652 - "server_y" 5653 5654 required: true 5655 responses: 5656 201: 5657 description: "Container created successfully" 5658 schema: 5659 type: "object" 5660 title: "ContainerCreateResponse" 5661 description: "OK response to ContainerCreate operation" 5662 required: [Id, Warnings] 5663 properties: 5664 Id: 5665 description: "The ID of the created container" 5666 type: "string" 5667 x-nullable: false 5668 Warnings: 5669 description: "Warnings encountered when creating the container" 5670 type: "array" 5671 x-nullable: false 5672 items: 5673 type: "string" 5674 examples: 5675 application/json: 5676 Id: "e90e34656806" 5677 Warnings: [] 5678 400: 5679 description: "bad parameter" 5680 schema: 5681 $ref: "#/definitions/ErrorResponse" 5682 404: 5683 description: "no such image" 5684 schema: 5685 $ref: "#/definitions/ErrorResponse" 5686 examples: 5687 application/json: 5688 message: "No such image: c2ada9df5af8" 5689 409: 5690 description: "conflict" 5691 schema: 5692 $ref: "#/definitions/ErrorResponse" 5693 500: 5694 description: "server error" 5695 schema: 5696 $ref: "#/definitions/ErrorResponse" 5697 tags: ["Container"] 5698 /containers/{id}/json: 5699 get: 5700 summary: "Inspect a container" 5701 description: "Return low-level information about a container." 5702 operationId: "ContainerInspect" 5703 produces: 5704 - "application/json" 5705 responses: 5706 200: 5707 description: "no error" 5708 schema: 5709 type: "object" 5710 title: "ContainerInspectResponse" 5711 properties: 5712 Id: 5713 description: "The ID of the container" 5714 type: "string" 5715 Created: 5716 description: "The time the container was created" 5717 type: "string" 5718 Path: 5719 description: "The path to the command being run" 5720 type: "string" 5721 Args: 5722 description: "The arguments to the command being run" 5723 type: "array" 5724 items: 5725 type: "string" 5726 State: 5727 x-nullable: true 5728 $ref: "#/definitions/ContainerState" 5729 Image: 5730 description: "The container's image ID" 5731 type: "string" 5732 ResolvConfPath: 5733 type: "string" 5734 HostnamePath: 5735 type: "string" 5736 HostsPath: 5737 type: "string" 5738 LogPath: 5739 type: "string" 5740 Node: 5741 description: "TODO" 5742 type: "object" 5743 Name: 5744 type: "string" 5745 RestartCount: 5746 type: "integer" 5747 Driver: 5748 type: "string" 5749 MountLabel: 5750 type: "string" 5751 ProcessLabel: 5752 type: "string" 5753 AppArmorProfile: 5754 type: "string" 5755 ExecIDs: 5756 description: "IDs of exec instances that are running in the container." 5757 type: "array" 5758 items: 5759 type: "string" 5760 x-nullable: true 5761 HostConfig: 5762 $ref: "#/definitions/HostConfig" 5763 GraphDriver: 5764 $ref: "#/definitions/GraphDriverData" 5765 SizeRw: 5766 description: | 5767 The size of files that have been created or changed by this 5768 container. 5769 type: "integer" 5770 format: "int64" 5771 SizeRootFs: 5772 description: "The total size of all the files in this container." 5773 type: "integer" 5774 format: "int64" 5775 Mounts: 5776 type: "array" 5777 items: 5778 $ref: "#/definitions/MountPoint" 5779 Config: 5780 $ref: "#/definitions/ContainerConfig" 5781 NetworkSettings: 5782 $ref: "#/definitions/NetworkSettings" 5783 examples: 5784 application/json: 5785 AppArmorProfile: "" 5786 Args: 5787 - "-c" 5788 - "exit 9" 5789 Config: 5790 AttachStderr: true 5791 AttachStdin: false 5792 AttachStdout: true 5793 Cmd: 5794 - "/bin/sh" 5795 - "-c" 5796 - "exit 9" 5797 Domainname: "" 5798 Env: 5799 - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" 5800 Healthcheck: 5801 Test: ["CMD-SHELL", "exit 0"] 5802 Hostname: "ba033ac44011" 5803 Image: "ubuntu" 5804 Labels: 5805 com.example.vendor: "Acme" 5806 com.example.license: "GPL" 5807 com.example.version: "1.0" 5808 MacAddress: "" 5809 NetworkDisabled: false 5810 OpenStdin: false 5811 StdinOnce: false 5812 Tty: false 5813 User: "" 5814 Volumes: 5815 /volumes/data: {} 5816 WorkingDir: "" 5817 StopSignal: "SIGTERM" 5818 StopTimeout: 10 5819 Created: "2015-01-06T15:47:31.485331387Z" 5820 Driver: "devicemapper" 5821 ExecIDs: 5822 - "b35395de42bc8abd327f9dd65d913b9ba28c74d2f0734eeeae84fa1c616a0fca" 5823 - "3fc1232e5cd20c8de182ed81178503dc6437f4e7ef12b52cc5e8de020652f1c4" 5824 HostConfig: 5825 MaximumIOps: 0 5826 MaximumIOBps: 0 5827 BlkioWeight: 0 5828 BlkioWeightDevice: 5829 - {} 5830 BlkioDeviceReadBps: 5831 - {} 5832 BlkioDeviceWriteBps: 5833 - {} 5834 BlkioDeviceReadIOps: 5835 - {} 5836 BlkioDeviceWriteIOps: 5837 - {} 5838 ContainerIDFile: "" 5839 CpusetCpus: "" 5840 CpusetMems: "" 5841 CpuPercent: 80 5842 CpuShares: 0 5843 CpuPeriod: 100000 5844 CpuRealtimePeriod: 1000000 5845 CpuRealtimeRuntime: 10000 5846 Devices: [] 5847 IpcMode: "" 5848 Memory: 0 5849 MemorySwap: 0 5850 MemoryReservation: 0 5851 KernelMemory: 0 5852 OomKillDisable: false 5853 OomScoreAdj: 500 5854 NetworkMode: "bridge" 5855 PidMode: "" 5856 PortBindings: {} 5857 Privileged: false 5858 ReadonlyRootfs: false 5859 PublishAllPorts: false 5860 RestartPolicy: 5861 MaximumRetryCount: 2 5862 Name: "on-failure" 5863 LogConfig: 5864 Type: "json-file" 5865 Sysctls: 5866 net.ipv4.ip_forward: "1" 5867 Ulimits: 5868 - {} 5869 VolumeDriver: "" 5870 ShmSize: 67108864 5871 HostnamePath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/hostname" 5872 HostsPath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/hosts" 5873 LogPath: "/var/lib/docker/containers/1eb5fabf5a03807136561b3c00adcd2992b535d624d5e18b6cdc6a6844d9767b/1eb5fabf5a03807136561b3c00adcd2992b535d624d5e18b6cdc6a6844d9767b-json.log" 5874 Id: "ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39" 5875 Image: "04c5d3b7b0656168630d3ba35d8889bd0e9caafcaeb3004d2bfbc47e7c5d35d2" 5876 MountLabel: "" 5877 Name: "/boring_euclid" 5878 NetworkSettings: 5879 Bridge: "" 5880 SandboxID: "" 5881 HairpinMode: false 5882 LinkLocalIPv6Address: "" 5883 LinkLocalIPv6PrefixLen: 0 5884 SandboxKey: "" 5885 EndpointID: "" 5886 Gateway: "" 5887 GlobalIPv6Address: "" 5888 GlobalIPv6PrefixLen: 0 5889 IPAddress: "" 5890 IPPrefixLen: 0 5891 IPv6Gateway: "" 5892 MacAddress: "" 5893 Networks: 5894 bridge: 5895 NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812" 5896 EndpointID: "7587b82f0dada3656fda26588aee72630c6fab1536d36e394b2bfbcf898c971d" 5897 Gateway: "172.17.0.1" 5898 IPAddress: "172.17.0.2" 5899 IPPrefixLen: 16 5900 IPv6Gateway: "" 5901 GlobalIPv6Address: "" 5902 GlobalIPv6PrefixLen: 0 5903 MacAddress: "02:42:ac:12:00:02" 5904 Path: "/bin/sh" 5905 ProcessLabel: "" 5906 ResolvConfPath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/resolv.conf" 5907 RestartCount: 1 5908 State: 5909 Error: "" 5910 ExitCode: 9 5911 FinishedAt: "2015-01-06T15:47:32.080254511Z" 5912 Health: 5913 Status: "healthy" 5914 FailingStreak: 0 5915 Log: 5916 - Start: "2019-12-22T10:59:05.6385933Z" 5917 End: "2019-12-22T10:59:05.8078452Z" 5918 ExitCode: 0 5919 Output: "" 5920 OOMKilled: false 5921 Dead: false 5922 Paused: false 5923 Pid: 0 5924 Restarting: false 5925 Running: true 5926 StartedAt: "2015-01-06T15:47:32.072697474Z" 5927 Status: "running" 5928 Mounts: 5929 - Name: "fac362...80535" 5930 Source: "/data" 5931 Destination: "/data" 5932 Driver: "local" 5933 Mode: "ro,Z" 5934 RW: false 5935 Propagation: "" 5936 404: 5937 description: "no such container" 5938 schema: 5939 $ref: "#/definitions/ErrorResponse" 5940 examples: 5941 application/json: 5942 message: "No such container: c2ada9df5af8" 5943 500: 5944 description: "server error" 5945 schema: 5946 $ref: "#/definitions/ErrorResponse" 5947 parameters: 5948 - name: "id" 5949 in: "path" 5950 required: true 5951 description: "ID or name of the container" 5952 type: "string" 5953 - name: "size" 5954 in: "query" 5955 type: "boolean" 5956 default: false 5957 description: "Return the size of container as fields `SizeRw` and `SizeRootFs`" 5958 tags: ["Container"] 5959 /containers/{id}/top: 5960 get: 5961 summary: "List processes running inside a container" 5962 description: | 5963 On Unix systems, this is done by running the `ps` command. This endpoint 5964 is not supported on Windows. 5965 operationId: "ContainerTop" 5966 responses: 5967 200: 5968 description: "no error" 5969 schema: 5970 type: "object" 5971 title: "ContainerTopResponse" 5972 description: "OK response to ContainerTop operation" 5973 properties: 5974 Titles: 5975 description: "The ps column titles" 5976 type: "array" 5977 items: 5978 type: "string" 5979 Processes: 5980 description: | 5981 Each process running in the container, where each is process 5982 is an array of values corresponding to the titles. 5983 type: "array" 5984 items: 5985 type: "array" 5986 items: 5987 type: "string" 5988 examples: 5989 application/json: 5990 Titles: 5991 - "UID" 5992 - "PID" 5993 - "PPID" 5994 - "C" 5995 - "STIME" 5996 - "TTY" 5997 - "TIME" 5998 - "CMD" 5999 Processes: 6000 - 6001 - "root" 6002 - "13642" 6003 - "882" 6004 - "0" 6005 - "17:03" 6006 - "pts/0" 6007 - "00:00:00" 6008 - "/bin/bash" 6009 - 6010 - "root" 6011 - "13735" 6012 - "13642" 6013 - "0" 6014 - "17:06" 6015 - "pts/0" 6016 - "00:00:00" 6017 - "sleep 10" 6018 404: 6019 description: "no such container" 6020 schema: 6021 $ref: "#/definitions/ErrorResponse" 6022 examples: 6023 application/json: 6024 message: "No such container: c2ada9df5af8" 6025 500: 6026 description: "server error" 6027 schema: 6028 $ref: "#/definitions/ErrorResponse" 6029 parameters: 6030 - name: "id" 6031 in: "path" 6032 required: true 6033 description: "ID or name of the container" 6034 type: "string" 6035 - name: "ps_args" 6036 in: "query" 6037 description: "The arguments to pass to `ps`. For example, `aux`" 6038 type: "string" 6039 default: "-ef" 6040 tags: ["Container"] 6041 /containers/{id}/logs: 6042 get: 6043 summary: "Get container logs" 6044 description: | 6045 Get `stdout` and `stderr` logs from a container. 6046 6047 Note: This endpoint works only for containers with the `json-file` or 6048 `journald` logging driver. 6049 operationId: "ContainerLogs" 6050 responses: 6051 101: 6052 description: "logs returned as a stream" 6053 schema: 6054 type: "string" 6055 format: "binary" 6056 200: 6057 description: "logs returned as a string in response body" 6058 schema: 6059 type: "string" 6060 404: 6061 description: "no such container" 6062 schema: 6063 $ref: "#/definitions/ErrorResponse" 6064 examples: 6065 application/json: 6066 message: "No such container: c2ada9df5af8" 6067 500: 6068 description: "server error" 6069 schema: 6070 $ref: "#/definitions/ErrorResponse" 6071 parameters: 6072 - name: "id" 6073 in: "path" 6074 required: true 6075 description: "ID or name of the container" 6076 type: "string" 6077 - name: "follow" 6078 in: "query" 6079 description: | 6080 Return the logs as a stream. 6081 6082 This will return a `101` HTTP response with a `Connection: upgrade` header, then hijack the HTTP connection to send raw output. For more information about hijacking and the stream format, [see the documentation for the attach endpoint](#operation/ContainerAttach). 6083 type: "boolean" 6084 default: false 6085 - name: "stdout" 6086 in: "query" 6087 description: "Return logs from `stdout`" 6088 type: "boolean" 6089 default: false 6090 - name: "stderr" 6091 in: "query" 6092 description: "Return logs from `stderr`" 6093 type: "boolean" 6094 default: false 6095 - name: "since" 6096 in: "query" 6097 description: "Only return logs since this time, as a UNIX timestamp" 6098 type: "integer" 6099 default: 0 6100 - name: "until" 6101 in: "query" 6102 description: "Only return logs before this time, as a UNIX timestamp" 6103 type: "integer" 6104 default: 0 6105 - name: "timestamps" 6106 in: "query" 6107 description: "Add timestamps to every log line" 6108 type: "boolean" 6109 default: false 6110 - name: "tail" 6111 in: "query" 6112 description: | 6113 Only return this number of log lines from the end of the logs. 6114 Specify as an integer or `all` to output all log lines. 6115 type: "string" 6116 default: "all" 6117 tags: ["Container"] 6118 /containers/{id}/changes: 6119 get: 6120 summary: "Get changes on a container’s filesystem" 6121 description: | 6122 Returns which files in a container's filesystem have been added, deleted, 6123 or modified. The `Kind` of modification can be one of: 6124 6125 - `0`: Modified 6126 - `1`: Added 6127 - `2`: Deleted 6128 operationId: "ContainerChanges" 6129 produces: ["application/json"] 6130 responses: 6131 200: 6132 description: "The list of changes" 6133 schema: 6134 type: "array" 6135 items: 6136 type: "object" 6137 x-go-name: "ContainerChangeResponseItem" 6138 title: "ContainerChangeResponseItem" 6139 description: "change item in response to ContainerChanges operation" 6140 required: [Path, Kind] 6141 properties: 6142 Path: 6143 description: "Path to file that has changed" 6144 type: "string" 6145 x-nullable: false 6146 Kind: 6147 description: "Kind of change" 6148 type: "integer" 6149 format: "uint8" 6150 enum: [0, 1, 2] 6151 x-nullable: false 6152 examples: 6153 application/json: 6154 - Path: "/dev" 6155 Kind: 0 6156 - Path: "/dev/kmsg" 6157 Kind: 1 6158 - Path: "/test" 6159 Kind: 1 6160 404: 6161 description: "no such container" 6162 schema: 6163 $ref: "#/definitions/ErrorResponse" 6164 examples: 6165 application/json: 6166 message: "No such container: c2ada9df5af8" 6167 500: 6168 description: "server error" 6169 schema: 6170 $ref: "#/definitions/ErrorResponse" 6171 parameters: 6172 - name: "id" 6173 in: "path" 6174 required: true 6175 description: "ID or name of the container" 6176 type: "string" 6177 tags: ["Container"] 6178 /containers/{id}/export: 6179 get: 6180 summary: "Export a container" 6181 description: "Export the contents of a container as a tarball." 6182 operationId: "ContainerExport" 6183 produces: 6184 - "application/octet-stream" 6185 responses: 6186 200: 6187 description: "no error" 6188 404: 6189 description: "no such container" 6190 schema: 6191 $ref: "#/definitions/ErrorResponse" 6192 examples: 6193 application/json: 6194 message: "No such container: c2ada9df5af8" 6195 500: 6196 description: "server error" 6197 schema: 6198 $ref: "#/definitions/ErrorResponse" 6199 parameters: 6200 - name: "id" 6201 in: "path" 6202 required: true 6203 description: "ID or name of the container" 6204 type: "string" 6205 tags: ["Container"] 6206 /containers/{id}/stats: 6207 get: 6208 summary: "Get container stats based on resource usage" 6209 description: | 6210 This endpoint returns a live stream of a container’s resource usage 6211 statistics. 6212 6213 The `precpu_stats` is the CPU statistic of the *previous* read, and is 6214 used to calculate the CPU usage percentage. It is not an exact copy 6215 of the `cpu_stats` field. 6216 6217 If either `precpu_stats.online_cpus` or `cpu_stats.online_cpus` is 6218 nil then for compatibility with older daemons the length of the 6219 corresponding `cpu_usage.percpu_usage` array should be used. 6220 6221 To calculate the values shown by the `stats` command of the docker cli tool 6222 the following formulas can be used: 6223 * used_memory = `memory_stats.usage - memory_stats.stats.cache` 6224 * available_memory = `memory_stats.limit` 6225 * Memory usage % = `(used_memory / available_memory) * 100.0` 6226 * cpu_delta = `cpu_stats.cpu_usage.total_usage - precpu_stats.cpu_usage.total_usage` 6227 * system_cpu_delta = `cpu_stats.system_cpu_usage - precpu_stats.system_cpu_usage` 6228 * number_cpus = `lenght(cpu_stats.cpu_usage.percpu_usage)` or `cpu_stats.online_cpus` 6229 * CPU usage % = `(cpu_delta / system_cpu_delta) * number_cpus * 100.0` 6230 operationId: "ContainerStats" 6231 produces: ["application/json"] 6232 responses: 6233 200: 6234 description: "no error" 6235 schema: 6236 type: "object" 6237 examples: 6238 application/json: 6239 read: "2015-01-08T22:57:31.547920715Z" 6240 pids_stats: 6241 current: 3 6242 networks: 6243 eth0: 6244 rx_bytes: 5338 6245 rx_dropped: 0 6246 rx_errors: 0 6247 rx_packets: 36 6248 tx_bytes: 648 6249 tx_dropped: 0 6250 tx_errors: 0 6251 tx_packets: 8 6252 eth5: 6253 rx_bytes: 4641 6254 rx_dropped: 0 6255 rx_errors: 0 6256 rx_packets: 26 6257 tx_bytes: 690 6258 tx_dropped: 0 6259 tx_errors: 0 6260 tx_packets: 9 6261 memory_stats: 6262 stats: 6263 total_pgmajfault: 0 6264 cache: 0 6265 mapped_file: 0 6266 total_inactive_file: 0 6267 pgpgout: 414 6268 rss: 6537216 6269 total_mapped_file: 0 6270 writeback: 0 6271 unevictable: 0 6272 pgpgin: 477 6273 total_unevictable: 0 6274 pgmajfault: 0 6275 total_rss: 6537216 6276 total_rss_huge: 6291456 6277 total_writeback: 0 6278 total_inactive_anon: 0 6279 rss_huge: 6291456 6280 hierarchical_memory_limit: 67108864 6281 total_pgfault: 964 6282 total_active_file: 0 6283 active_anon: 6537216 6284 total_active_anon: 6537216 6285 total_pgpgout: 414 6286 total_cache: 0 6287 inactive_anon: 0 6288 active_file: 0 6289 pgfault: 964 6290 inactive_file: 0 6291 total_pgpgin: 477 6292 max_usage: 6651904 6293 usage: 6537216 6294 failcnt: 0 6295 limit: 67108864 6296 blkio_stats: {} 6297 cpu_stats: 6298 cpu_usage: 6299 percpu_usage: 6300 - 8646879 6301 - 24472255 6302 - 36438778 6303 - 30657443 6304 usage_in_usermode: 50000000 6305 total_usage: 100215355 6306 usage_in_kernelmode: 30000000 6307 system_cpu_usage: 739306590000000 6308 online_cpus: 4 6309 throttling_data: 6310 periods: 0 6311 throttled_periods: 0 6312 throttled_time: 0 6313 precpu_stats: 6314 cpu_usage: 6315 percpu_usage: 6316 - 8646879 6317 - 24350896 6318 - 36438778 6319 - 30657443 6320 usage_in_usermode: 50000000 6321 total_usage: 100093996 6322 usage_in_kernelmode: 30000000 6323 system_cpu_usage: 9492140000000 6324 online_cpus: 4 6325 throttling_data: 6326 periods: 0 6327 throttled_periods: 0 6328 throttled_time: 0 6329 404: 6330 description: "no such container" 6331 schema: 6332 $ref: "#/definitions/ErrorResponse" 6333 examples: 6334 application/json: 6335 message: "No such container: c2ada9df5af8" 6336 500: 6337 description: "server error" 6338 schema: 6339 $ref: "#/definitions/ErrorResponse" 6340 parameters: 6341 - name: "id" 6342 in: "path" 6343 required: true 6344 description: "ID or name of the container" 6345 type: "string" 6346 - name: "stream" 6347 in: "query" 6348 description: | 6349 Stream the output. If false, the stats will be output once and then 6350 it will disconnect. 6351 type: "boolean" 6352 default: true 6353 tags: ["Container"] 6354 /containers/{id}/resize: 6355 post: 6356 summary: "Resize a container TTY" 6357 description: "Resize the TTY for a container." 6358 operationId: "ContainerResize" 6359 consumes: 6360 - "application/octet-stream" 6361 produces: 6362 - "text/plain" 6363 responses: 6364 200: 6365 description: "no error" 6366 404: 6367 description: "no such container" 6368 schema: 6369 $ref: "#/definitions/ErrorResponse" 6370 examples: 6371 application/json: 6372 message: "No such container: c2ada9df5af8" 6373 500: 6374 description: "cannot resize container" 6375 schema: 6376 $ref: "#/definitions/ErrorResponse" 6377 parameters: 6378 - name: "id" 6379 in: "path" 6380 required: true 6381 description: "ID or name of the container" 6382 type: "string" 6383 - name: "h" 6384 in: "query" 6385 description: "Height of the TTY session in characters" 6386 type: "integer" 6387 - name: "w" 6388 in: "query" 6389 description: "Width of the TTY session in characters" 6390 type: "integer" 6391 tags: ["Container"] 6392 /containers/{id}/start: 6393 post: 6394 summary: "Start a container" 6395 operationId: "ContainerStart" 6396 responses: 6397 204: 6398 description: "no error" 6399 304: 6400 description: "container already started" 6401 404: 6402 description: "no such container" 6403 schema: 6404 $ref: "#/definitions/ErrorResponse" 6405 examples: 6406 application/json: 6407 message: "No such container: c2ada9df5af8" 6408 500: 6409 description: "server error" 6410 schema: 6411 $ref: "#/definitions/ErrorResponse" 6412 parameters: 6413 - name: "id" 6414 in: "path" 6415 required: true 6416 description: "ID or name of the container" 6417 type: "string" 6418 - name: "detachKeys" 6419 in: "query" 6420 description: | 6421 Override the key sequence for detaching a container. Format is a 6422 single character `[a-Z]` or `ctrl-<value>` where `<value>` is one 6423 of: `a-z`, `@`, `^`, `[`, `,` or `_`. 6424 type: "string" 6425 tags: ["Container"] 6426 /containers/{id}/stop: 6427 post: 6428 summary: "Stop a container" 6429 operationId: "ContainerStop" 6430 responses: 6431 204: 6432 description: "no error" 6433 304: 6434 description: "container already stopped" 6435 404: 6436 description: "no such container" 6437 schema: 6438 $ref: "#/definitions/ErrorResponse" 6439 examples: 6440 application/json: 6441 message: "No such container: c2ada9df5af8" 6442 500: 6443 description: "server error" 6444 schema: 6445 $ref: "#/definitions/ErrorResponse" 6446 parameters: 6447 - name: "id" 6448 in: "path" 6449 required: true 6450 description: "ID or name of the container" 6451 type: "string" 6452 - name: "t" 6453 in: "query" 6454 description: "Number of seconds to wait before killing the container" 6455 type: "integer" 6456 tags: ["Container"] 6457 /containers/{id}/restart: 6458 post: 6459 summary: "Restart a container" 6460 operationId: "ContainerRestart" 6461 responses: 6462 204: 6463 description: "no error" 6464 404: 6465 description: "no such container" 6466 schema: 6467 $ref: "#/definitions/ErrorResponse" 6468 examples: 6469 application/json: 6470 message: "No such container: c2ada9df5af8" 6471 500: 6472 description: "server error" 6473 schema: 6474 $ref: "#/definitions/ErrorResponse" 6475 parameters: 6476 - name: "id" 6477 in: "path" 6478 required: true 6479 description: "ID or name of the container" 6480 type: "string" 6481 - name: "t" 6482 in: "query" 6483 description: "Number of seconds to wait before killing the container" 6484 type: "integer" 6485 tags: ["Container"] 6486 /containers/{id}/kill: 6487 post: 6488 summary: "Kill a container" 6489 description: | 6490 Send a POSIX signal to a container, defaulting to killing to the 6491 container. 6492 operationId: "ContainerKill" 6493 responses: 6494 204: 6495 description: "no error" 6496 404: 6497 description: "no such container" 6498 schema: 6499 $ref: "#/definitions/ErrorResponse" 6500 examples: 6501 application/json: 6502 message: "No such container: c2ada9df5af8" 6503 409: 6504 description: "container is not running" 6505 schema: 6506 $ref: "#/definitions/ErrorResponse" 6507 examples: 6508 application/json: 6509 message: "Container d37cde0fe4ad63c3a7252023b2f9800282894247d145cb5933ddf6e52cc03a28 is not running" 6510 500: 6511 description: "server error" 6512 schema: 6513 $ref: "#/definitions/ErrorResponse" 6514 parameters: 6515 - name: "id" 6516 in: "path" 6517 required: true 6518 description: "ID or name of the container" 6519 type: "string" 6520 - name: "signal" 6521 in: "query" 6522 description: "Signal to send to the container as an integer or string (e.g. `SIGINT`)" 6523 type: "string" 6524 default: "SIGKILL" 6525 tags: ["Container"] 6526 /containers/{id}/update: 6527 post: 6528 summary: "Update a container" 6529 description: | 6530 Change various configuration options of a container without having to 6531 recreate it. 6532 operationId: "ContainerUpdate" 6533 consumes: ["application/json"] 6534 produces: ["application/json"] 6535 responses: 6536 200: 6537 description: "The container has been updated." 6538 schema: 6539 type: "object" 6540 title: "ContainerUpdateResponse" 6541 description: "OK response to ContainerUpdate operation" 6542 properties: 6543 Warnings: 6544 type: "array" 6545 items: 6546 type: "string" 6547 404: 6548 description: "no such container" 6549 schema: 6550 $ref: "#/definitions/ErrorResponse" 6551 examples: 6552 application/json: 6553 message: "No such container: c2ada9df5af8" 6554 500: 6555 description: "server error" 6556 schema: 6557 $ref: "#/definitions/ErrorResponse" 6558 parameters: 6559 - name: "id" 6560 in: "path" 6561 required: true 6562 description: "ID or name of the container" 6563 type: "string" 6564 - name: "update" 6565 in: "body" 6566 required: true 6567 schema: 6568 allOf: 6569 - $ref: "#/definitions/Resources" 6570 - type: "object" 6571 properties: 6572 RestartPolicy: 6573 $ref: "#/definitions/RestartPolicy" 6574 example: 6575 BlkioWeight: 300 6576 CpuShares: 512 6577 CpuPeriod: 100000 6578 CpuQuota: 50000 6579 CpuRealtimePeriod: 1000000 6580 CpuRealtimeRuntime: 10000 6581 CpusetCpus: "0,1" 6582 CpusetMems: "0" 6583 Memory: 314572800 6584 MemorySwap: 514288000 6585 MemoryReservation: 209715200 6586 KernelMemory: 52428800 6587 RestartPolicy: 6588 MaximumRetryCount: 4 6589 Name: "on-failure" 6590 tags: ["Container"] 6591 /containers/{id}/rename: 6592 post: 6593 summary: "Rename a container" 6594 operationId: "ContainerRename" 6595 responses: 6596 204: 6597 description: "no error" 6598 404: 6599 description: "no such container" 6600 schema: 6601 $ref: "#/definitions/ErrorResponse" 6602 examples: 6603 application/json: 6604 message: "No such container: c2ada9df5af8" 6605 409: 6606 description: "name already in use" 6607 schema: 6608 $ref: "#/definitions/ErrorResponse" 6609 500: 6610 description: "server error" 6611 schema: 6612 $ref: "#/definitions/ErrorResponse" 6613 parameters: 6614 - name: "id" 6615 in: "path" 6616 required: true 6617 description: "ID or name of the container" 6618 type: "string" 6619 - name: "name" 6620 in: "query" 6621 required: true 6622 description: "New name for the container" 6623 type: "string" 6624 tags: ["Container"] 6625 /containers/{id}/pause: 6626 post: 6627 summary: "Pause a container" 6628 description: | 6629 Use the freezer cgroup to suspend all processes in a container. 6630 6631 Traditionally, when suspending a process the `SIGSTOP` signal is used, 6632 which is observable by the process being suspended. With the freezer 6633 cgroup the process is unaware, and unable to capture, that it is being 6634 suspended, and subsequently resumed. 6635 operationId: "ContainerPause" 6636 responses: 6637 204: 6638 description: "no error" 6639 404: 6640 description: "no such container" 6641 schema: 6642 $ref: "#/definitions/ErrorResponse" 6643 examples: 6644 application/json: 6645 message: "No such container: c2ada9df5af8" 6646 500: 6647 description: "server error" 6648 schema: 6649 $ref: "#/definitions/ErrorResponse" 6650 parameters: 6651 - name: "id" 6652 in: "path" 6653 required: true 6654 description: "ID or name of the container" 6655 type: "string" 6656 tags: ["Container"] 6657 /containers/{id}/unpause: 6658 post: 6659 summary: "Unpause a container" 6660 description: "Resume a container which has been paused." 6661 operationId: "ContainerUnpause" 6662 responses: 6663 204: 6664 description: "no error" 6665 404: 6666 description: "no such container" 6667 schema: 6668 $ref: "#/definitions/ErrorResponse" 6669 examples: 6670 application/json: 6671 message: "No such container: c2ada9df5af8" 6672 500: 6673 description: "server error" 6674 schema: 6675 $ref: "#/definitions/ErrorResponse" 6676 parameters: 6677 - name: "id" 6678 in: "path" 6679 required: true 6680 description: "ID or name of the container" 6681 type: "string" 6682 tags: ["Container"] 6683 /containers/{id}/attach: 6684 post: 6685 summary: "Attach to a container" 6686 description: | 6687 Attach to a container to read its output or send it input. You can attach 6688 to the same container multiple times and you can reattach to containers 6689 that have been detached. 6690 6691 Either the `stream` or `logs` parameter must be `true` for this endpoint 6692 to do anything. 6693 6694 See the [documentation for the `docker attach` command](https://docs.docker.com/engine/reference/commandline/attach/) 6695 for more details. 6696 6697 ### Hijacking 6698 6699 This endpoint hijacks the HTTP connection to transport `stdin`, `stdout`, 6700 and `stderr` on the same socket. 6701 6702 This is the response from the daemon for an attach request: 6703 6704 ``` 6705 HTTP/1.1 200 OK 6706 Content-Type: application/vnd.docker.raw-stream 6707 6708 [STREAM] 6709 ``` 6710 6711 After the headers and two new lines, the TCP connection can now be used 6712 for raw, bidirectional communication between the client and server. 6713 6714 To hint potential proxies about connection hijacking, the Docker client 6715 can also optionally send connection upgrade headers. 6716 6717 For example, the client sends this request to upgrade the connection: 6718 6719 ``` 6720 POST /containers/16253994b7c4/attach?stream=1&stdout=1 HTTP/1.1 6721 Upgrade: tcp 6722 Connection: Upgrade 6723 ``` 6724 6725 The Docker daemon will respond with a `101 UPGRADED` response, and will 6726 similarly follow with the raw stream: 6727 6728 ``` 6729 HTTP/1.1 101 UPGRADED 6730 Content-Type: application/vnd.docker.raw-stream 6731 Connection: Upgrade 6732 Upgrade: tcp 6733 6734 [STREAM] 6735 ``` 6736 6737 ### Stream format 6738 6739 When the TTY setting is disabled in [`POST /containers/create`](#operation/ContainerCreate), 6740 the stream over the hijacked connected is multiplexed to separate out 6741 `stdout` and `stderr`. The stream consists of a series of frames, each 6742 containing a header and a payload. 6743 6744 The header contains the information which the stream writes (`stdout` or 6745 `stderr`). It also contains the size of the associated frame encoded in 6746 the last four bytes (`uint32`). 6747 6748 It is encoded on the first eight bytes like this: 6749 6750 ```go 6751 header := [8]byte{STREAM_TYPE, 0, 0, 0, SIZE1, SIZE2, SIZE3, SIZE4} 6752 ``` 6753 6754 `STREAM_TYPE` can be: 6755 6756 - 0: `stdin` (is written on `stdout`) 6757 - 1: `stdout` 6758 - 2: `stderr` 6759 6760 `SIZE1, SIZE2, SIZE3, SIZE4` are the four bytes of the `uint32` size 6761 encoded as big endian. 6762 6763 Following the header is the payload, which is the specified number of 6764 bytes of `STREAM_TYPE`. 6765 6766 The simplest way to implement this protocol is the following: 6767 6768 1. Read 8 bytes. 6769 2. Choose `stdout` or `stderr` depending on the first byte. 6770 3. Extract the frame size from the last four bytes. 6771 4. Read the extracted size and output it on the correct output. 6772 5. Goto 1. 6773 6774 ### Stream format when using a TTY 6775 6776 When the TTY setting is enabled in [`POST /containers/create`](#operation/ContainerCreate), 6777 the stream is not multiplexed. The data exchanged over the hijacked 6778 connection is simply the raw data from the process PTY and client's 6779 `stdin`. 6780 6781 operationId: "ContainerAttach" 6782 produces: 6783 - "application/vnd.docker.raw-stream" 6784 responses: 6785 101: 6786 description: "no error, hints proxy about hijacking" 6787 200: 6788 description: "no error, no upgrade header found" 6789 400: 6790 description: "bad parameter" 6791 schema: 6792 $ref: "#/definitions/ErrorResponse" 6793 404: 6794 description: "no such container" 6795 schema: 6796 $ref: "#/definitions/ErrorResponse" 6797 examples: 6798 application/json: 6799 message: "No such container: c2ada9df5af8" 6800 500: 6801 description: "server error" 6802 schema: 6803 $ref: "#/definitions/ErrorResponse" 6804 parameters: 6805 - name: "id" 6806 in: "path" 6807 required: true 6808 description: "ID or name of the container" 6809 type: "string" 6810 - name: "detachKeys" 6811 in: "query" 6812 description: | 6813 Override the key sequence for detaching a container.Format is a single 6814 character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`, 6815 `@`, `^`, `[`, `,` or `_`. 6816 type: "string" 6817 - name: "logs" 6818 in: "query" 6819 description: | 6820 Replay previous logs from the container. 6821 6822 This is useful for attaching to a container that has started and you 6823 want to output everything since the container started. 6824 6825 If `stream` is also enabled, once all the previous output has been 6826 returned, it will seamlessly transition into streaming current 6827 output. 6828 type: "boolean" 6829 default: false 6830 - name: "stream" 6831 in: "query" 6832 description: | 6833 Stream attached streams from the time the request was made onwards. 6834 type: "boolean" 6835 default: false 6836 - name: "stdin" 6837 in: "query" 6838 description: "Attach to `stdin`" 6839 type: "boolean" 6840 default: false 6841 - name: "stdout" 6842 in: "query" 6843 description: "Attach to `stdout`" 6844 type: "boolean" 6845 default: false 6846 - name: "stderr" 6847 in: "query" 6848 description: "Attach to `stderr`" 6849 type: "boolean" 6850 default: false 6851 tags: ["Container"] 6852 /containers/{id}/attach/ws: 6853 get: 6854 summary: "Attach to a container via a websocket" 6855 operationId: "ContainerAttachWebsocket" 6856 responses: 6857 101: 6858 description: "no error, hints proxy about hijacking" 6859 200: 6860 description: "no error, no upgrade header found" 6861 400: 6862 description: "bad parameter" 6863 schema: 6864 $ref: "#/definitions/ErrorResponse" 6865 404: 6866 description: "no such container" 6867 schema: 6868 $ref: "#/definitions/ErrorResponse" 6869 examples: 6870 application/json: 6871 message: "No such container: c2ada9df5af8" 6872 500: 6873 description: "server error" 6874 schema: 6875 $ref: "#/definitions/ErrorResponse" 6876 parameters: 6877 - name: "id" 6878 in: "path" 6879 required: true 6880 description: "ID or name of the container" 6881 type: "string" 6882 - name: "detachKeys" 6883 in: "query" 6884 description: | 6885 Override the key sequence for detaching a container.Format is a single 6886 character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`, 6887 `@`, `^`, `[`, `,`, or `_`. 6888 type: "string" 6889 - name: "logs" 6890 in: "query" 6891 description: "Return logs" 6892 type: "boolean" 6893 default: false 6894 - name: "stream" 6895 in: "query" 6896 description: "Return stream" 6897 type: "boolean" 6898 default: false 6899 tags: ["Container"] 6900 /containers/{id}/wait: 6901 post: 6902 summary: "Wait for a container" 6903 description: "Block until a container stops, then returns the exit code." 6904 operationId: "ContainerWait" 6905 produces: ["application/json"] 6906 responses: 6907 200: 6908 description: "The container has exit." 6909 schema: 6910 $ref: "#/definitions/ContainerWaitResponse" 6911 400: 6912 description: "bad parameter" 6913 schema: 6914 $ref: "#/definitions/ErrorResponse" 6915 404: 6916 description: "no such container" 6917 schema: 6918 $ref: "#/definitions/ErrorResponse" 6919 examples: 6920 application/json: 6921 message: "No such container: c2ada9df5af8" 6922 500: 6923 description: "server error" 6924 schema: 6925 $ref: "#/definitions/ErrorResponse" 6926 parameters: 6927 - name: "id" 6928 in: "path" 6929 required: true 6930 description: "ID or name of the container" 6931 type: "string" 6932 - name: "condition" 6933 in: "query" 6934 description: | 6935 Wait until a container state reaches the given condition. 6936 6937 Defaults to `not-running` if omitted or empty. 6938 type: "string" 6939 enum: 6940 - "not-running" 6941 - "next-exit" 6942 - "removed" 6943 default: "not-running" 6944 tags: ["Container"] 6945 /containers/{id}: 6946 delete: 6947 summary: "Remove a container" 6948 operationId: "ContainerDelete" 6949 responses: 6950 204: 6951 description: "no error" 6952 400: 6953 description: "bad parameter" 6954 schema: 6955 $ref: "#/definitions/ErrorResponse" 6956 404: 6957 description: "no such container" 6958 schema: 6959 $ref: "#/definitions/ErrorResponse" 6960 examples: 6961 application/json: 6962 message: "No such container: c2ada9df5af8" 6963 409: 6964 description: "conflict" 6965 schema: 6966 $ref: "#/definitions/ErrorResponse" 6967 examples: 6968 application/json: 6969 message: | 6970 You cannot remove a running container: c2ada9df5af8. Stop the 6971 container before attempting removal or force remove 6972 500: 6973 description: "server error" 6974 schema: 6975 $ref: "#/definitions/ErrorResponse" 6976 parameters: 6977 - name: "id" 6978 in: "path" 6979 required: true 6980 description: "ID or name of the container" 6981 type: "string" 6982 - name: "v" 6983 in: "query" 6984 description: "Remove anonymous volumes associated with the container." 6985 type: "boolean" 6986 default: false 6987 - name: "force" 6988 in: "query" 6989 description: "If the container is running, kill it before removing it." 6990 type: "boolean" 6991 default: false 6992 - name: "link" 6993 in: "query" 6994 description: "Remove the specified link associated with the container." 6995 type: "boolean" 6996 default: false 6997 tags: ["Container"] 6998 /containers/{id}/archive: 6999 head: 7000 summary: "Get information about files in a container" 7001 description: | 7002 A response header `X-Docker-Container-Path-Stat` is returned, containing 7003 a base64 - encoded JSON object with some filesystem header information 7004 about the path. 7005 operationId: "ContainerArchiveInfo" 7006 responses: 7007 200: 7008 description: "no error" 7009 headers: 7010 X-Docker-Container-Path-Stat: 7011 type: "string" 7012 description: | 7013 A base64 - encoded JSON object with some filesystem header 7014 information about the path 7015 400: 7016 description: "Bad parameter" 7017 schema: 7018 $ref: "#/definitions/ErrorResponse" 7019 404: 7020 description: "Container or path does not exist" 7021 schema: 7022 $ref: "#/definitions/ErrorResponse" 7023 examples: 7024 application/json: 7025 message: "No such container: c2ada9df5af8" 7026 500: 7027 description: "Server error" 7028 schema: 7029 $ref: "#/definitions/ErrorResponse" 7030 parameters: 7031 - name: "id" 7032 in: "path" 7033 required: true 7034 description: "ID or name of the container" 7035 type: "string" 7036 - name: "path" 7037 in: "query" 7038 required: true 7039 description: "Resource in the container’s filesystem to archive." 7040 type: "string" 7041 tags: ["Container"] 7042 get: 7043 summary: "Get an archive of a filesystem resource in a container" 7044 description: "Get a tar archive of a resource in the filesystem of container id." 7045 operationId: "ContainerArchive" 7046 produces: ["application/x-tar"] 7047 responses: 7048 200: 7049 description: "no error" 7050 400: 7051 description: "Bad parameter" 7052 schema: 7053 $ref: "#/definitions/ErrorResponse" 7054 404: 7055 description: "Container or path does not exist" 7056 schema: 7057 $ref: "#/definitions/ErrorResponse" 7058 examples: 7059 application/json: 7060 message: "No such container: c2ada9df5af8" 7061 500: 7062 description: "server error" 7063 schema: 7064 $ref: "#/definitions/ErrorResponse" 7065 parameters: 7066 - name: "id" 7067 in: "path" 7068 required: true 7069 description: "ID or name of the container" 7070 type: "string" 7071 - name: "path" 7072 in: "query" 7073 required: true 7074 description: "Resource in the container’s filesystem to archive." 7075 type: "string" 7076 tags: ["Container"] 7077 put: 7078 summary: "Extract an archive of files or folders to a directory in a container" 7079 description: | 7080 Upload a tar archive to be extracted to a path in the filesystem of container id. 7081 `path` parameter is asserted to be a directory. If it exists as a file, 400 error 7082 will be returned with message "not a directory". 7083 operationId: "PutContainerArchive" 7084 consumes: ["application/x-tar", "application/octet-stream"] 7085 responses: 7086 200: 7087 description: "The content was extracted successfully" 7088 400: 7089 description: "Bad parameter" 7090 schema: 7091 $ref: "#/definitions/ErrorResponse" 7092 examples: 7093 application/json: 7094 message: "not a directory" 7095 403: 7096 description: "Permission denied, the volume or container rootfs is marked as read-only." 7097 schema: 7098 $ref: "#/definitions/ErrorResponse" 7099 404: 7100 description: "No such container or path does not exist inside the container" 7101 schema: 7102 $ref: "#/definitions/ErrorResponse" 7103 examples: 7104 application/json: 7105 message: "No such container: c2ada9df5af8" 7106 500: 7107 description: "Server error" 7108 schema: 7109 $ref: "#/definitions/ErrorResponse" 7110 parameters: 7111 - name: "id" 7112 in: "path" 7113 required: true 7114 description: "ID or name of the container" 7115 type: "string" 7116 - name: "path" 7117 in: "query" 7118 required: true 7119 description: "Path to a directory in the container to extract the archive’s contents into. " 7120 type: "string" 7121 - name: "noOverwriteDirNonDir" 7122 in: "query" 7123 description: | 7124 If `1`, `true`, or `True` then it will be an error if unpacking the 7125 given content would cause an existing directory to be replaced with 7126 a non-directory and vice versa. 7127 type: "string" 7128 - name: "copyUIDGID" 7129 in: "query" 7130 description: | 7131 If `1`, `true`, then it will copy UID/GID maps to the dest file or 7132 dir 7133 type: "string" 7134 - name: "inputStream" 7135 in: "body" 7136 required: true 7137 description: | 7138 The input stream must be a tar archive compressed with one of the 7139 following algorithms: `identity` (no compression), `gzip`, `bzip2`, 7140 or `xz`. 7141 schema: 7142 type: "string" 7143 format: "binary" 7144 tags: ["Container"] 7145 /containers/prune: 7146 post: 7147 summary: "Delete stopped containers" 7148 produces: 7149 - "application/json" 7150 operationId: "ContainerPrune" 7151 parameters: 7152 - name: "filters" 7153 in: "query" 7154 description: | 7155 Filters to process on the prune list, encoded as JSON (a `map[string][]string`). 7156 7157 Available filters: 7158 - `until=<timestamp>` Prune containers created before this timestamp. The `<timestamp>` can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed relative to the daemon machine’s time. 7159 - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune containers with (or without, in case `label!=...` is used) the specified labels. 7160 type: "string" 7161 responses: 7162 200: 7163 description: "No error" 7164 schema: 7165 type: "object" 7166 title: "ContainerPruneResponse" 7167 properties: 7168 ContainersDeleted: 7169 description: "Container IDs that were deleted" 7170 type: "array" 7171 items: 7172 type: "string" 7173 SpaceReclaimed: 7174 description: "Disk space reclaimed in bytes" 7175 type: "integer" 7176 format: "int64" 7177 500: 7178 description: "Server error" 7179 schema: 7180 $ref: "#/definitions/ErrorResponse" 7181 tags: ["Container"] 7182 /images/json: 7183 get: 7184 summary: "List Images" 7185 description: "Returns a list of images on the server. Note that it uses a different, smaller representation of an image than inspecting a single image." 7186 operationId: "ImageList" 7187 produces: 7188 - "application/json" 7189 responses: 7190 200: 7191 description: "Summary image data for the images matching the query" 7192 schema: 7193 type: "array" 7194 items: 7195 $ref: "#/definitions/ImageSummary" 7196 500: 7197 description: "server error" 7198 schema: 7199 $ref: "#/definitions/ErrorResponse" 7200 parameters: 7201 - name: "all" 7202 in: "query" 7203 description: "Show all images. Only images from a final layer (no children) are shown by default." 7204 type: "boolean" 7205 default: false 7206 - name: "filters" 7207 in: "query" 7208 description: | 7209 A JSON encoded value of the filters (a `map[string][]string`) to 7210 process on the images list. 7211 7212 Available filters: 7213 7214 - `before`=(`<image-name>[:<tag>]`, `<image id>` or `<image@digest>`) 7215 - `dangling=true` 7216 - `label=key` or `label="key=value"` of an image label 7217 - `reference`=(`<image-name>[:<tag>]`) 7218 - `since`=(`<image-name>[:<tag>]`, `<image id>` or `<image@digest>`) 7219 type: "string" 7220 - name: "digests" 7221 in: "query" 7222 description: "Show digest information as a `RepoDigests` field on each image." 7223 type: "boolean" 7224 default: false 7225 tags: ["Image"] 7226 /build: 7227 post: 7228 summary: "Build an image" 7229 description: | 7230 Build an image from a tar archive with a `Dockerfile` in it. 7231 7232 The `Dockerfile` specifies how the image is built from the tar archive. It is typically in the archive's root, but can be at a different path or have a different name by specifying the `dockerfile` parameter. [See the `Dockerfile` reference for more information](https://docs.docker.com/engine/reference/builder/). 7233 7234 The Docker daemon performs a preliminary validation of the `Dockerfile` before starting the build, and returns an error if the syntax is incorrect. After that, each instruction is run one-by-one until the ID of the new image is output. 7235 7236 The build is canceled if the client drops the connection by quitting or being killed. 7237 operationId: "ImageBuild" 7238 consumes: 7239 - "application/octet-stream" 7240 produces: 7241 - "application/json" 7242 parameters: 7243 - name: "inputStream" 7244 in: "body" 7245 description: "A tar archive compressed with one of the following algorithms: identity (no compression), gzip, bzip2, xz." 7246 schema: 7247 type: "string" 7248 format: "binary" 7249 - name: "dockerfile" 7250 in: "query" 7251 description: "Path within the build context to the `Dockerfile`. This is ignored if `remote` is specified and points to an external `Dockerfile`." 7252 type: "string" 7253 default: "Dockerfile" 7254 - name: "t" 7255 in: "query" 7256 description: "A name and optional tag to apply to the image in the `name:tag` format. If you omit the tag the default `latest` value is assumed. You can provide several `t` parameters." 7257 type: "string" 7258 - name: "extrahosts" 7259 in: "query" 7260 description: "Extra hosts to add to /etc/hosts" 7261 type: "string" 7262 - name: "remote" 7263 in: "query" 7264 description: "A Git repository URI or HTTP/HTTPS context URI. If the URI points to a single text file, the file’s contents are placed into a file called `Dockerfile` and the image is built from that file. If the URI points to a tarball, the file is downloaded by the daemon and the contents therein used as the context for the build. If the URI points to a tarball and the `dockerfile` parameter is also specified, there must be a file with the corresponding path inside the tarball." 7265 type: "string" 7266 - name: "q" 7267 in: "query" 7268 description: "Suppress verbose build output." 7269 type: "boolean" 7270 default: false 7271 - name: "nocache" 7272 in: "query" 7273 description: "Do not use the cache when building the image." 7274 type: "boolean" 7275 default: false 7276 - name: "cachefrom" 7277 in: "query" 7278 description: "JSON array of images used for build cache resolution." 7279 type: "string" 7280 - name: "pull" 7281 in: "query" 7282 description: "Attempt to pull the image even if an older image exists locally." 7283 type: "string" 7284 - name: "rm" 7285 in: "query" 7286 description: "Remove intermediate containers after a successful build." 7287 type: "boolean" 7288 default: true 7289 - name: "forcerm" 7290 in: "query" 7291 description: "Always remove intermediate containers, even upon failure." 7292 type: "boolean" 7293 default: false 7294 - name: "memory" 7295 in: "query" 7296 description: "Set memory limit for build." 7297 type: "integer" 7298 - name: "memswap" 7299 in: "query" 7300 description: "Total memory (memory + swap). Set as `-1` to disable swap." 7301 type: "integer" 7302 - name: "cpushares" 7303 in: "query" 7304 description: "CPU shares (relative weight)." 7305 type: "integer" 7306 - name: "cpusetcpus" 7307 in: "query" 7308 description: "CPUs in which to allow execution (e.g., `0-3`, `0,1`)." 7309 type: "string" 7310 - name: "cpuperiod" 7311 in: "query" 7312 description: "The length of a CPU period in microseconds." 7313 type: "integer" 7314 - name: "cpuquota" 7315 in: "query" 7316 description: "Microseconds of CPU time that the container can get in a CPU period." 7317 type: "integer" 7318 - name: "buildargs" 7319 in: "query" 7320 description: > 7321 JSON map of string pairs for build-time variables. Users pass these values at build-time. Docker 7322 uses the buildargs as the environment context for commands run via the `Dockerfile` RUN 7323 instruction, or for variable expansion in other `Dockerfile` instructions. This is not meant for 7324 passing secret values. 7325 7326 7327 For example, the build arg `FOO=bar` would become `{"FOO":"bar"}` in JSON. This would result in the 7328 query parameter `buildargs={"FOO":"bar"}`. Note that `{"FOO":"bar"}` should be URI component encoded. 7329 7330 7331 [Read more about the buildargs instruction.](https://docs.docker.com/engine/reference/builder/#arg) 7332 type: "string" 7333 - name: "shmsize" 7334 in: "query" 7335 description: "Size of `/dev/shm` in bytes. The size must be greater than 0. If omitted the system uses 64MB." 7336 type: "integer" 7337 - name: "squash" 7338 in: "query" 7339 description: "Squash the resulting images layers into a single layer. *(Experimental release only.)*" 7340 type: "boolean" 7341 - name: "labels" 7342 in: "query" 7343 description: "Arbitrary key/value labels to set on the image, as a JSON map of string pairs." 7344 type: "string" 7345 - name: "networkmode" 7346 in: "query" 7347 description: | 7348 Sets the networking mode for the run commands during build. Supported 7349 standard values are: `bridge`, `host`, `none`, and `container:<name|id>`. 7350 Any other value is taken as a custom network's name or ID to which this 7351 container should connect to. 7352 type: "string" 7353 - name: "Content-type" 7354 in: "header" 7355 type: "string" 7356 enum: 7357 - "application/x-tar" 7358 default: "application/x-tar" 7359 - name: "X-Registry-Config" 7360 in: "header" 7361 description: | 7362 This is a base64-encoded JSON object with auth configurations for multiple registries that a build may refer to. 7363 7364 The key is a registry URL, and the value is an auth configuration object, [as described in the authentication section](#section/Authentication). For example: 7365 7366 ``` 7367 { 7368 "docker.example.com": { 7369 "username": "janedoe", 7370 "password": "hunter2" 7371 }, 7372 "https://index.docker.io/v1/": { 7373 "username": "mobydock", 7374 "password": "conta1n3rize14" 7375 } 7376 } 7377 ``` 7378 7379 Only the registry domain name (and port if not the default 443) are required. However, for legacy reasons, the Docker Hub registry must be specified with both a `https://` prefix and a `/v1/` suffix even though Docker will prefer to use the v2 registry API. 7380 type: "string" 7381 - name: "platform" 7382 in: "query" 7383 description: "Platform in the format os[/arch[/variant]]" 7384 type: "string" 7385 default: "" 7386 - name: "target" 7387 in: "query" 7388 description: "Target build stage" 7389 type: "string" 7390 default: "" 7391 responses: 7392 200: 7393 description: "no error" 7394 400: 7395 description: "Bad parameter" 7396 schema: 7397 $ref: "#/definitions/ErrorResponse" 7398 500: 7399 description: "server error" 7400 schema: 7401 $ref: "#/definitions/ErrorResponse" 7402 tags: ["Image"] 7403 /build/prune: 7404 post: 7405 summary: "Delete builder cache" 7406 produces: 7407 - "application/json" 7408 operationId: "BuildPrune" 7409 parameters: 7410 - name: "keep-storage" 7411 in: "query" 7412 description: "Amount of disk space in bytes to keep for cache" 7413 type: "integer" 7414 format: "int64" 7415 - name: "all" 7416 in: "query" 7417 type: "boolean" 7418 description: "Remove all types of build cache" 7419 - name: "filters" 7420 in: "query" 7421 type: "string" 7422 description: | 7423 A JSON encoded value of the filters (a `map[string][]string`) to 7424 process on the list of build cache objects. 7425 7426 Available filters: 7427 7428 - `until=<duration>`: duration relative to daemon's time, during which build cache was not used, in Go's duration format (e.g., '24h') 7429 - `id=<id>` 7430 - `parent=<id>` 7431 - `type=<string>` 7432 - `description=<string>` 7433 - `inuse` 7434 - `shared` 7435 - `private` 7436 responses: 7437 200: 7438 description: "No error" 7439 schema: 7440 type: "object" 7441 title: "BuildPruneResponse" 7442 properties: 7443 CachesDeleted: 7444 type: "array" 7445 items: 7446 description: "ID of build cache object" 7447 type: "string" 7448 SpaceReclaimed: 7449 description: "Disk space reclaimed in bytes" 7450 type: "integer" 7451 format: "int64" 7452 500: 7453 description: "Server error" 7454 schema: 7455 $ref: "#/definitions/ErrorResponse" 7456 tags: ["Image"] 7457 /images/create: 7458 post: 7459 summary: "Create an image" 7460 description: "Create an image by either pulling it from a registry or importing it." 7461 operationId: "ImageCreate" 7462 consumes: 7463 - "text/plain" 7464 - "application/octet-stream" 7465 produces: 7466 - "application/json" 7467 responses: 7468 200: 7469 description: "no error" 7470 404: 7471 description: "repository does not exist or no read access" 7472 schema: 7473 $ref: "#/definitions/ErrorResponse" 7474 500: 7475 description: "server error" 7476 schema: 7477 $ref: "#/definitions/ErrorResponse" 7478 parameters: 7479 - name: "fromImage" 7480 in: "query" 7481 description: "Name of the image to pull. The name may include a tag or digest. This parameter may only be used when pulling an image. The pull is cancelled if the HTTP connection is closed." 7482 type: "string" 7483 - name: "fromSrc" 7484 in: "query" 7485 description: "Source to import. The value may be a URL from which the image can be retrieved or `-` to read the image from the request body. This parameter may only be used when importing an image." 7486 type: "string" 7487 - name: "repo" 7488 in: "query" 7489 description: "Repository name given to an image when it is imported. The repo may include a tag. This parameter may only be used when importing an image." 7490 type: "string" 7491 - name: "tag" 7492 in: "query" 7493 description: "Tag or digest. If empty when pulling an image, this causes all tags for the given image to be pulled." 7494 type: "string" 7495 - name: "message" 7496 in: "query" 7497 description: "Set commit message for imported image." 7498 type: "string" 7499 - name: "inputImage" 7500 in: "body" 7501 description: "Image content if the value `-` has been specified in fromSrc query parameter" 7502 schema: 7503 type: "string" 7504 required: false 7505 - name: "X-Registry-Auth" 7506 in: "header" 7507 description: | 7508 A base64url-encoded auth configuration. 7509 7510 Refer to the [authentication section](#section/Authentication) for 7511 details. 7512 type: "string" 7513 - name: "platform" 7514 in: "query" 7515 description: "Platform in the format os[/arch[/variant]]" 7516 type: "string" 7517 default: "" 7518 tags: ["Image"] 7519 /images/{name}/json: 7520 get: 7521 summary: "Inspect an image" 7522 description: "Return low-level information about an image." 7523 operationId: "ImageInspect" 7524 produces: 7525 - "application/json" 7526 responses: 7527 200: 7528 description: "No error" 7529 schema: 7530 $ref: "#/definitions/ImageInspect" 7531 404: 7532 description: "No such image" 7533 schema: 7534 $ref: "#/definitions/ErrorResponse" 7535 examples: 7536 application/json: 7537 message: "No such image: someimage (tag: latest)" 7538 500: 7539 description: "Server error" 7540 schema: 7541 $ref: "#/definitions/ErrorResponse" 7542 parameters: 7543 - name: "name" 7544 in: "path" 7545 description: "Image name or id" 7546 type: "string" 7547 required: true 7548 tags: ["Image"] 7549 /images/{name}/history: 7550 get: 7551 summary: "Get the history of an image" 7552 description: "Return parent layers of an image." 7553 operationId: "ImageHistory" 7554 produces: ["application/json"] 7555 responses: 7556 200: 7557 description: "List of image layers" 7558 schema: 7559 type: "array" 7560 items: 7561 type: "object" 7562 x-go-name: HistoryResponseItem 7563 title: "HistoryResponseItem" 7564 description: "individual image layer information in response to ImageHistory operation" 7565 required: [Id, Created, CreatedBy, Tags, Size, Comment] 7566 properties: 7567 Id: 7568 type: "string" 7569 x-nullable: false 7570 Created: 7571 type: "integer" 7572 format: "int64" 7573 x-nullable: false 7574 CreatedBy: 7575 type: "string" 7576 x-nullable: false 7577 Tags: 7578 type: "array" 7579 items: 7580 type: "string" 7581 Size: 7582 type: "integer" 7583 format: "int64" 7584 x-nullable: false 7585 Comment: 7586 type: "string" 7587 x-nullable: false 7588 examples: 7589 application/json: 7590 - Id: "3db9c44f45209632d6050b35958829c3a2aa256d81b9a7be45b362ff85c54710" 7591 Created: 1398108230 7592 CreatedBy: "/bin/sh -c #(nop) ADD file:eb15dbd63394e063b805a3c32ca7bf0266ef64676d5a6fab4801f2e81e2a5148 in /" 7593 Tags: 7594 - "ubuntu:lucid" 7595 - "ubuntu:10.04" 7596 Size: 182964289 7597 Comment: "" 7598 - Id: "6cfa4d1f33fb861d4d114f43b25abd0ac737509268065cdfd69d544a59c85ab8" 7599 Created: 1398108222 7600 CreatedBy: "/bin/sh -c #(nop) MAINTAINER Tianon Gravi <admwiggin@gmail.com> - mkimage-debootstrap.sh -i iproute,iputils-ping,ubuntu-minimal -t lucid.tar.xz lucid http://archive.ubuntu.com/ubuntu/" 7601 Tags: [] 7602 Size: 0 7603 Comment: "" 7604 - Id: "511136ea3c5a64f264b78b5433614aec563103b4d4702f3ba7d4d2698e22c158" 7605 Created: 1371157430 7606 CreatedBy: "" 7607 Tags: 7608 - "scratch12:latest" 7609 - "scratch:latest" 7610 Size: 0 7611 Comment: "Imported from -" 7612 404: 7613 description: "No such image" 7614 schema: 7615 $ref: "#/definitions/ErrorResponse" 7616 500: 7617 description: "Server error" 7618 schema: 7619 $ref: "#/definitions/ErrorResponse" 7620 parameters: 7621 - name: "name" 7622 in: "path" 7623 description: "Image name or ID" 7624 type: "string" 7625 required: true 7626 tags: ["Image"] 7627 /images/{name}/push: 7628 post: 7629 summary: "Push an image" 7630 description: | 7631 Push an image to a registry. 7632 7633 If you wish to push an image on to a private registry, that image must 7634 already have a tag which references the registry. For example, 7635 `registry.example.com/myimage:latest`. 7636 7637 The push is cancelled if the HTTP connection is closed. 7638 operationId: "ImagePush" 7639 consumes: 7640 - "application/octet-stream" 7641 responses: 7642 200: 7643 description: "No error" 7644 404: 7645 description: "No such image" 7646 schema: 7647 $ref: "#/definitions/ErrorResponse" 7648 500: 7649 description: "Server error" 7650 schema: 7651 $ref: "#/definitions/ErrorResponse" 7652 parameters: 7653 - name: "name" 7654 in: "path" 7655 description: "Image name or ID." 7656 type: "string" 7657 required: true 7658 - name: "tag" 7659 in: "query" 7660 description: "The tag to associate with the image on the registry." 7661 type: "string" 7662 - name: "X-Registry-Auth" 7663 in: "header" 7664 description: | 7665 A base64url-encoded auth configuration. 7666 7667 Refer to the [authentication section](#section/Authentication) for 7668 details. 7669 type: "string" 7670 required: true 7671 tags: ["Image"] 7672 /images/{name}/tag: 7673 post: 7674 summary: "Tag an image" 7675 description: "Tag an image so that it becomes part of a repository." 7676 operationId: "ImageTag" 7677 responses: 7678 201: 7679 description: "No error" 7680 400: 7681 description: "Bad parameter" 7682 schema: 7683 $ref: "#/definitions/ErrorResponse" 7684 404: 7685 description: "No such image" 7686 schema: 7687 $ref: "#/definitions/ErrorResponse" 7688 409: 7689 description: "Conflict" 7690 schema: 7691 $ref: "#/definitions/ErrorResponse" 7692 500: 7693 description: "Server error" 7694 schema: 7695 $ref: "#/definitions/ErrorResponse" 7696 parameters: 7697 - name: "name" 7698 in: "path" 7699 description: "Image name or ID to tag." 7700 type: "string" 7701 required: true 7702 - name: "repo" 7703 in: "query" 7704 description: "The repository to tag in. For example, `someuser/someimage`." 7705 type: "string" 7706 - name: "tag" 7707 in: "query" 7708 description: "The name of the new tag." 7709 type: "string" 7710 tags: ["Image"] 7711 /images/{name}: 7712 delete: 7713 summary: "Remove an image" 7714 description: | 7715 Remove an image, along with any untagged parent images that were 7716 referenced by that image. 7717 7718 Images can't be removed if they have descendant images, are being 7719 used by a running container or are being used by a build. 7720 operationId: "ImageDelete" 7721 produces: ["application/json"] 7722 responses: 7723 200: 7724 description: "The image was deleted successfully" 7725 schema: 7726 type: "array" 7727 items: 7728 $ref: "#/definitions/ImageDeleteResponseItem" 7729 examples: 7730 application/json: 7731 - Untagged: "3e2f21a89f" 7732 - Deleted: "3e2f21a89f" 7733 - Deleted: "53b4f83ac9" 7734 404: 7735 description: "No such image" 7736 schema: 7737 $ref: "#/definitions/ErrorResponse" 7738 409: 7739 description: "Conflict" 7740 schema: 7741 $ref: "#/definitions/ErrorResponse" 7742 500: 7743 description: "Server error" 7744 schema: 7745 $ref: "#/definitions/ErrorResponse" 7746 parameters: 7747 - name: "name" 7748 in: "path" 7749 description: "Image name or ID" 7750 type: "string" 7751 required: true 7752 - name: "force" 7753 in: "query" 7754 description: "Remove the image even if it is being used by stopped containers or has other tags" 7755 type: "boolean" 7756 default: false 7757 - name: "noprune" 7758 in: "query" 7759 description: "Do not delete untagged parent images" 7760 type: "boolean" 7761 default: false 7762 tags: ["Image"] 7763 /images/search: 7764 get: 7765 summary: "Search images" 7766 description: "Search for an image on Docker Hub." 7767 operationId: "ImageSearch" 7768 produces: 7769 - "application/json" 7770 responses: 7771 200: 7772 description: "No error" 7773 schema: 7774 type: "array" 7775 items: 7776 type: "object" 7777 title: "ImageSearchResponseItem" 7778 properties: 7779 description: 7780 type: "string" 7781 is_official: 7782 type: "boolean" 7783 is_automated: 7784 type: "boolean" 7785 name: 7786 type: "string" 7787 star_count: 7788 type: "integer" 7789 examples: 7790 application/json: 7791 - description: "" 7792 is_official: false 7793 is_automated: false 7794 name: "wma55/u1210sshd" 7795 star_count: 0 7796 - description: "" 7797 is_official: false 7798 is_automated: false 7799 name: "jdswinbank/sshd" 7800 star_count: 0 7801 - description: "" 7802 is_official: false 7803 is_automated: false 7804 name: "vgauthier/sshd" 7805 star_count: 0 7806 500: 7807 description: "Server error" 7808 schema: 7809 $ref: "#/definitions/ErrorResponse" 7810 parameters: 7811 - name: "term" 7812 in: "query" 7813 description: "Term to search" 7814 type: "string" 7815 required: true 7816 - name: "limit" 7817 in: "query" 7818 description: "Maximum number of results to return" 7819 type: "integer" 7820 - name: "filters" 7821 in: "query" 7822 description: | 7823 A JSON encoded value of the filters (a `map[string][]string`) to process on the images list. Available filters: 7824 7825 - `is-automated=(true|false)` 7826 - `is-official=(true|false)` 7827 - `stars=<number>` Matches images that has at least 'number' stars. 7828 type: "string" 7829 tags: ["Image"] 7830 /images/prune: 7831 post: 7832 summary: "Delete unused images" 7833 produces: 7834 - "application/json" 7835 operationId: "ImagePrune" 7836 parameters: 7837 - name: "filters" 7838 in: "query" 7839 description: | 7840 Filters to process on the prune list, encoded as JSON (a `map[string][]string`). Available filters: 7841 7842 - `dangling=<boolean>` When set to `true` (or `1`), prune only 7843 unused *and* untagged images. When set to `false` 7844 (or `0`), all unused images are pruned. 7845 - `until=<string>` Prune images created before this timestamp. The `<timestamp>` can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed relative to the daemon machine’s time. 7846 - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune images with (or without, in case `label!=...` is used) the specified labels. 7847 type: "string" 7848 responses: 7849 200: 7850 description: "No error" 7851 schema: 7852 type: "object" 7853 title: "ImagePruneResponse" 7854 properties: 7855 ImagesDeleted: 7856 description: "Images that were deleted" 7857 type: "array" 7858 items: 7859 $ref: "#/definitions/ImageDeleteResponseItem" 7860 SpaceReclaimed: 7861 description: "Disk space reclaimed in bytes" 7862 type: "integer" 7863 format: "int64" 7864 500: 7865 description: "Server error" 7866 schema: 7867 $ref: "#/definitions/ErrorResponse" 7868 tags: ["Image"] 7869 /auth: 7870 post: 7871 summary: "Check auth configuration" 7872 description: | 7873 Validate credentials for a registry and, if available, get an identity 7874 token for accessing the registry without password. 7875 operationId: "SystemAuth" 7876 consumes: ["application/json"] 7877 produces: ["application/json"] 7878 responses: 7879 200: 7880 description: "An identity token was generated successfully." 7881 schema: 7882 type: "object" 7883 title: "SystemAuthResponse" 7884 required: [Status] 7885 properties: 7886 Status: 7887 description: "The status of the authentication" 7888 type: "string" 7889 x-nullable: false 7890 IdentityToken: 7891 description: "An opaque token used to authenticate a user after a successful login" 7892 type: "string" 7893 x-nullable: false 7894 examples: 7895 application/json: 7896 Status: "Login Succeeded" 7897 IdentityToken: "9cbaf023786cd7..." 7898 204: 7899 description: "No error" 7900 500: 7901 description: "Server error" 7902 schema: 7903 $ref: "#/definitions/ErrorResponse" 7904 parameters: 7905 - name: "authConfig" 7906 in: "body" 7907 description: "Authentication to check" 7908 schema: 7909 $ref: "#/definitions/AuthConfig" 7910 tags: ["System"] 7911 /info: 7912 get: 7913 summary: "Get system information" 7914 operationId: "SystemInfo" 7915 produces: 7916 - "application/json" 7917 responses: 7918 200: 7919 description: "No error" 7920 schema: 7921 $ref: "#/definitions/SystemInfo" 7922 500: 7923 description: "Server error" 7924 schema: 7925 $ref: "#/definitions/ErrorResponse" 7926 tags: ["System"] 7927 /version: 7928 get: 7929 summary: "Get version" 7930 description: "Returns the version of Docker that is running and various information about the system that Docker is running on." 7931 operationId: "SystemVersion" 7932 produces: ["application/json"] 7933 responses: 7934 200: 7935 description: "no error" 7936 schema: 7937 $ref: "#/definitions/SystemVersion" 7938 500: 7939 description: "server error" 7940 schema: 7941 $ref: "#/definitions/ErrorResponse" 7942 tags: ["System"] 7943 /_ping: 7944 get: 7945 summary: "Ping" 7946 description: "This is a dummy endpoint you can use to test if the server is accessible." 7947 operationId: "SystemPing" 7948 produces: ["text/plain"] 7949 responses: 7950 200: 7951 description: "no error" 7952 schema: 7953 type: "string" 7954 example: "OK" 7955 headers: 7956 API-Version: 7957 type: "string" 7958 description: "Max API Version the server supports" 7959 Builder-Version: 7960 type: "string" 7961 description: "Default version of docker image builder" 7962 Docker-Experimental: 7963 type: "boolean" 7964 description: "If the server is running with experimental mode enabled" 7965 500: 7966 description: "server error" 7967 schema: 7968 $ref: "#/definitions/ErrorResponse" 7969 tags: ["System"] 7970 /commit: 7971 post: 7972 summary: "Create a new image from a container" 7973 operationId: "ImageCommit" 7974 consumes: 7975 - "application/json" 7976 produces: 7977 - "application/json" 7978 responses: 7979 201: 7980 description: "no error" 7981 schema: 7982 $ref: "#/definitions/IdResponse" 7983 404: 7984 description: "no such container" 7985 schema: 7986 $ref: "#/definitions/ErrorResponse" 7987 examples: 7988 application/json: 7989 message: "No such container: c2ada9df5af8" 7990 500: 7991 description: "server error" 7992 schema: 7993 $ref: "#/definitions/ErrorResponse" 7994 parameters: 7995 - name: "containerConfig" 7996 in: "body" 7997 description: "The container configuration" 7998 schema: 7999 $ref: "#/definitions/ContainerConfig" 8000 - name: "container" 8001 in: "query" 8002 description: "The ID or name of the container to commit" 8003 type: "string" 8004 - name: "repo" 8005 in: "query" 8006 description: "Repository name for the created image" 8007 type: "string" 8008 - name: "tag" 8009 in: "query" 8010 description: "Tag name for the create image" 8011 type: "string" 8012 - name: "comment" 8013 in: "query" 8014 description: "Commit message" 8015 type: "string" 8016 - name: "author" 8017 in: "query" 8018 description: "Author of the image (e.g., `John Hannibal Smith <hannibal@a-team.com>`)" 8019 type: "string" 8020 - name: "pause" 8021 in: "query" 8022 description: "Whether to pause the container before committing" 8023 type: "boolean" 8024 default: true 8025 - name: "changes" 8026 in: "query" 8027 description: "`Dockerfile` instructions to apply while committing" 8028 type: "string" 8029 tags: ["Image"] 8030 /events: 8031 get: 8032 summary: "Monitor events" 8033 description: | 8034 Stream real-time events from the server. 8035 8036 Various objects within Docker report events when something happens to them. 8037 8038 Containers report these events: `attach`, `commit`, `copy`, `create`, `destroy`, `detach`, `die`, `exec_create`, `exec_detach`, `exec_start`, `exec_die`, `export`, `health_status`, `kill`, `oom`, `pause`, `rename`, `resize`, `restart`, `start`, `stop`, `top`, `unpause`, and `update` 8039 8040 Images report these events: `delete`, `import`, `load`, `pull`, `push`, `save`, `tag`, and `untag` 8041 8042 Volumes report these events: `create`, `mount`, `unmount`, and `destroy` 8043 8044 Networks report these events: `create`, `connect`, `disconnect`, `destroy`, `update`, and `remove` 8045 8046 The Docker daemon reports these events: `reload` 8047 8048 Services report these events: `create`, `update`, and `remove` 8049 8050 Nodes report these events: `create`, `update`, and `remove` 8051 8052 Secrets report these events: `create`, `update`, and `remove` 8053 8054 Configs report these events: `create`, `update`, and `remove` 8055 8056 operationId: "SystemEvents" 8057 produces: 8058 - "application/json" 8059 responses: 8060 200: 8061 description: "no error" 8062 schema: 8063 type: "object" 8064 title: "SystemEventsResponse" 8065 properties: 8066 Type: 8067 description: "The type of object emitting the event" 8068 type: "string" 8069 Action: 8070 description: "The type of event" 8071 type: "string" 8072 Actor: 8073 type: "object" 8074 properties: 8075 ID: 8076 description: "The ID of the object emitting the event" 8077 type: "string" 8078 Attributes: 8079 description: "Various key/value attributes of the object, depending on its type" 8080 type: "object" 8081 additionalProperties: 8082 type: "string" 8083 time: 8084 description: "Timestamp of event" 8085 type: "integer" 8086 timeNano: 8087 description: "Timestamp of event, with nanosecond accuracy" 8088 type: "integer" 8089 format: "int64" 8090 examples: 8091 application/json: 8092 Type: "container" 8093 Action: "create" 8094 Actor: 8095 ID: "ede54ee1afda366ab42f824e8a5ffd195155d853ceaec74a927f249ea270c743" 8096 Attributes: 8097 com.example.some-label: "some-label-value" 8098 image: "alpine" 8099 name: "my-container" 8100 time: 1461943101 8101 400: 8102 description: "bad parameter" 8103 schema: 8104 $ref: "#/definitions/ErrorResponse" 8105 500: 8106 description: "server error" 8107 schema: 8108 $ref: "#/definitions/ErrorResponse" 8109 parameters: 8110 - name: "since" 8111 in: "query" 8112 description: "Show events created since this timestamp then stream new events." 8113 type: "string" 8114 - name: "until" 8115 in: "query" 8116 description: "Show events created until this timestamp then stop streaming." 8117 type: "string" 8118 - name: "filters" 8119 in: "query" 8120 description: | 8121 A JSON encoded value of filters (a `map[string][]string`) to process on the event list. Available filters: 8122 8123 - `config=<string>` config name or ID 8124 - `container=<string>` container name or ID 8125 - `daemon=<string>` daemon name or ID 8126 - `event=<string>` event type 8127 - `image=<string>` image name or ID 8128 - `label=<string>` image or container label 8129 - `network=<string>` network name or ID 8130 - `node=<string>` node ID 8131 - `plugin`=<string> plugin name or ID 8132 - `scope`=<string> local or swarm 8133 - `secret=<string>` secret name or ID 8134 - `service=<string>` service name or ID 8135 - `type=<string>` object to filter by, one of `container`, `image`, `volume`, `network`, `daemon`, `plugin`, `node`, `service`, `secret` or `config` 8136 - `volume=<string>` volume name 8137 type: "string" 8138 tags: ["System"] 8139 /system/df: 8140 get: 8141 summary: "Get data usage information" 8142 operationId: "SystemDataUsage" 8143 responses: 8144 200: 8145 description: "no error" 8146 schema: 8147 type: "object" 8148 title: "SystemDataUsageResponse" 8149 properties: 8150 LayersSize: 8151 type: "integer" 8152 format: "int64" 8153 Images: 8154 type: "array" 8155 items: 8156 $ref: "#/definitions/ImageSummary" 8157 Containers: 8158 type: "array" 8159 items: 8160 $ref: "#/definitions/ContainerSummary" 8161 Volumes: 8162 type: "array" 8163 items: 8164 $ref: "#/definitions/Volume" 8165 BuildCache: 8166 type: "array" 8167 items: 8168 $ref: "#/definitions/BuildCache" 8169 example: 8170 LayersSize: 1092588 8171 Images: 8172 - 8173 Id: "sha256:2b8fd9751c4c0f5dd266fcae00707e67a2545ef34f9a29354585f93dac906749" 8174 ParentId: "" 8175 RepoTags: 8176 - "busybox:latest" 8177 RepoDigests: 8178 - "busybox@sha256:a59906e33509d14c036c8678d687bd4eec81ed7c4b8ce907b888c607f6a1e0e6" 8179 Created: 1466724217 8180 Size: 1092588 8181 SharedSize: 0 8182 VirtualSize: 1092588 8183 Labels: {} 8184 Containers: 1 8185 Containers: 8186 - 8187 Id: "e575172ed11dc01bfce087fb27bee502db149e1a0fad7c296ad300bbff178148" 8188 Names: 8189 - "/top" 8190 Image: "busybox" 8191 ImageID: "sha256:2b8fd9751c4c0f5dd266fcae00707e67a2545ef34f9a29354585f93dac906749" 8192 Command: "top" 8193 Created: 1472592424 8194 Ports: [] 8195 SizeRootFs: 1092588 8196 Labels: {} 8197 State: "exited" 8198 Status: "Exited (0) 56 minutes ago" 8199 HostConfig: 8200 NetworkMode: "default" 8201 NetworkSettings: 8202 Networks: 8203 bridge: 8204 IPAMConfig: null 8205 Links: null 8206 Aliases: null 8207 NetworkID: "d687bc59335f0e5c9ee8193e5612e8aee000c8c62ea170cfb99c098f95899d92" 8208 EndpointID: "8ed5115aeaad9abb174f68dcf135b49f11daf597678315231a32ca28441dec6a" 8209 Gateway: "172.18.0.1" 8210 IPAddress: "172.18.0.2" 8211 IPPrefixLen: 16 8212 IPv6Gateway: "" 8213 GlobalIPv6Address: "" 8214 GlobalIPv6PrefixLen: 0 8215 MacAddress: "02:42:ac:12:00:02" 8216 Mounts: [] 8217 Volumes: 8218 - 8219 Name: "my-volume" 8220 Driver: "local" 8221 Mountpoint: "/var/lib/docker/volumes/my-volume/_data" 8222 Labels: null 8223 Scope: "local" 8224 Options: null 8225 UsageData: 8226 Size: 10920104 8227 RefCount: 2 8228 BuildCache: 8229 - 8230 ID: "hw53o5aio51xtltp5xjp8v7fx" 8231 Parent: "" 8232 Type: "regular" 8233 Description: "pulled from docker.io/library/debian@sha256:234cb88d3020898631af0ccbbcca9a66ae7306ecd30c9720690858c1b007d2a0" 8234 InUse: false 8235 Shared: true 8236 Size: 0 8237 CreatedAt: "2021-06-28T13:31:01.474619385Z" 8238 LastUsedAt: "2021-07-07T22:02:32.738075951Z" 8239 UsageCount: 26 8240 - 8241 ID: "ndlpt0hhvkqcdfkputsk4cq9c" 8242 Parent: "ndlpt0hhvkqcdfkputsk4cq9c" 8243 Type: "regular" 8244 Description: "mount / from exec /bin/sh -c echo 'Binary::apt::APT::Keep-Downloaded-Packages \"true\";' > /etc/apt/apt.conf.d/keep-cache" 8245 InUse: false 8246 Shared: true 8247 Size: 51 8248 CreatedAt: "2021-06-28T13:31:03.002625487Z" 8249 LastUsedAt: "2021-07-07T22:02:32.773909517Z" 8250 UsageCount: 26 8251 500: 8252 description: "server error" 8253 schema: 8254 $ref: "#/definitions/ErrorResponse" 8255 tags: ["System"] 8256 /images/{name}/get: 8257 get: 8258 summary: "Export an image" 8259 description: | 8260 Get a tarball containing all images and metadata for a repository. 8261 8262 If `name` is a specific name and tag (e.g. `ubuntu:latest`), then only that image (and its parents) are returned. If `name` is an image ID, similarly only that image (and its parents) are returned, but with the exclusion of the `repositories` file in the tarball, as there were no image names referenced. 8263 8264 ### Image tarball format 8265 8266 An image tarball contains one directory per image layer (named using its long ID), each containing these files: 8267 8268 - `VERSION`: currently `1.0` - the file format version 8269 - `json`: detailed layer information, similar to `docker inspect layer_id` 8270 - `layer.tar`: A tarfile containing the filesystem changes in this layer 8271 8272 The `layer.tar` file contains `aufs` style `.wh..wh.aufs` files and directories for storing attribute changes and deletions. 8273 8274 If the tarball defines a repository, the tarball should also include a `repositories` file at the root that contains a list of repository and tag names mapped to layer IDs. 8275 8276 ```json 8277 { 8278 "hello-world": { 8279 "latest": "565a9d68a73f6706862bfe8409a7f659776d4d60a8d096eb4a3cbce6999cc2a1" 8280 } 8281 } 8282 ``` 8283 operationId: "ImageGet" 8284 produces: 8285 - "application/x-tar" 8286 responses: 8287 200: 8288 description: "no error" 8289 schema: 8290 type: "string" 8291 format: "binary" 8292 500: 8293 description: "server error" 8294 schema: 8295 $ref: "#/definitions/ErrorResponse" 8296 parameters: 8297 - name: "name" 8298 in: "path" 8299 description: "Image name or ID" 8300 type: "string" 8301 required: true 8302 tags: ["Image"] 8303 /images/get: 8304 get: 8305 summary: "Export several images" 8306 description: | 8307 Get a tarball containing all images and metadata for several image 8308 repositories. 8309 8310 For each value of the `names` parameter: if it is a specific name and 8311 tag (e.g. `ubuntu:latest`), then only that image (and its parents) are 8312 returned; if it is an image ID, similarly only that image (and its parents) 8313 are returned and there would be no names referenced in the 'repositories' 8314 file for this image ID. 8315 8316 For details on the format, see the [export image endpoint](#operation/ImageGet). 8317 operationId: "ImageGetAll" 8318 produces: 8319 - "application/x-tar" 8320 responses: 8321 200: 8322 description: "no error" 8323 schema: 8324 type: "string" 8325 format: "binary" 8326 500: 8327 description: "server error" 8328 schema: 8329 $ref: "#/definitions/ErrorResponse" 8330 parameters: 8331 - name: "names" 8332 in: "query" 8333 description: "Image names to filter by" 8334 type: "array" 8335 items: 8336 type: "string" 8337 tags: ["Image"] 8338 /images/load: 8339 post: 8340 summary: "Import images" 8341 description: | 8342 Load a set of images and tags into a repository. 8343 8344 For details on the format, see the [export image endpoint](#operation/ImageGet). 8345 operationId: "ImageLoad" 8346 consumes: 8347 - "application/x-tar" 8348 produces: 8349 - "application/json" 8350 responses: 8351 200: 8352 description: "no error" 8353 500: 8354 description: "server error" 8355 schema: 8356 $ref: "#/definitions/ErrorResponse" 8357 parameters: 8358 - name: "imagesTarball" 8359 in: "body" 8360 description: "Tar archive containing images" 8361 schema: 8362 type: "string" 8363 format: "binary" 8364 - name: "quiet" 8365 in: "query" 8366 description: "Suppress progress details during load." 8367 type: "boolean" 8368 default: false 8369 tags: ["Image"] 8370 /containers/{id}/exec: 8371 post: 8372 summary: "Create an exec instance" 8373 description: "Run a command inside a running container." 8374 operationId: "ContainerExec" 8375 consumes: 8376 - "application/json" 8377 produces: 8378 - "application/json" 8379 responses: 8380 201: 8381 description: "no error" 8382 schema: 8383 $ref: "#/definitions/IdResponse" 8384 404: 8385 description: "no such container" 8386 schema: 8387 $ref: "#/definitions/ErrorResponse" 8388 examples: 8389 application/json: 8390 message: "No such container: c2ada9df5af8" 8391 409: 8392 description: "container is paused" 8393 schema: 8394 $ref: "#/definitions/ErrorResponse" 8395 500: 8396 description: "Server error" 8397 schema: 8398 $ref: "#/definitions/ErrorResponse" 8399 parameters: 8400 - name: "execConfig" 8401 in: "body" 8402 description: "Exec configuration" 8403 schema: 8404 type: "object" 8405 properties: 8406 AttachStdin: 8407 type: "boolean" 8408 description: "Attach to `stdin` of the exec command." 8409 AttachStdout: 8410 type: "boolean" 8411 description: "Attach to `stdout` of the exec command." 8412 AttachStderr: 8413 type: "boolean" 8414 description: "Attach to `stderr` of the exec command." 8415 DetachKeys: 8416 type: "string" 8417 description: | 8418 Override the key sequence for detaching a container. Format is 8419 a single character `[a-Z]` or `ctrl-<value>` where `<value>` 8420 is one of: `a-z`, `@`, `^`, `[`, `,` or `_`. 8421 Tty: 8422 type: "boolean" 8423 description: "Allocate a pseudo-TTY." 8424 Env: 8425 description: | 8426 A list of environment variables in the form `["VAR=value", ...]`. 8427 type: "array" 8428 items: 8429 type: "string" 8430 Cmd: 8431 type: "array" 8432 description: "Command to run, as a string or array of strings." 8433 items: 8434 type: "string" 8435 Privileged: 8436 type: "boolean" 8437 description: "Runs the exec process with extended privileges." 8438 default: false 8439 User: 8440 type: "string" 8441 description: | 8442 The user, and optionally, group to run the exec process inside 8443 the container. Format is one of: `user`, `user:group`, `uid`, 8444 or `uid:gid`. 8445 WorkingDir: 8446 type: "string" 8447 description: | 8448 The working directory for the exec process inside the container. 8449 example: 8450 AttachStdin: false 8451 AttachStdout: true 8452 AttachStderr: true 8453 DetachKeys: "ctrl-p,ctrl-q" 8454 Tty: false 8455 Cmd: 8456 - "date" 8457 Env: 8458 - "FOO=bar" 8459 - "BAZ=quux" 8460 required: true 8461 - name: "id" 8462 in: "path" 8463 description: "ID or name of container" 8464 type: "string" 8465 required: true 8466 tags: ["Exec"] 8467 /exec/{id}/start: 8468 post: 8469 summary: "Start an exec instance" 8470 description: | 8471 Starts a previously set up exec instance. If detach is true, this endpoint 8472 returns immediately after starting the command. Otherwise, it sets up an 8473 interactive session with the command. 8474 operationId: "ExecStart" 8475 consumes: 8476 - "application/json" 8477 produces: 8478 - "application/vnd.docker.raw-stream" 8479 responses: 8480 200: 8481 description: "No error" 8482 404: 8483 description: "No such exec instance" 8484 schema: 8485 $ref: "#/definitions/ErrorResponse" 8486 409: 8487 description: "Container is stopped or paused" 8488 schema: 8489 $ref: "#/definitions/ErrorResponse" 8490 parameters: 8491 - name: "execStartConfig" 8492 in: "body" 8493 schema: 8494 type: "object" 8495 properties: 8496 Detach: 8497 type: "boolean" 8498 description: "Detach from the command." 8499 Tty: 8500 type: "boolean" 8501 description: "Allocate a pseudo-TTY." 8502 example: 8503 Detach: false 8504 Tty: false 8505 - name: "id" 8506 in: "path" 8507 description: "Exec instance ID" 8508 required: true 8509 type: "string" 8510 tags: ["Exec"] 8511 /exec/{id}/resize: 8512 post: 8513 summary: "Resize an exec instance" 8514 description: | 8515 Resize the TTY session used by an exec instance. This endpoint only works 8516 if `tty` was specified as part of creating and starting the exec instance. 8517 operationId: "ExecResize" 8518 responses: 8519 200: 8520 description: "No error" 8521 400: 8522 description: "bad parameter" 8523 schema: 8524 $ref: "#/definitions/ErrorResponse" 8525 404: 8526 description: "No such exec instance" 8527 schema: 8528 $ref: "#/definitions/ErrorResponse" 8529 500: 8530 description: "Server error" 8531 schema: 8532 $ref: "#/definitions/ErrorResponse" 8533 parameters: 8534 - name: "id" 8535 in: "path" 8536 description: "Exec instance ID" 8537 required: true 8538 type: "string" 8539 - name: "h" 8540 in: "query" 8541 description: "Height of the TTY session in characters" 8542 type: "integer" 8543 - name: "w" 8544 in: "query" 8545 description: "Width of the TTY session in characters" 8546 type: "integer" 8547 tags: ["Exec"] 8548 /exec/{id}/json: 8549 get: 8550 summary: "Inspect an exec instance" 8551 description: "Return low-level information about an exec instance." 8552 operationId: "ExecInspect" 8553 produces: 8554 - "application/json" 8555 responses: 8556 200: 8557 description: "No error" 8558 schema: 8559 type: "object" 8560 title: "ExecInspectResponse" 8561 properties: 8562 CanRemove: 8563 type: "boolean" 8564 DetachKeys: 8565 type: "string" 8566 ID: 8567 type: "string" 8568 Running: 8569 type: "boolean" 8570 ExitCode: 8571 type: "integer" 8572 ProcessConfig: 8573 $ref: "#/definitions/ProcessConfig" 8574 OpenStdin: 8575 type: "boolean" 8576 OpenStderr: 8577 type: "boolean" 8578 OpenStdout: 8579 type: "boolean" 8580 ContainerID: 8581 type: "string" 8582 Pid: 8583 type: "integer" 8584 description: "The system process ID for the exec process." 8585 examples: 8586 application/json: 8587 CanRemove: false 8588 ContainerID: "b53ee82b53a40c7dca428523e34f741f3abc51d9f297a14ff874bf761b995126" 8589 DetachKeys: "" 8590 ExitCode: 2 8591 ID: "f33bbfb39f5b142420f4759b2348913bd4a8d1a6d7fd56499cb41a1bb91d7b3b" 8592 OpenStderr: true 8593 OpenStdin: true 8594 OpenStdout: true 8595 ProcessConfig: 8596 arguments: 8597 - "-c" 8598 - "exit 2" 8599 entrypoint: "sh" 8600 privileged: false 8601 tty: true 8602 user: "1000" 8603 Running: false 8604 Pid: 42000 8605 404: 8606 description: "No such exec instance" 8607 schema: 8608 $ref: "#/definitions/ErrorResponse" 8609 500: 8610 description: "Server error" 8611 schema: 8612 $ref: "#/definitions/ErrorResponse" 8613 parameters: 8614 - name: "id" 8615 in: "path" 8616 description: "Exec instance ID" 8617 required: true 8618 type: "string" 8619 tags: ["Exec"] 8620 8621 /volumes: 8622 get: 8623 summary: "List volumes" 8624 operationId: "VolumeList" 8625 produces: ["application/json"] 8626 responses: 8627 200: 8628 description: "Summary volume data that matches the query" 8629 schema: 8630 $ref: "#/definitions/VolumeListResponse" 8631 500: 8632 description: "Server error" 8633 schema: 8634 $ref: "#/definitions/ErrorResponse" 8635 parameters: 8636 - name: "filters" 8637 in: "query" 8638 description: | 8639 JSON encoded value of the filters (a `map[string][]string`) to 8640 process on the volumes list. Available filters: 8641 8642 - `dangling=<boolean>` When set to `true` (or `1`), returns all 8643 volumes that are not in use by a container. When set to `false` 8644 (or `0`), only volumes that are in use by one or more 8645 containers are returned. 8646 - `driver=<volume-driver-name>` Matches volumes based on their driver. 8647 - `label=<key>` or `label=<key>:<value>` Matches volumes based on 8648 the presence of a `label` alone or a `label` and a value. 8649 - `name=<volume-name>` Matches all or part of a volume name. 8650 type: "string" 8651 format: "json" 8652 tags: ["Volume"] 8653 8654 /volumes/create: 8655 post: 8656 summary: "Create a volume" 8657 operationId: "VolumeCreate" 8658 consumes: ["application/json"] 8659 produces: ["application/json"] 8660 responses: 8661 201: 8662 description: "The volume was created successfully" 8663 schema: 8664 $ref: "#/definitions/Volume" 8665 500: 8666 description: "Server error" 8667 schema: 8668 $ref: "#/definitions/ErrorResponse" 8669 parameters: 8670 - name: "volumeConfig" 8671 in: "body" 8672 required: true 8673 description: "Volume configuration" 8674 schema: 8675 $ref: "#/definitions/VolumeCreateOptions" 8676 tags: ["Volume"] 8677 8678 /volumes/{name}: 8679 get: 8680 summary: "Inspect a volume" 8681 operationId: "VolumeInspect" 8682 produces: ["application/json"] 8683 responses: 8684 200: 8685 description: "No error" 8686 schema: 8687 $ref: "#/definitions/Volume" 8688 404: 8689 description: "No such volume" 8690 schema: 8691 $ref: "#/definitions/ErrorResponse" 8692 500: 8693 description: "Server error" 8694 schema: 8695 $ref: "#/definitions/ErrorResponse" 8696 parameters: 8697 - name: "name" 8698 in: "path" 8699 required: true 8700 description: "Volume name or ID" 8701 type: "string" 8702 tags: ["Volume"] 8703 8704 delete: 8705 summary: "Remove a volume" 8706 description: "Instruct the driver to remove the volume." 8707 operationId: "VolumeDelete" 8708 responses: 8709 204: 8710 description: "The volume was removed" 8711 404: 8712 description: "No such volume or volume driver" 8713 schema: 8714 $ref: "#/definitions/ErrorResponse" 8715 409: 8716 description: "Volume is in use and cannot be removed" 8717 schema: 8718 $ref: "#/definitions/ErrorResponse" 8719 500: 8720 description: "Server error" 8721 schema: 8722 $ref: "#/definitions/ErrorResponse" 8723 parameters: 8724 - name: "name" 8725 in: "path" 8726 required: true 8727 description: "Volume name or ID" 8728 type: "string" 8729 - name: "force" 8730 in: "query" 8731 description: "Force the removal of the volume" 8732 type: "boolean" 8733 default: false 8734 tags: ["Volume"] 8735 /volumes/prune: 8736 post: 8737 summary: "Delete unused volumes" 8738 produces: 8739 - "application/json" 8740 operationId: "VolumePrune" 8741 parameters: 8742 - name: "filters" 8743 in: "query" 8744 description: | 8745 Filters to process on the prune list, encoded as JSON (a `map[string][]string`). 8746 8747 Available filters: 8748 - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune volumes with (or without, in case `label!=...` is used) the specified labels. 8749 type: "string" 8750 responses: 8751 200: 8752 description: "No error" 8753 schema: 8754 type: "object" 8755 title: "VolumePruneResponse" 8756 properties: 8757 VolumesDeleted: 8758 description: "Volumes that were deleted" 8759 type: "array" 8760 items: 8761 type: "string" 8762 SpaceReclaimed: 8763 description: "Disk space reclaimed in bytes" 8764 type: "integer" 8765 format: "int64" 8766 500: 8767 description: "Server error" 8768 schema: 8769 $ref: "#/definitions/ErrorResponse" 8770 tags: ["Volume"] 8771 /networks: 8772 get: 8773 summary: "List networks" 8774 description: | 8775 Returns a list of networks. For details on the format, see the 8776 [network inspect endpoint](#operation/NetworkInspect). 8777 8778 Note that it uses a different, smaller representation of a network than 8779 inspecting a single network. For example, the list of containers attached 8780 to the network is not propagated in API versions 1.28 and up. 8781 operationId: "NetworkList" 8782 produces: 8783 - "application/json" 8784 responses: 8785 200: 8786 description: "No error" 8787 schema: 8788 type: "array" 8789 items: 8790 $ref: "#/definitions/Network" 8791 examples: 8792 application/json: 8793 - Name: "bridge" 8794 Id: "f2de39df4171b0dc801e8002d1d999b77256983dfc63041c0f34030aa3977566" 8795 Created: "2016-10-19T06:21:00.416543526Z" 8796 Scope: "local" 8797 Driver: "bridge" 8798 EnableIPv6: false 8799 Internal: false 8800 Attachable: false 8801 Ingress: false 8802 IPAM: 8803 Driver: "default" 8804 Config: 8805 - 8806 Subnet: "172.17.0.0/16" 8807 Options: 8808 com.docker.network.bridge.default_bridge: "true" 8809 com.docker.network.bridge.enable_icc: "true" 8810 com.docker.network.bridge.enable_ip_masquerade: "true" 8811 com.docker.network.bridge.host_binding_ipv4: "0.0.0.0" 8812 com.docker.network.bridge.name: "docker0" 8813 com.docker.network.driver.mtu: "1500" 8814 - Name: "none" 8815 Id: "e086a3893b05ab69242d3c44e49483a3bbbd3a26b46baa8f61ab797c1088d794" 8816 Created: "0001-01-01T00:00:00Z" 8817 Scope: "local" 8818 Driver: "null" 8819 EnableIPv6: false 8820 Internal: false 8821 Attachable: false 8822 Ingress: false 8823 IPAM: 8824 Driver: "default" 8825 Config: [] 8826 Containers: {} 8827 Options: {} 8828 - Name: "host" 8829 Id: "13e871235c677f196c4e1ecebb9dc733b9b2d2ab589e30c539efeda84a24215e" 8830 Created: "0001-01-01T00:00:00Z" 8831 Scope: "local" 8832 Driver: "host" 8833 EnableIPv6: false 8834 Internal: false 8835 Attachable: false 8836 Ingress: false 8837 IPAM: 8838 Driver: "default" 8839 Config: [] 8840 Containers: {} 8841 Options: {} 8842 500: 8843 description: "Server error" 8844 schema: 8845 $ref: "#/definitions/ErrorResponse" 8846 parameters: 8847 - name: "filters" 8848 in: "query" 8849 description: | 8850 JSON encoded value of the filters (a `map[string][]string`) to process 8851 on the networks list. 8852 8853 Available filters: 8854 8855 - `driver=<driver-name>` Matches a network's driver. 8856 - `id=<network-id>` Matches all or part of a network ID. 8857 - `label=<key>` or `label=<key>=<value>` of a network label. 8858 - `name=<network-name>` Matches all or part of a network name. 8859 - `scope=["swarm"|"global"|"local"]` Filters networks by scope (`swarm`, `global`, or `local`). 8860 - `type=["custom"|"builtin"]` Filters networks by type. The `custom` keyword returns all user-defined networks. 8861 type: "string" 8862 tags: ["Network"] 8863 8864 /networks/{id}: 8865 get: 8866 summary: "Inspect a network" 8867 operationId: "NetworkInspect" 8868 produces: 8869 - "application/json" 8870 responses: 8871 200: 8872 description: "No error" 8873 schema: 8874 $ref: "#/definitions/Network" 8875 404: 8876 description: "Network not found" 8877 schema: 8878 $ref: "#/definitions/ErrorResponse" 8879 500: 8880 description: "Server error" 8881 schema: 8882 $ref: "#/definitions/ErrorResponse" 8883 parameters: 8884 - name: "id" 8885 in: "path" 8886 description: "Network ID or name" 8887 required: true 8888 type: "string" 8889 - name: "verbose" 8890 in: "query" 8891 description: "Detailed inspect output for troubleshooting" 8892 type: "boolean" 8893 default: false 8894 - name: "scope" 8895 in: "query" 8896 description: "Filter the network by scope (swarm, global, or local)" 8897 type: "string" 8898 tags: ["Network"] 8899 8900 delete: 8901 summary: "Remove a network" 8902 operationId: "NetworkDelete" 8903 responses: 8904 204: 8905 description: "No error" 8906 403: 8907 description: "operation not supported for pre-defined networks" 8908 schema: 8909 $ref: "#/definitions/ErrorResponse" 8910 404: 8911 description: "no such network" 8912 schema: 8913 $ref: "#/definitions/ErrorResponse" 8914 500: 8915 description: "Server error" 8916 schema: 8917 $ref: "#/definitions/ErrorResponse" 8918 parameters: 8919 - name: "id" 8920 in: "path" 8921 description: "Network ID or name" 8922 required: true 8923 type: "string" 8924 tags: ["Network"] 8925 8926 /networks/create: 8927 post: 8928 summary: "Create a network" 8929 operationId: "NetworkCreate" 8930 consumes: 8931 - "application/json" 8932 produces: 8933 - "application/json" 8934 responses: 8935 201: 8936 description: "No error" 8937 schema: 8938 type: "object" 8939 title: "NetworkCreateResponse" 8940 properties: 8941 Id: 8942 description: "The ID of the created network." 8943 type: "string" 8944 Warning: 8945 type: "string" 8946 example: 8947 Id: "22be93d5babb089c5aab8dbc369042fad48ff791584ca2da2100db837a1c7c30" 8948 Warning: "" 8949 403: 8950 description: "operation not supported for pre-defined networks" 8951 schema: 8952 $ref: "#/definitions/ErrorResponse" 8953 404: 8954 description: "plugin not found" 8955 schema: 8956 $ref: "#/definitions/ErrorResponse" 8957 500: 8958 description: "Server error" 8959 schema: 8960 $ref: "#/definitions/ErrorResponse" 8961 parameters: 8962 - name: "networkConfig" 8963 in: "body" 8964 description: "Network configuration" 8965 required: true 8966 schema: 8967 type: "object" 8968 required: ["Name"] 8969 properties: 8970 Name: 8971 description: "The network's name." 8972 type: "string" 8973 CheckDuplicate: 8974 description: | 8975 Check for networks with duplicate names. Since Network is 8976 primarily keyed based on a random ID and not on the name, and 8977 network name is strictly a user-friendly alias to the network 8978 which is uniquely identified using ID, there is no guaranteed 8979 way to check for duplicates. CheckDuplicate is there to provide 8980 a best effort checking of any networks which has the same name 8981 but it is not guaranteed to catch all name collisions. 8982 type: "boolean" 8983 Driver: 8984 description: "Name of the network driver plugin to use." 8985 type: "string" 8986 default: "bridge" 8987 Internal: 8988 description: "Restrict external access to the network." 8989 type: "boolean" 8990 Attachable: 8991 description: | 8992 Globally scoped network is manually attachable by regular 8993 containers from workers in swarm mode. 8994 type: "boolean" 8995 Ingress: 8996 description: | 8997 Ingress network is the network which provides the routing-mesh 8998 in swarm mode. 8999 type: "boolean" 9000 IPAM: 9001 description: "Optional custom IP scheme for the network." 9002 $ref: "#/definitions/IPAM" 9003 EnableIPv6: 9004 description: "Enable IPv6 on the network." 9005 type: "boolean" 9006 Options: 9007 description: "Network specific options to be used by the drivers." 9008 type: "object" 9009 additionalProperties: 9010 type: "string" 9011 Labels: 9012 description: "User-defined key/value metadata." 9013 type: "object" 9014 additionalProperties: 9015 type: "string" 9016 example: 9017 Name: "isolated_nw" 9018 CheckDuplicate: false 9019 Driver: "bridge" 9020 EnableIPv6: true 9021 IPAM: 9022 Driver: "default" 9023 Config: 9024 - Subnet: "172.20.0.0/16" 9025 IPRange: "172.20.10.0/24" 9026 Gateway: "172.20.10.11" 9027 - Subnet: "2001:db8:abcd::/64" 9028 Gateway: "2001:db8:abcd::1011" 9029 Options: 9030 foo: "bar" 9031 Internal: true 9032 Attachable: false 9033 Ingress: false 9034 Options: 9035 com.docker.network.bridge.default_bridge: "true" 9036 com.docker.network.bridge.enable_icc: "true" 9037 com.docker.network.bridge.enable_ip_masquerade: "true" 9038 com.docker.network.bridge.host_binding_ipv4: "0.0.0.0" 9039 com.docker.network.bridge.name: "docker0" 9040 com.docker.network.driver.mtu: "1500" 9041 Labels: 9042 com.example.some-label: "some-value" 9043 com.example.some-other-label: "some-other-value" 9044 tags: ["Network"] 9045 9046 /networks/{id}/connect: 9047 post: 9048 summary: "Connect a container to a network" 9049 operationId: "NetworkConnect" 9050 consumes: 9051 - "application/json" 9052 responses: 9053 200: 9054 description: "No error" 9055 403: 9056 description: "Operation not supported for swarm scoped networks" 9057 schema: 9058 $ref: "#/definitions/ErrorResponse" 9059 404: 9060 description: "Network or container not found" 9061 schema: 9062 $ref: "#/definitions/ErrorResponse" 9063 500: 9064 description: "Server error" 9065 schema: 9066 $ref: "#/definitions/ErrorResponse" 9067 parameters: 9068 - name: "id" 9069 in: "path" 9070 description: "Network ID or name" 9071 required: true 9072 type: "string" 9073 - name: "container" 9074 in: "body" 9075 required: true 9076 schema: 9077 type: "object" 9078 properties: 9079 Container: 9080 type: "string" 9081 description: "The ID or name of the container to connect to the network." 9082 EndpointConfig: 9083 $ref: "#/definitions/EndpointSettings" 9084 example: 9085 Container: "3613f73ba0e4" 9086 EndpointConfig: 9087 IPAMConfig: 9088 IPv4Address: "172.24.56.89" 9089 IPv6Address: "2001:db8::5689" 9090 tags: ["Network"] 9091 9092 /networks/{id}/disconnect: 9093 post: 9094 summary: "Disconnect a container from a network" 9095 operationId: "NetworkDisconnect" 9096 consumes: 9097 - "application/json" 9098 responses: 9099 200: 9100 description: "No error" 9101 403: 9102 description: "Operation not supported for swarm scoped networks" 9103 schema: 9104 $ref: "#/definitions/ErrorResponse" 9105 404: 9106 description: "Network or container not found" 9107 schema: 9108 $ref: "#/definitions/ErrorResponse" 9109 500: 9110 description: "Server error" 9111 schema: 9112 $ref: "#/definitions/ErrorResponse" 9113 parameters: 9114 - name: "id" 9115 in: "path" 9116 description: "Network ID or name" 9117 required: true 9118 type: "string" 9119 - name: "container" 9120 in: "body" 9121 required: true 9122 schema: 9123 type: "object" 9124 properties: 9125 Container: 9126 type: "string" 9127 description: | 9128 The ID or name of the container to disconnect from the network. 9129 Force: 9130 type: "boolean" 9131 description: | 9132 Force the container to disconnect from the network. 9133 tags: ["Network"] 9134 /networks/prune: 9135 post: 9136 summary: "Delete unused networks" 9137 produces: 9138 - "application/json" 9139 operationId: "NetworkPrune" 9140 parameters: 9141 - name: "filters" 9142 in: "query" 9143 description: | 9144 Filters to process on the prune list, encoded as JSON (a `map[string][]string`). 9145 9146 Available filters: 9147 - `until=<timestamp>` Prune networks created before this timestamp. The `<timestamp>` can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed relative to the daemon machine’s time. 9148 - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune networks with (or without, in case `label!=...` is used) the specified labels. 9149 type: "string" 9150 responses: 9151 200: 9152 description: "No error" 9153 schema: 9154 type: "object" 9155 title: "NetworkPruneResponse" 9156 properties: 9157 NetworksDeleted: 9158 description: "Networks that were deleted" 9159 type: "array" 9160 items: 9161 type: "string" 9162 500: 9163 description: "Server error" 9164 schema: 9165 $ref: "#/definitions/ErrorResponse" 9166 tags: ["Network"] 9167 /plugins: 9168 get: 9169 summary: "List plugins" 9170 operationId: "PluginList" 9171 description: "Returns information about installed plugins." 9172 produces: ["application/json"] 9173 responses: 9174 200: 9175 description: "No error" 9176 schema: 9177 type: "array" 9178 items: 9179 $ref: "#/definitions/Plugin" 9180 500: 9181 description: "Server error" 9182 schema: 9183 $ref: "#/definitions/ErrorResponse" 9184 parameters: 9185 - name: "filters" 9186 in: "query" 9187 type: "string" 9188 description: | 9189 A JSON encoded value of the filters (a `map[string][]string`) to 9190 process on the plugin list. 9191 9192 Available filters: 9193 9194 - `capability=<capability name>` 9195 - `enable=<true>|<false>` 9196 tags: ["Plugin"] 9197 9198 /plugins/privileges: 9199 get: 9200 summary: "Get plugin privileges" 9201 operationId: "GetPluginPrivileges" 9202 responses: 9203 200: 9204 description: "no error" 9205 schema: 9206 type: "array" 9207 items: 9208 description: | 9209 Describes a permission the user has to accept upon installing 9210 the plugin. 9211 type: "object" 9212 title: "PluginPrivilegeItem" 9213 properties: 9214 Name: 9215 type: "string" 9216 Description: 9217 type: "string" 9218 Value: 9219 type: "array" 9220 items: 9221 type: "string" 9222 example: 9223 - Name: "network" 9224 Description: "" 9225 Value: 9226 - "host" 9227 - Name: "mount" 9228 Description: "" 9229 Value: 9230 - "/data" 9231 - Name: "device" 9232 Description: "" 9233 Value: 9234 - "/dev/cpu_dma_latency" 9235 500: 9236 description: "server error" 9237 schema: 9238 $ref: "#/definitions/ErrorResponse" 9239 parameters: 9240 - name: "remote" 9241 in: "query" 9242 description: | 9243 The name of the plugin. The `:latest` tag is optional, and is the 9244 default if omitted. 9245 required: true 9246 type: "string" 9247 tags: 9248 - "Plugin" 9249 9250 /plugins/pull: 9251 post: 9252 summary: "Install a plugin" 9253 operationId: "PluginPull" 9254 description: | 9255 Pulls and installs a plugin. After the plugin is installed, it can be 9256 enabled using the [`POST /plugins/{name}/enable` endpoint](#operation/PostPluginsEnable). 9257 produces: 9258 - "application/json" 9259 responses: 9260 204: 9261 description: "no error" 9262 500: 9263 description: "server error" 9264 schema: 9265 $ref: "#/definitions/ErrorResponse" 9266 parameters: 9267 - name: "remote" 9268 in: "query" 9269 description: | 9270 Remote reference for plugin to install. 9271 9272 The `:latest` tag is optional, and is used as the default if omitted. 9273 required: true 9274 type: "string" 9275 - name: "name" 9276 in: "query" 9277 description: | 9278 Local name for the pulled plugin. 9279 9280 The `:latest` tag is optional, and is used as the default if omitted. 9281 required: false 9282 type: "string" 9283 - name: "X-Registry-Auth" 9284 in: "header" 9285 description: | 9286 A base64url-encoded auth configuration to use when pulling a plugin 9287 from a registry. 9288 9289 Refer to the [authentication section](#section/Authentication) for 9290 details. 9291 type: "string" 9292 - name: "body" 9293 in: "body" 9294 schema: 9295 type: "array" 9296 items: 9297 description: | 9298 Describes a permission accepted by the user upon installing the 9299 plugin. 9300 type: "object" 9301 properties: 9302 Name: 9303 type: "string" 9304 Description: 9305 type: "string" 9306 Value: 9307 type: "array" 9308 items: 9309 type: "string" 9310 example: 9311 - Name: "network" 9312 Description: "" 9313 Value: 9314 - "host" 9315 - Name: "mount" 9316 Description: "" 9317 Value: 9318 - "/data" 9319 - Name: "device" 9320 Description: "" 9321 Value: 9322 - "/dev/cpu_dma_latency" 9323 tags: ["Plugin"] 9324 /plugins/{name}/json: 9325 get: 9326 summary: "Inspect a plugin" 9327 operationId: "PluginInspect" 9328 responses: 9329 200: 9330 description: "no error" 9331 schema: 9332 $ref: "#/definitions/Plugin" 9333 404: 9334 description: "plugin is not installed" 9335 schema: 9336 $ref: "#/definitions/ErrorResponse" 9337 500: 9338 description: "server error" 9339 schema: 9340 $ref: "#/definitions/ErrorResponse" 9341 parameters: 9342 - name: "name" 9343 in: "path" 9344 description: | 9345 The name of the plugin. The `:latest` tag is optional, and is the 9346 default if omitted. 9347 required: true 9348 type: "string" 9349 tags: ["Plugin"] 9350 /plugins/{name}: 9351 delete: 9352 summary: "Remove a plugin" 9353 operationId: "PluginDelete" 9354 responses: 9355 200: 9356 description: "no error" 9357 schema: 9358 $ref: "#/definitions/Plugin" 9359 404: 9360 description: "plugin is not installed" 9361 schema: 9362 $ref: "#/definitions/ErrorResponse" 9363 500: 9364 description: "server error" 9365 schema: 9366 $ref: "#/definitions/ErrorResponse" 9367 parameters: 9368 - name: "name" 9369 in: "path" 9370 description: | 9371 The name of the plugin. The `:latest` tag is optional, and is the 9372 default if omitted. 9373 required: true 9374 type: "string" 9375 - name: "force" 9376 in: "query" 9377 description: | 9378 Disable the plugin before removing. This may result in issues if the 9379 plugin is in use by a container. 9380 type: "boolean" 9381 default: false 9382 tags: ["Plugin"] 9383 /plugins/{name}/enable: 9384 post: 9385 summary: "Enable a plugin" 9386 operationId: "PluginEnable" 9387 responses: 9388 200: 9389 description: "no error" 9390 404: 9391 description: "plugin is not installed" 9392 schema: 9393 $ref: "#/definitions/ErrorResponse" 9394 500: 9395 description: "server error" 9396 schema: 9397 $ref: "#/definitions/ErrorResponse" 9398 parameters: 9399 - name: "name" 9400 in: "path" 9401 description: | 9402 The name of the plugin. The `:latest` tag is optional, and is the 9403 default if omitted. 9404 required: true 9405 type: "string" 9406 - name: "timeout" 9407 in: "query" 9408 description: "Set the HTTP client timeout (in seconds)" 9409 type: "integer" 9410 default: 0 9411 tags: ["Plugin"] 9412 /plugins/{name}/disable: 9413 post: 9414 summary: "Disable a plugin" 9415 operationId: "PluginDisable" 9416 responses: 9417 200: 9418 description: "no error" 9419 404: 9420 description: "plugin is not installed" 9421 schema: 9422 $ref: "#/definitions/ErrorResponse" 9423 500: 9424 description: "server error" 9425 schema: 9426 $ref: "#/definitions/ErrorResponse" 9427 parameters: 9428 - name: "name" 9429 in: "path" 9430 description: | 9431 The name of the plugin. The `:latest` tag is optional, and is the 9432 default if omitted. 9433 required: true 9434 type: "string" 9435 tags: ["Plugin"] 9436 /plugins/{name}/upgrade: 9437 post: 9438 summary: "Upgrade a plugin" 9439 operationId: "PluginUpgrade" 9440 responses: 9441 204: 9442 description: "no error" 9443 404: 9444 description: "plugin not installed" 9445 schema: 9446 $ref: "#/definitions/ErrorResponse" 9447 500: 9448 description: "server error" 9449 schema: 9450 $ref: "#/definitions/ErrorResponse" 9451 parameters: 9452 - name: "name" 9453 in: "path" 9454 description: | 9455 The name of the plugin. The `:latest` tag is optional, and is the 9456 default if omitted. 9457 required: true 9458 type: "string" 9459 - name: "remote" 9460 in: "query" 9461 description: | 9462 Remote reference to upgrade to. 9463 9464 The `:latest` tag is optional, and is used as the default if omitted. 9465 required: true 9466 type: "string" 9467 - name: "X-Registry-Auth" 9468 in: "header" 9469 description: | 9470 A base64url-encoded auth configuration to use when pulling a plugin 9471 from a registry. 9472 9473 Refer to the [authentication section](#section/Authentication) for 9474 details. 9475 type: "string" 9476 - name: "body" 9477 in: "body" 9478 schema: 9479 type: "array" 9480 items: 9481 description: | 9482 Describes a permission accepted by the user upon installing the 9483 plugin. 9484 type: "object" 9485 properties: 9486 Name: 9487 type: "string" 9488 Description: 9489 type: "string" 9490 Value: 9491 type: "array" 9492 items: 9493 type: "string" 9494 example: 9495 - Name: "network" 9496 Description: "" 9497 Value: 9498 - "host" 9499 - Name: "mount" 9500 Description: "" 9501 Value: 9502 - "/data" 9503 - Name: "device" 9504 Description: "" 9505 Value: 9506 - "/dev/cpu_dma_latency" 9507 tags: ["Plugin"] 9508 /plugins/create: 9509 post: 9510 summary: "Create a plugin" 9511 operationId: "PluginCreate" 9512 consumes: 9513 - "application/x-tar" 9514 responses: 9515 204: 9516 description: "no error" 9517 500: 9518 description: "server error" 9519 schema: 9520 $ref: "#/definitions/ErrorResponse" 9521 parameters: 9522 - name: "name" 9523 in: "query" 9524 description: | 9525 The name of the plugin. The `:latest` tag is optional, and is the 9526 default if omitted. 9527 required: true 9528 type: "string" 9529 - name: "tarContext" 9530 in: "body" 9531 description: "Path to tar containing plugin rootfs and manifest" 9532 schema: 9533 type: "string" 9534 format: "binary" 9535 tags: ["Plugin"] 9536 /plugins/{name}/push: 9537 post: 9538 summary: "Push a plugin" 9539 operationId: "PluginPush" 9540 description: | 9541 Push a plugin to the registry. 9542 parameters: 9543 - name: "name" 9544 in: "path" 9545 description: | 9546 The name of the plugin. The `:latest` tag is optional, and is the 9547 default if omitted. 9548 required: true 9549 type: "string" 9550 responses: 9551 200: 9552 description: "no error" 9553 404: 9554 description: "plugin not installed" 9555 schema: 9556 $ref: "#/definitions/ErrorResponse" 9557 500: 9558 description: "server error" 9559 schema: 9560 $ref: "#/definitions/ErrorResponse" 9561 tags: ["Plugin"] 9562 /plugins/{name}/set: 9563 post: 9564 summary: "Configure a plugin" 9565 operationId: "PluginSet" 9566 consumes: 9567 - "application/json" 9568 parameters: 9569 - name: "name" 9570 in: "path" 9571 description: | 9572 The name of the plugin. The `:latest` tag is optional, and is the 9573 default if omitted. 9574 required: true 9575 type: "string" 9576 - name: "body" 9577 in: "body" 9578 schema: 9579 type: "array" 9580 items: 9581 type: "string" 9582 example: ["DEBUG=1"] 9583 responses: 9584 204: 9585 description: "No error" 9586 404: 9587 description: "Plugin not installed" 9588 schema: 9589 $ref: "#/definitions/ErrorResponse" 9590 500: 9591 description: "Server error" 9592 schema: 9593 $ref: "#/definitions/ErrorResponse" 9594 tags: ["Plugin"] 9595 /nodes: 9596 get: 9597 summary: "List nodes" 9598 operationId: "NodeList" 9599 responses: 9600 200: 9601 description: "no error" 9602 schema: 9603 type: "array" 9604 items: 9605 $ref: "#/definitions/Node" 9606 500: 9607 description: "server error" 9608 schema: 9609 $ref: "#/definitions/ErrorResponse" 9610 503: 9611 description: "node is not part of a swarm" 9612 schema: 9613 $ref: "#/definitions/ErrorResponse" 9614 parameters: 9615 - name: "filters" 9616 in: "query" 9617 description: | 9618 Filters to process on the nodes list, encoded as JSON (a `map[string][]string`). 9619 9620 Available filters: 9621 - `id=<node id>` 9622 - `label=<engine label>` 9623 - `membership=`(`accepted`|`pending`)` 9624 - `name=<node name>` 9625 - `role=`(`manager`|`worker`)` 9626 type: "string" 9627 tags: ["Node"] 9628 /nodes/{id}: 9629 get: 9630 summary: "Inspect a node" 9631 operationId: "NodeInspect" 9632 responses: 9633 200: 9634 description: "no error" 9635 schema: 9636 $ref: "#/definitions/Node" 9637 404: 9638 description: "no such node" 9639 schema: 9640 $ref: "#/definitions/ErrorResponse" 9641 500: 9642 description: "server error" 9643 schema: 9644 $ref: "#/definitions/ErrorResponse" 9645 503: 9646 description: "node is not part of a swarm" 9647 schema: 9648 $ref: "#/definitions/ErrorResponse" 9649 parameters: 9650 - name: "id" 9651 in: "path" 9652 description: "The ID or name of the node" 9653 type: "string" 9654 required: true 9655 tags: ["Node"] 9656 delete: 9657 summary: "Delete a node" 9658 operationId: "NodeDelete" 9659 responses: 9660 200: 9661 description: "no error" 9662 404: 9663 description: "no such node" 9664 schema: 9665 $ref: "#/definitions/ErrorResponse" 9666 500: 9667 description: "server error" 9668 schema: 9669 $ref: "#/definitions/ErrorResponse" 9670 503: 9671 description: "node is not part of a swarm" 9672 schema: 9673 $ref: "#/definitions/ErrorResponse" 9674 parameters: 9675 - name: "id" 9676 in: "path" 9677 description: "The ID or name of the node" 9678 type: "string" 9679 required: true 9680 - name: "force" 9681 in: "query" 9682 description: "Force remove a node from the swarm" 9683 default: false 9684 type: "boolean" 9685 tags: ["Node"] 9686 /nodes/{id}/update: 9687 post: 9688 summary: "Update a node" 9689 operationId: "NodeUpdate" 9690 responses: 9691 200: 9692 description: "no error" 9693 400: 9694 description: "bad parameter" 9695 schema: 9696 $ref: "#/definitions/ErrorResponse" 9697 404: 9698 description: "no such node" 9699 schema: 9700 $ref: "#/definitions/ErrorResponse" 9701 500: 9702 description: "server error" 9703 schema: 9704 $ref: "#/definitions/ErrorResponse" 9705 503: 9706 description: "node is not part of a swarm" 9707 schema: 9708 $ref: "#/definitions/ErrorResponse" 9709 parameters: 9710 - name: "id" 9711 in: "path" 9712 description: "The ID of the node" 9713 type: "string" 9714 required: true 9715 - name: "body" 9716 in: "body" 9717 schema: 9718 $ref: "#/definitions/NodeSpec" 9719 - name: "version" 9720 in: "query" 9721 description: | 9722 The version number of the node object being updated. This is required 9723 to avoid conflicting writes. 9724 type: "integer" 9725 format: "int64" 9726 required: true 9727 tags: ["Node"] 9728 /swarm: 9729 get: 9730 summary: "Inspect swarm" 9731 operationId: "SwarmInspect" 9732 responses: 9733 200: 9734 description: "no error" 9735 schema: 9736 $ref: "#/definitions/Swarm" 9737 404: 9738 description: "no such swarm" 9739 schema: 9740 $ref: "#/definitions/ErrorResponse" 9741 500: 9742 description: "server error" 9743 schema: 9744 $ref: "#/definitions/ErrorResponse" 9745 503: 9746 description: "node is not part of a swarm" 9747 schema: 9748 $ref: "#/definitions/ErrorResponse" 9749 tags: ["Swarm"] 9750 /swarm/init: 9751 post: 9752 summary: "Initialize a new swarm" 9753 operationId: "SwarmInit" 9754 produces: 9755 - "application/json" 9756 - "text/plain" 9757 responses: 9758 200: 9759 description: "no error" 9760 schema: 9761 description: "The node ID" 9762 type: "string" 9763 example: "7v2t30z9blmxuhnyo6s4cpenp" 9764 400: 9765 description: "bad parameter" 9766 schema: 9767 $ref: "#/definitions/ErrorResponse" 9768 500: 9769 description: "server error" 9770 schema: 9771 $ref: "#/definitions/ErrorResponse" 9772 503: 9773 description: "node is already part of a swarm" 9774 schema: 9775 $ref: "#/definitions/ErrorResponse" 9776 parameters: 9777 - name: "body" 9778 in: "body" 9779 required: true 9780 schema: 9781 type: "object" 9782 properties: 9783 ListenAddr: 9784 description: | 9785 Listen address used for inter-manager communication, as well 9786 as determining the networking interface used for the VXLAN 9787 Tunnel Endpoint (VTEP). This can either be an address/port 9788 combination in the form `192.168.1.1:4567`, or an interface 9789 followed by a port number, like `eth0:4567`. If the port number 9790 is omitted, the default swarm listening port is used. 9791 type: "string" 9792 AdvertiseAddr: 9793 description: | 9794 Externally reachable address advertised to other nodes. This 9795 can either be an address/port combination in the form 9796 `192.168.1.1:4567`, or an interface followed by a port number, 9797 like `eth0:4567`. If the port number is omitted, the port 9798 number from the listen address is used. If `AdvertiseAddr` is 9799 not specified, it will be automatically detected when possible. 9800 type: "string" 9801 DataPathAddr: 9802 description: | 9803 Address or interface to use for data path traffic (format: 9804 `<ip|interface>`), for example, `192.168.1.1`, or an interface, 9805 like `eth0`. If `DataPathAddr` is unspecified, the same address 9806 as `AdvertiseAddr` is used. 9807 9808 The `DataPathAddr` specifies the address that global scope 9809 network drivers will publish towards other nodes in order to 9810 reach the containers running on this node. Using this parameter 9811 it is possible to separate the container data traffic from the 9812 management traffic of the cluster. 9813 type: "string" 9814 DefaultAddrPool: 9815 description: | 9816 Default Address Pool specifies default subnet pools for global 9817 scope networks. 9818 type: "array" 9819 items: 9820 type: "string" 9821 example: ["10.10.0.0/16", "20.20.0.0/16"] 9822 ForceNewCluster: 9823 description: "Force creation of a new swarm." 9824 type: "boolean" 9825 SubnetSize: 9826 description: | 9827 SubnetSize specifies the subnet size of the networks created 9828 from the default subnet pool. 9829 type: "integer" 9830 format: "uint32" 9831 Spec: 9832 $ref: "#/definitions/SwarmSpec" 9833 example: 9834 ListenAddr: "0.0.0.0:2377" 9835 AdvertiseAddr: "192.168.1.1:2377" 9836 DefaultAddrPool: ["10.10.0.0/8", "20.20.0.0/8"] 9837 SubnetSize: 24 9838 ForceNewCluster: false 9839 Spec: 9840 Orchestration: {} 9841 Raft: {} 9842 Dispatcher: {} 9843 CAConfig: {} 9844 EncryptionConfig: 9845 AutoLockManagers: false 9846 tags: ["Swarm"] 9847 /swarm/join: 9848 post: 9849 summary: "Join an existing swarm" 9850 operationId: "SwarmJoin" 9851 responses: 9852 200: 9853 description: "no error" 9854 400: 9855 description: "bad parameter" 9856 schema: 9857 $ref: "#/definitions/ErrorResponse" 9858 500: 9859 description: "server error" 9860 schema: 9861 $ref: "#/definitions/ErrorResponse" 9862 503: 9863 description: "node is already part of a swarm" 9864 schema: 9865 $ref: "#/definitions/ErrorResponse" 9866 parameters: 9867 - name: "body" 9868 in: "body" 9869 required: true 9870 schema: 9871 type: "object" 9872 properties: 9873 ListenAddr: 9874 description: | 9875 Listen address used for inter-manager communication if the node 9876 gets promoted to manager, as well as determining the networking 9877 interface used for the VXLAN Tunnel Endpoint (VTEP). 9878 type: "string" 9879 AdvertiseAddr: 9880 description: | 9881 Externally reachable address advertised to other nodes. This 9882 can either be an address/port combination in the form 9883 `192.168.1.1:4567`, or an interface followed by a port number, 9884 like `eth0:4567`. If the port number is omitted, the port 9885 number from the listen address is used. If `AdvertiseAddr` is 9886 not specified, it will be automatically detected when possible. 9887 type: "string" 9888 DataPathAddr: 9889 description: | 9890 Address or interface to use for data path traffic (format: 9891 `<ip|interface>`), for example, `192.168.1.1`, or an interface, 9892 like `eth0`. If `DataPathAddr` is unspecified, the same address 9893 as `AdvertiseAddr` is used. 9894 9895 The `DataPathAddr` specifies the address that global scope 9896 network drivers will publish towards other nodes in order to 9897 reach the containers running on this node. Using this parameter 9898 it is possible to separate the container data traffic from the 9899 management traffic of the cluster. 9900 9901 type: "string" 9902 RemoteAddrs: 9903 description: | 9904 Addresses of manager nodes already participating in the swarm. 9905 type: "array" 9906 items: 9907 type: "string" 9908 JoinToken: 9909 description: "Secret token for joining this swarm." 9910 type: "string" 9911 example: 9912 ListenAddr: "0.0.0.0:2377" 9913 AdvertiseAddr: "192.168.1.1:2377" 9914 RemoteAddrs: 9915 - "node1:2377" 9916 JoinToken: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-7p73s1dx5in4tatdymyhg9hu2" 9917 tags: ["Swarm"] 9918 /swarm/leave: 9919 post: 9920 summary: "Leave a swarm" 9921 operationId: "SwarmLeave" 9922 responses: 9923 200: 9924 description: "no error" 9925 500: 9926 description: "server error" 9927 schema: 9928 $ref: "#/definitions/ErrorResponse" 9929 503: 9930 description: "node is not part of a swarm" 9931 schema: 9932 $ref: "#/definitions/ErrorResponse" 9933 parameters: 9934 - name: "force" 9935 description: | 9936 Force leave swarm, even if this is the last manager or that it will 9937 break the cluster. 9938 in: "query" 9939 type: "boolean" 9940 default: false 9941 tags: ["Swarm"] 9942 /swarm/update: 9943 post: 9944 summary: "Update a swarm" 9945 operationId: "SwarmUpdate" 9946 responses: 9947 200: 9948 description: "no error" 9949 400: 9950 description: "bad parameter" 9951 schema: 9952 $ref: "#/definitions/ErrorResponse" 9953 500: 9954 description: "server error" 9955 schema: 9956 $ref: "#/definitions/ErrorResponse" 9957 503: 9958 description: "node is not part of a swarm" 9959 schema: 9960 $ref: "#/definitions/ErrorResponse" 9961 parameters: 9962 - name: "body" 9963 in: "body" 9964 required: true 9965 schema: 9966 $ref: "#/definitions/SwarmSpec" 9967 - name: "version" 9968 in: "query" 9969 description: | 9970 The version number of the swarm object being updated. This is 9971 required to avoid conflicting writes. 9972 type: "integer" 9973 format: "int64" 9974 required: true 9975 - name: "rotateWorkerToken" 9976 in: "query" 9977 description: "Rotate the worker join token." 9978 type: "boolean" 9979 default: false 9980 - name: "rotateManagerToken" 9981 in: "query" 9982 description: "Rotate the manager join token." 9983 type: "boolean" 9984 default: false 9985 - name: "rotateManagerUnlockKey" 9986 in: "query" 9987 description: "Rotate the manager unlock key." 9988 type: "boolean" 9989 default: false 9990 tags: ["Swarm"] 9991 /swarm/unlockkey: 9992 get: 9993 summary: "Get the unlock key" 9994 operationId: "SwarmUnlockkey" 9995 consumes: 9996 - "application/json" 9997 responses: 9998 200: 9999 description: "no error" 10000 schema: 10001 type: "object" 10002 title: "UnlockKeyResponse" 10003 properties: 10004 UnlockKey: 10005 description: "The swarm's unlock key." 10006 type: "string" 10007 example: 10008 UnlockKey: "SWMKEY-1-7c37Cc8654o6p38HnroywCi19pllOnGtbdZEgtKxZu8" 10009 500: 10010 description: "server error" 10011 schema: 10012 $ref: "#/definitions/ErrorResponse" 10013 503: 10014 description: "node is not part of a swarm" 10015 schema: 10016 $ref: "#/definitions/ErrorResponse" 10017 tags: ["Swarm"] 10018 /swarm/unlock: 10019 post: 10020 summary: "Unlock a locked manager" 10021 operationId: "SwarmUnlock" 10022 consumes: 10023 - "application/json" 10024 produces: 10025 - "application/json" 10026 parameters: 10027 - name: "body" 10028 in: "body" 10029 required: true 10030 schema: 10031 type: "object" 10032 properties: 10033 UnlockKey: 10034 description: "The swarm's unlock key." 10035 type: "string" 10036 example: 10037 UnlockKey: "SWMKEY-1-7c37Cc8654o6p38HnroywCi19pllOnGtbdZEgtKxZu8" 10038 responses: 10039 200: 10040 description: "no error" 10041 500: 10042 description: "server error" 10043 schema: 10044 $ref: "#/definitions/ErrorResponse" 10045 503: 10046 description: "node is not part of a swarm" 10047 schema: 10048 $ref: "#/definitions/ErrorResponse" 10049 tags: ["Swarm"] 10050 /services: 10051 get: 10052 summary: "List services" 10053 operationId: "ServiceList" 10054 responses: 10055 200: 10056 description: "no error" 10057 schema: 10058 type: "array" 10059 items: 10060 $ref: "#/definitions/Service" 10061 500: 10062 description: "server error" 10063 schema: 10064 $ref: "#/definitions/ErrorResponse" 10065 503: 10066 description: "node is not part of a swarm" 10067 schema: 10068 $ref: "#/definitions/ErrorResponse" 10069 parameters: 10070 - name: "filters" 10071 in: "query" 10072 type: "string" 10073 description: | 10074 A JSON encoded value of the filters (a `map[string][]string`) to 10075 process on the services list. 10076 10077 Available filters: 10078 10079 - `id=<service id>` 10080 - `label=<service label>` 10081 - `mode=["replicated"|"global"]` 10082 - `name=<service name>` 10083 tags: ["Service"] 10084 /services/create: 10085 post: 10086 summary: "Create a service" 10087 operationId: "ServiceCreate" 10088 consumes: 10089 - "application/json" 10090 produces: 10091 - "application/json" 10092 responses: 10093 201: 10094 description: "no error" 10095 schema: 10096 type: "object" 10097 title: "ServiceCreateResponse" 10098 properties: 10099 ID: 10100 description: "The ID of the created service." 10101 type: "string" 10102 Warning: 10103 description: "Optional warning message" 10104 type: "string" 10105 example: 10106 ID: "ak7w3gjqoa3kuz8xcpnyy0pvl" 10107 Warning: "unable to pin image doesnotexist:latest to digest: image library/doesnotexist:latest not found" 10108 400: 10109 description: "bad parameter" 10110 schema: 10111 $ref: "#/definitions/ErrorResponse" 10112 403: 10113 description: "network is not eligible for services" 10114 schema: 10115 $ref: "#/definitions/ErrorResponse" 10116 409: 10117 description: "name conflicts with an existing service" 10118 schema: 10119 $ref: "#/definitions/ErrorResponse" 10120 500: 10121 description: "server error" 10122 schema: 10123 $ref: "#/definitions/ErrorResponse" 10124 503: 10125 description: "node is not part of a swarm" 10126 schema: 10127 $ref: "#/definitions/ErrorResponse" 10128 parameters: 10129 - name: "body" 10130 in: "body" 10131 required: true 10132 schema: 10133 allOf: 10134 - $ref: "#/definitions/ServiceSpec" 10135 - type: "object" 10136 example: 10137 Name: "web" 10138 TaskTemplate: 10139 ContainerSpec: 10140 Image: "nginx:alpine" 10141 Mounts: 10142 - 10143 ReadOnly: true 10144 Source: "web-data" 10145 Target: "/usr/share/nginx/html" 10146 Type: "volume" 10147 VolumeOptions: 10148 DriverConfig: {} 10149 Labels: 10150 com.example.something: "something-value" 10151 Hosts: ["10.10.10.10 host1", "ABCD:EF01:2345:6789:ABCD:EF01:2345:6789 host2"] 10152 User: "33" 10153 DNSConfig: 10154 Nameservers: ["8.8.8.8"] 10155 Search: ["example.org"] 10156 Options: ["timeout:3"] 10157 Secrets: 10158 - 10159 File: 10160 Name: "www.example.org.key" 10161 UID: "33" 10162 GID: "33" 10163 Mode: 384 10164 SecretID: "fpjqlhnwb19zds35k8wn80lq9" 10165 SecretName: "example_org_domain_key" 10166 LogDriver: 10167 Name: "json-file" 10168 Options: 10169 max-file: "3" 10170 max-size: "10M" 10171 Placement: {} 10172 Resources: 10173 Limits: 10174 MemoryBytes: 104857600 10175 Reservations: {} 10176 RestartPolicy: 10177 Condition: "on-failure" 10178 Delay: 10000000000 10179 MaxAttempts: 10 10180 Mode: 10181 Replicated: 10182 Replicas: 4 10183 UpdateConfig: 10184 Parallelism: 2 10185 Delay: 1000000000 10186 FailureAction: "pause" 10187 Monitor: 15000000000 10188 MaxFailureRatio: 0.15 10189 RollbackConfig: 10190 Parallelism: 1 10191 Delay: 1000000000 10192 FailureAction: "pause" 10193 Monitor: 15000000000 10194 MaxFailureRatio: 0.15 10195 EndpointSpec: 10196 Ports: 10197 - 10198 Protocol: "tcp" 10199 PublishedPort: 8080 10200 TargetPort: 80 10201 Labels: 10202 foo: "bar" 10203 - name: "X-Registry-Auth" 10204 in: "header" 10205 description: | 10206 A base64url-encoded auth configuration for pulling from private 10207 registries. 10208 10209 Refer to the [authentication section](#section/Authentication) for 10210 details. 10211 type: "string" 10212 tags: ["Service"] 10213 /services/{id}: 10214 get: 10215 summary: "Inspect a service" 10216 operationId: "ServiceInspect" 10217 responses: 10218 200: 10219 description: "no error" 10220 schema: 10221 $ref: "#/definitions/Service" 10222 404: 10223 description: "no such service" 10224 schema: 10225 $ref: "#/definitions/ErrorResponse" 10226 500: 10227 description: "server error" 10228 schema: 10229 $ref: "#/definitions/ErrorResponse" 10230 503: 10231 description: "node is not part of a swarm" 10232 schema: 10233 $ref: "#/definitions/ErrorResponse" 10234 parameters: 10235 - name: "id" 10236 in: "path" 10237 description: "ID or name of service." 10238 required: true 10239 type: "string" 10240 - name: "insertDefaults" 10241 in: "query" 10242 description: "Fill empty fields with default values." 10243 type: "boolean" 10244 default: false 10245 tags: ["Service"] 10246 delete: 10247 summary: "Delete a service" 10248 operationId: "ServiceDelete" 10249 responses: 10250 200: 10251 description: "no error" 10252 404: 10253 description: "no such service" 10254 schema: 10255 $ref: "#/definitions/ErrorResponse" 10256 500: 10257 description: "server error" 10258 schema: 10259 $ref: "#/definitions/ErrorResponse" 10260 503: 10261 description: "node is not part of a swarm" 10262 schema: 10263 $ref: "#/definitions/ErrorResponse" 10264 parameters: 10265 - name: "id" 10266 in: "path" 10267 description: "ID or name of service." 10268 required: true 10269 type: "string" 10270 tags: ["Service"] 10271 /services/{id}/update: 10272 post: 10273 summary: "Update a service" 10274 operationId: "ServiceUpdate" 10275 consumes: ["application/json"] 10276 produces: ["application/json"] 10277 responses: 10278 200: 10279 description: "no error" 10280 schema: 10281 $ref: "#/definitions/ServiceUpdateResponse" 10282 400: 10283 description: "bad parameter" 10284 schema: 10285 $ref: "#/definitions/ErrorResponse" 10286 404: 10287 description: "no such service" 10288 schema: 10289 $ref: "#/definitions/ErrorResponse" 10290 500: 10291 description: "server error" 10292 schema: 10293 $ref: "#/definitions/ErrorResponse" 10294 503: 10295 description: "node is not part of a swarm" 10296 schema: 10297 $ref: "#/definitions/ErrorResponse" 10298 parameters: 10299 - name: "id" 10300 in: "path" 10301 description: "ID or name of service." 10302 required: true 10303 type: "string" 10304 - name: "body" 10305 in: "body" 10306 required: true 10307 schema: 10308 allOf: 10309 - $ref: "#/definitions/ServiceSpec" 10310 - type: "object" 10311 example: 10312 Name: "top" 10313 TaskTemplate: 10314 ContainerSpec: 10315 Image: "busybox" 10316 Args: 10317 - "top" 10318 Resources: 10319 Limits: {} 10320 Reservations: {} 10321 RestartPolicy: 10322 Condition: "any" 10323 MaxAttempts: 0 10324 Placement: {} 10325 ForceUpdate: 0 10326 Mode: 10327 Replicated: 10328 Replicas: 1 10329 UpdateConfig: 10330 Parallelism: 2 10331 Delay: 1000000000 10332 FailureAction: "pause" 10333 Monitor: 15000000000 10334 MaxFailureRatio: 0.15 10335 RollbackConfig: 10336 Parallelism: 1 10337 Delay: 1000000000 10338 FailureAction: "pause" 10339 Monitor: 15000000000 10340 MaxFailureRatio: 0.15 10341 EndpointSpec: 10342 Mode: "vip" 10343 10344 - name: "version" 10345 in: "query" 10346 description: | 10347 The version number of the service object being updated. This is 10348 required to avoid conflicting writes. 10349 This version number should be the value as currently set on the 10350 service *before* the update. You can find the current version by 10351 calling `GET /services/{id}` 10352 required: true 10353 type: "integer" 10354 - name: "registryAuthFrom" 10355 in: "query" 10356 description: | 10357 If the `X-Registry-Auth` header is not specified, this parameter 10358 indicates where to find registry authorization credentials. 10359 type: "string" 10360 enum: ["spec", "previous-spec"] 10361 default: "spec" 10362 - name: "rollback" 10363 in: "query" 10364 description: | 10365 Set to this parameter to `previous` to cause a server-side rollback 10366 to the previous service spec. The supplied spec will be ignored in 10367 this case. 10368 type: "string" 10369 - name: "X-Registry-Auth" 10370 in: "header" 10371 description: | 10372 A base64url-encoded auth configuration for pulling from private 10373 registries. 10374 10375 Refer to the [authentication section](#section/Authentication) for 10376 details. 10377 type: "string" 10378 10379 tags: ["Service"] 10380 /services/{id}/logs: 10381 get: 10382 summary: "Get service logs" 10383 description: | 10384 Get `stdout` and `stderr` logs from a service. See also 10385 [`/containers/{id}/logs`](#operation/ContainerLogs). 10386 10387 **Note**: This endpoint works only for services with the `json-file` or 10388 `journald` logging drivers. 10389 operationId: "ServiceLogs" 10390 produces: 10391 - "application/vnd.docker.raw-stream" 10392 - "application/json" 10393 responses: 10394 101: 10395 description: "logs returned as a stream" 10396 schema: 10397 type: "string" 10398 format: "binary" 10399 200: 10400 description: "logs returned as a string in response body" 10401 schema: 10402 type: "string" 10403 404: 10404 description: "no such service" 10405 schema: 10406 $ref: "#/definitions/ErrorResponse" 10407 examples: 10408 application/json: 10409 message: "No such service: c2ada9df5af8" 10410 500: 10411 description: "server error" 10412 schema: 10413 $ref: "#/definitions/ErrorResponse" 10414 503: 10415 description: "node is not part of a swarm" 10416 schema: 10417 $ref: "#/definitions/ErrorResponse" 10418 parameters: 10419 - name: "id" 10420 in: "path" 10421 required: true 10422 description: "ID or name of the service" 10423 type: "string" 10424 - name: "details" 10425 in: "query" 10426 description: "Show service context and extra details provided to logs." 10427 type: "boolean" 10428 default: false 10429 - name: "follow" 10430 in: "query" 10431 description: | 10432 Return the logs as a stream. 10433 10434 This will return a `101` HTTP response with a `Connection: upgrade` header, then hijack the HTTP connection to send raw output. For more information about hijacking and the stream format, [see the documentation for the attach endpoint](#operation/ContainerAttach). 10435 type: "boolean" 10436 default: false 10437 - name: "stdout" 10438 in: "query" 10439 description: "Return logs from `stdout`" 10440 type: "boolean" 10441 default: false 10442 - name: "stderr" 10443 in: "query" 10444 description: "Return logs from `stderr`" 10445 type: "boolean" 10446 default: false 10447 - name: "since" 10448 in: "query" 10449 description: "Only return logs since this time, as a UNIX timestamp" 10450 type: "integer" 10451 default: 0 10452 - name: "timestamps" 10453 in: "query" 10454 description: "Add timestamps to every log line" 10455 type: "boolean" 10456 default: false 10457 - name: "tail" 10458 in: "query" 10459 description: | 10460 Only return this number of log lines from the end of the logs. 10461 Specify as an integer or `all` to output all log lines. 10462 type: "string" 10463 default: "all" 10464 tags: ["Service"] 10465 /tasks: 10466 get: 10467 summary: "List tasks" 10468 operationId: "TaskList" 10469 produces: 10470 - "application/json" 10471 responses: 10472 200: 10473 description: "no error" 10474 schema: 10475 type: "array" 10476 items: 10477 $ref: "#/definitions/Task" 10478 example: 10479 - ID: "0kzzo1i0y4jz6027t0k7aezc7" 10480 Version: 10481 Index: 71 10482 CreatedAt: "2016-06-07T21:07:31.171892745Z" 10483 UpdatedAt: "2016-06-07T21:07:31.376370513Z" 10484 Spec: 10485 ContainerSpec: 10486 Image: "redis" 10487 Resources: 10488 Limits: {} 10489 Reservations: {} 10490 RestartPolicy: 10491 Condition: "any" 10492 MaxAttempts: 0 10493 Placement: {} 10494 ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz" 10495 Slot: 1 10496 NodeID: "60gvrl6tm78dmak4yl7srz94v" 10497 Status: 10498 Timestamp: "2016-06-07T21:07:31.290032978Z" 10499 State: "running" 10500 Message: "started" 10501 ContainerStatus: 10502 ContainerID: "e5d62702a1b48d01c3e02ca1e0212a250801fa8d67caca0b6f35919ebc12f035" 10503 PID: 677 10504 DesiredState: "running" 10505 NetworksAttachments: 10506 - Network: 10507 ID: "4qvuz4ko70xaltuqbt8956gd1" 10508 Version: 10509 Index: 18 10510 CreatedAt: "2016-06-07T20:31:11.912919752Z" 10511 UpdatedAt: "2016-06-07T21:07:29.955277358Z" 10512 Spec: 10513 Name: "ingress" 10514 Labels: 10515 com.docker.swarm.internal: "true" 10516 DriverConfiguration: {} 10517 IPAMOptions: 10518 Driver: {} 10519 Configs: 10520 - Subnet: "10.255.0.0/16" 10521 Gateway: "10.255.0.1" 10522 DriverState: 10523 Name: "overlay" 10524 Options: 10525 com.docker.network.driver.overlay.vxlanid_list: "256" 10526 IPAMOptions: 10527 Driver: 10528 Name: "default" 10529 Configs: 10530 - Subnet: "10.255.0.0/16" 10531 Gateway: "10.255.0.1" 10532 Addresses: 10533 - "10.255.0.10/16" 10534 - ID: "1yljwbmlr8er2waf8orvqpwms" 10535 Version: 10536 Index: 30 10537 CreatedAt: "2016-06-07T21:07:30.019104782Z" 10538 UpdatedAt: "2016-06-07T21:07:30.231958098Z" 10539 Name: "hopeful_cori" 10540 Spec: 10541 ContainerSpec: 10542 Image: "redis" 10543 Resources: 10544 Limits: {} 10545 Reservations: {} 10546 RestartPolicy: 10547 Condition: "any" 10548 MaxAttempts: 0 10549 Placement: {} 10550 ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz" 10551 Slot: 1 10552 NodeID: "60gvrl6tm78dmak4yl7srz94v" 10553 Status: 10554 Timestamp: "2016-06-07T21:07:30.202183143Z" 10555 State: "shutdown" 10556 Message: "shutdown" 10557 ContainerStatus: 10558 ContainerID: "1cf8d63d18e79668b0004a4be4c6ee58cddfad2dae29506d8781581d0688a213" 10559 DesiredState: "shutdown" 10560 NetworksAttachments: 10561 - Network: 10562 ID: "4qvuz4ko70xaltuqbt8956gd1" 10563 Version: 10564 Index: 18 10565 CreatedAt: "2016-06-07T20:31:11.912919752Z" 10566 UpdatedAt: "2016-06-07T21:07:29.955277358Z" 10567 Spec: 10568 Name: "ingress" 10569 Labels: 10570 com.docker.swarm.internal: "true" 10571 DriverConfiguration: {} 10572 IPAMOptions: 10573 Driver: {} 10574 Configs: 10575 - Subnet: "10.255.0.0/16" 10576 Gateway: "10.255.0.1" 10577 DriverState: 10578 Name: "overlay" 10579 Options: 10580 com.docker.network.driver.overlay.vxlanid_list: "256" 10581 IPAMOptions: 10582 Driver: 10583 Name: "default" 10584 Configs: 10585 - Subnet: "10.255.0.0/16" 10586 Gateway: "10.255.0.1" 10587 Addresses: 10588 - "10.255.0.5/16" 10589 500: 10590 description: "server error" 10591 schema: 10592 $ref: "#/definitions/ErrorResponse" 10593 503: 10594 description: "node is not part of a swarm" 10595 schema: 10596 $ref: "#/definitions/ErrorResponse" 10597 parameters: 10598 - name: "filters" 10599 in: "query" 10600 type: "string" 10601 description: | 10602 A JSON encoded value of the filters (a `map[string][]string`) to 10603 process on the tasks list. 10604 10605 Available filters: 10606 10607 - `desired-state=(running | shutdown | accepted)` 10608 - `id=<task id>` 10609 - `label=key` or `label="key=value"` 10610 - `name=<task name>` 10611 - `node=<node id or name>` 10612 - `service=<service name>` 10613 tags: ["Task"] 10614 /tasks/{id}: 10615 get: 10616 summary: "Inspect a task" 10617 operationId: "TaskInspect" 10618 produces: 10619 - "application/json" 10620 responses: 10621 200: 10622 description: "no error" 10623 schema: 10624 $ref: "#/definitions/Task" 10625 404: 10626 description: "no such task" 10627 schema: 10628 $ref: "#/definitions/ErrorResponse" 10629 500: 10630 description: "server error" 10631 schema: 10632 $ref: "#/definitions/ErrorResponse" 10633 503: 10634 description: "node is not part of a swarm" 10635 schema: 10636 $ref: "#/definitions/ErrorResponse" 10637 parameters: 10638 - name: "id" 10639 in: "path" 10640 description: "ID of the task" 10641 required: true 10642 type: "string" 10643 tags: ["Task"] 10644 /tasks/{id}/logs: 10645 get: 10646 summary: "Get task logs" 10647 description: | 10648 Get `stdout` and `stderr` logs from a task. 10649 See also [`/containers/{id}/logs`](#operation/ContainerLogs). 10650 10651 **Note**: This endpoint works only for services with the `json-file` or 10652 `journald` logging drivers. 10653 operationId: "TaskLogs" 10654 produces: 10655 - "application/vnd.docker.raw-stream" 10656 - "application/json" 10657 responses: 10658 101: 10659 description: "logs returned as a stream" 10660 schema: 10661 type: "string" 10662 format: "binary" 10663 200: 10664 description: "logs returned as a string in response body" 10665 schema: 10666 type: "string" 10667 404: 10668 description: "no such task" 10669 schema: 10670 $ref: "#/definitions/ErrorResponse" 10671 examples: 10672 application/json: 10673 message: "No such task: c2ada9df5af8" 10674 500: 10675 description: "server error" 10676 schema: 10677 $ref: "#/definitions/ErrorResponse" 10678 503: 10679 description: "node is not part of a swarm" 10680 schema: 10681 $ref: "#/definitions/ErrorResponse" 10682 parameters: 10683 - name: "id" 10684 in: "path" 10685 required: true 10686 description: "ID of the task" 10687 type: "string" 10688 - name: "details" 10689 in: "query" 10690 description: "Show task context and extra details provided to logs." 10691 type: "boolean" 10692 default: false 10693 - name: "follow" 10694 in: "query" 10695 description: | 10696 Return the logs as a stream. 10697 10698 This will return a `101` HTTP response with a `Connection: upgrade` header, then hijack the HTTP connection to send raw output. For more information about hijacking and the stream format, [see the documentation for the attach endpoint](#operation/ContainerAttach). 10699 type: "boolean" 10700 default: false 10701 - name: "stdout" 10702 in: "query" 10703 description: "Return logs from `stdout`" 10704 type: "boolean" 10705 default: false 10706 - name: "stderr" 10707 in: "query" 10708 description: "Return logs from `stderr`" 10709 type: "boolean" 10710 default: false 10711 - name: "since" 10712 in: "query" 10713 description: "Only return logs since this time, as a UNIX timestamp" 10714 type: "integer" 10715 default: 0 10716 - name: "timestamps" 10717 in: "query" 10718 description: "Add timestamps to every log line" 10719 type: "boolean" 10720 default: false 10721 - name: "tail" 10722 in: "query" 10723 description: | 10724 Only return this number of log lines from the end of the logs. 10725 Specify as an integer or `all` to output all log lines. 10726 type: "string" 10727 default: "all" 10728 tags: ["Task"] 10729 /secrets: 10730 get: 10731 summary: "List secrets" 10732 operationId: "SecretList" 10733 produces: 10734 - "application/json" 10735 responses: 10736 200: 10737 description: "no error" 10738 schema: 10739 type: "array" 10740 items: 10741 $ref: "#/definitions/Secret" 10742 example: 10743 - ID: "blt1owaxmitz71s9v5zh81zun" 10744 Version: 10745 Index: 85 10746 CreatedAt: "2017-07-20T13:55:28.678958722Z" 10747 UpdatedAt: "2017-07-20T13:55:28.678958722Z" 10748 Spec: 10749 Name: "mysql-passwd" 10750 Labels: 10751 some.label: "some.value" 10752 Driver: 10753 Name: "secret-bucket" 10754 Options: 10755 OptionA: "value for driver option A" 10756 OptionB: "value for driver option B" 10757 - ID: "ktnbjxoalbkvbvedmg1urrz8h" 10758 Version: 10759 Index: 11 10760 CreatedAt: "2016-11-05T01:20:17.327670065Z" 10761 UpdatedAt: "2016-11-05T01:20:17.327670065Z" 10762 Spec: 10763 Name: "app-dev.crt" 10764 Labels: 10765 foo: "bar" 10766 500: 10767 description: "server error" 10768 schema: 10769 $ref: "#/definitions/ErrorResponse" 10770 503: 10771 description: "node is not part of a swarm" 10772 schema: 10773 $ref: "#/definitions/ErrorResponse" 10774 parameters: 10775 - name: "filters" 10776 in: "query" 10777 type: "string" 10778 description: | 10779 A JSON encoded value of the filters (a `map[string][]string`) to 10780 process on the secrets list. 10781 10782 Available filters: 10783 10784 - `id=<secret id>` 10785 - `label=<key> or label=<key>=value` 10786 - `name=<secret name>` 10787 - `names=<secret name>` 10788 tags: ["Secret"] 10789 /secrets/create: 10790 post: 10791 summary: "Create a secret" 10792 operationId: "SecretCreate" 10793 consumes: 10794 - "application/json" 10795 produces: 10796 - "application/json" 10797 responses: 10798 201: 10799 description: "no error" 10800 schema: 10801 $ref: "#/definitions/IdResponse" 10802 409: 10803 description: "name conflicts with an existing object" 10804 schema: 10805 $ref: "#/definitions/ErrorResponse" 10806 500: 10807 description: "server error" 10808 schema: 10809 $ref: "#/definitions/ErrorResponse" 10810 503: 10811 description: "node is not part of a swarm" 10812 schema: 10813 $ref: "#/definitions/ErrorResponse" 10814 parameters: 10815 - name: "body" 10816 in: "body" 10817 schema: 10818 allOf: 10819 - $ref: "#/definitions/SecretSpec" 10820 - type: "object" 10821 example: 10822 Name: "app-key.crt" 10823 Labels: 10824 foo: "bar" 10825 Data: "VEhJUyBJUyBOT1QgQSBSRUFMIENFUlRJRklDQVRFCg==" 10826 Driver: 10827 Name: "secret-bucket" 10828 Options: 10829 OptionA: "value for driver option A" 10830 OptionB: "value for driver option B" 10831 tags: ["Secret"] 10832 /secrets/{id}: 10833 get: 10834 summary: "Inspect a secret" 10835 operationId: "SecretInspect" 10836 produces: 10837 - "application/json" 10838 responses: 10839 200: 10840 description: "no error" 10841 schema: 10842 $ref: "#/definitions/Secret" 10843 examples: 10844 application/json: 10845 ID: "ktnbjxoalbkvbvedmg1urrz8h" 10846 Version: 10847 Index: 11 10848 CreatedAt: "2016-11-05T01:20:17.327670065Z" 10849 UpdatedAt: "2016-11-05T01:20:17.327670065Z" 10850 Spec: 10851 Name: "app-dev.crt" 10852 Labels: 10853 foo: "bar" 10854 Driver: 10855 Name: "secret-bucket" 10856 Options: 10857 OptionA: "value for driver option A" 10858 OptionB: "value for driver option B" 10859 10860 404: 10861 description: "secret not found" 10862 schema: 10863 $ref: "#/definitions/ErrorResponse" 10864 500: 10865 description: "server error" 10866 schema: 10867 $ref: "#/definitions/ErrorResponse" 10868 503: 10869 description: "node is not part of a swarm" 10870 schema: 10871 $ref: "#/definitions/ErrorResponse" 10872 parameters: 10873 - name: "id" 10874 in: "path" 10875 required: true 10876 type: "string" 10877 description: "ID of the secret" 10878 tags: ["Secret"] 10879 delete: 10880 summary: "Delete a secret" 10881 operationId: "SecretDelete" 10882 produces: 10883 - "application/json" 10884 responses: 10885 204: 10886 description: "no error" 10887 404: 10888 description: "secret not found" 10889 schema: 10890 $ref: "#/definitions/ErrorResponse" 10891 500: 10892 description: "server error" 10893 schema: 10894 $ref: "#/definitions/ErrorResponse" 10895 503: 10896 description: "node is not part of a swarm" 10897 schema: 10898 $ref: "#/definitions/ErrorResponse" 10899 parameters: 10900 - name: "id" 10901 in: "path" 10902 required: true 10903 type: "string" 10904 description: "ID of the secret" 10905 tags: ["Secret"] 10906 /secrets/{id}/update: 10907 post: 10908 summary: "Update a Secret" 10909 operationId: "SecretUpdate" 10910 responses: 10911 200: 10912 description: "no error" 10913 400: 10914 description: "bad parameter" 10915 schema: 10916 $ref: "#/definitions/ErrorResponse" 10917 404: 10918 description: "no such secret" 10919 schema: 10920 $ref: "#/definitions/ErrorResponse" 10921 500: 10922 description: "server error" 10923 schema: 10924 $ref: "#/definitions/ErrorResponse" 10925 503: 10926 description: "node is not part of a swarm" 10927 schema: 10928 $ref: "#/definitions/ErrorResponse" 10929 parameters: 10930 - name: "id" 10931 in: "path" 10932 description: "The ID or name of the secret" 10933 type: "string" 10934 required: true 10935 - name: "body" 10936 in: "body" 10937 schema: 10938 $ref: "#/definitions/SecretSpec" 10939 description: | 10940 The spec of the secret to update. Currently, only the Labels field 10941 can be updated. All other fields must remain unchanged from the 10942 [SecretInspect endpoint](#operation/SecretInspect) response values. 10943 - name: "version" 10944 in: "query" 10945 description: | 10946 The version number of the secret object being updated. This is 10947 required to avoid conflicting writes. 10948 type: "integer" 10949 format: "int64" 10950 required: true 10951 tags: ["Secret"] 10952 /configs: 10953 get: 10954 summary: "List configs" 10955 operationId: "ConfigList" 10956 produces: 10957 - "application/json" 10958 responses: 10959 200: 10960 description: "no error" 10961 schema: 10962 type: "array" 10963 items: 10964 $ref: "#/definitions/Config" 10965 example: 10966 - ID: "ktnbjxoalbkvbvedmg1urrz8h" 10967 Version: 10968 Index: 11 10969 CreatedAt: "2016-11-05T01:20:17.327670065Z" 10970 UpdatedAt: "2016-11-05T01:20:17.327670065Z" 10971 Spec: 10972 Name: "server.conf" 10973 500: 10974 description: "server error" 10975 schema: 10976 $ref: "#/definitions/ErrorResponse" 10977 503: 10978 description: "node is not part of a swarm" 10979 schema: 10980 $ref: "#/definitions/ErrorResponse" 10981 parameters: 10982 - name: "filters" 10983 in: "query" 10984 type: "string" 10985 description: | 10986 A JSON encoded value of the filters (a `map[string][]string`) to 10987 process on the configs list. 10988 10989 Available filters: 10990 10991 - `id=<config id>` 10992 - `label=<key> or label=<key>=value` 10993 - `name=<config name>` 10994 - `names=<config name>` 10995 tags: ["Config"] 10996 /configs/create: 10997 post: 10998 summary: "Create a config" 10999 operationId: "ConfigCreate" 11000 consumes: 11001 - "application/json" 11002 produces: 11003 - "application/json" 11004 responses: 11005 201: 11006 description: "no error" 11007 schema: 11008 $ref: "#/definitions/IdResponse" 11009 409: 11010 description: "name conflicts with an existing object" 11011 schema: 11012 $ref: "#/definitions/ErrorResponse" 11013 500: 11014 description: "server error" 11015 schema: 11016 $ref: "#/definitions/ErrorResponse" 11017 503: 11018 description: "node is not part of a swarm" 11019 schema: 11020 $ref: "#/definitions/ErrorResponse" 11021 parameters: 11022 - name: "body" 11023 in: "body" 11024 schema: 11025 allOf: 11026 - $ref: "#/definitions/ConfigSpec" 11027 - type: "object" 11028 example: 11029 Name: "server.conf" 11030 Labels: 11031 foo: "bar" 11032 Data: "VEhJUyBJUyBOT1QgQSBSRUFMIENFUlRJRklDQVRFCg==" 11033 tags: ["Config"] 11034 /configs/{id}: 11035 get: 11036 summary: "Inspect a config" 11037 operationId: "ConfigInspect" 11038 produces: 11039 - "application/json" 11040 responses: 11041 200: 11042 description: "no error" 11043 schema: 11044 $ref: "#/definitions/Config" 11045 examples: 11046 application/json: 11047 ID: "ktnbjxoalbkvbvedmg1urrz8h" 11048 Version: 11049 Index: 11 11050 CreatedAt: "2016-11-05T01:20:17.327670065Z" 11051 UpdatedAt: "2016-11-05T01:20:17.327670065Z" 11052 Spec: 11053 Name: "app-dev.crt" 11054 404: 11055 description: "config not found" 11056 schema: 11057 $ref: "#/definitions/ErrorResponse" 11058 500: 11059 description: "server error" 11060 schema: 11061 $ref: "#/definitions/ErrorResponse" 11062 503: 11063 description: "node is not part of a swarm" 11064 schema: 11065 $ref: "#/definitions/ErrorResponse" 11066 parameters: 11067 - name: "id" 11068 in: "path" 11069 required: true 11070 type: "string" 11071 description: "ID of the config" 11072 tags: ["Config"] 11073 delete: 11074 summary: "Delete a config" 11075 operationId: "ConfigDelete" 11076 produces: 11077 - "application/json" 11078 responses: 11079 204: 11080 description: "no error" 11081 404: 11082 description: "config not found" 11083 schema: 11084 $ref: "#/definitions/ErrorResponse" 11085 500: 11086 description: "server error" 11087 schema: 11088 $ref: "#/definitions/ErrorResponse" 11089 503: 11090 description: "node is not part of a swarm" 11091 schema: 11092 $ref: "#/definitions/ErrorResponse" 11093 parameters: 11094 - name: "id" 11095 in: "path" 11096 required: true 11097 type: "string" 11098 description: "ID of the config" 11099 tags: ["Config"] 11100 /configs/{id}/update: 11101 post: 11102 summary: "Update a Config" 11103 operationId: "ConfigUpdate" 11104 responses: 11105 200: 11106 description: "no error" 11107 400: 11108 description: "bad parameter" 11109 schema: 11110 $ref: "#/definitions/ErrorResponse" 11111 404: 11112 description: "no such config" 11113 schema: 11114 $ref: "#/definitions/ErrorResponse" 11115 500: 11116 description: "server error" 11117 schema: 11118 $ref: "#/definitions/ErrorResponse" 11119 503: 11120 description: "node is not part of a swarm" 11121 schema: 11122 $ref: "#/definitions/ErrorResponse" 11123 parameters: 11124 - name: "id" 11125 in: "path" 11126 description: "The ID or name of the config" 11127 type: "string" 11128 required: true 11129 - name: "body" 11130 in: "body" 11131 schema: 11132 $ref: "#/definitions/ConfigSpec" 11133 description: | 11134 The spec of the config to update. Currently, only the Labels field 11135 can be updated. All other fields must remain unchanged from the 11136 [ConfigInspect endpoint](#operation/ConfigInspect) response values. 11137 - name: "version" 11138 in: "query" 11139 description: | 11140 The version number of the config object being updated. This is 11141 required to avoid conflicting writes. 11142 type: "integer" 11143 format: "int64" 11144 required: true 11145 tags: ["Config"] 11146 /distribution/{name}/json: 11147 get: 11148 summary: "Get image information from the registry" 11149 description: | 11150 Return image digest and platform information by contacting the registry. 11151 operationId: "DistributionInspect" 11152 produces: 11153 - "application/json" 11154 responses: 11155 200: 11156 description: "descriptor and platform information" 11157 schema: 11158 type: "object" 11159 x-go-name: DistributionInspect 11160 title: "DistributionInspectResponse" 11161 required: [Descriptor, Platforms] 11162 properties: 11163 Descriptor: 11164 type: "object" 11165 description: | 11166 A descriptor struct containing digest, media type, and size. 11167 properties: 11168 MediaType: 11169 type: "string" 11170 Size: 11171 type: "integer" 11172 format: "int64" 11173 Digest: 11174 type: "string" 11175 URLs: 11176 type: "array" 11177 items: 11178 type: "string" 11179 Platforms: 11180 type: "array" 11181 description: | 11182 An array containing all platforms supported by the image. 11183 items: 11184 type: "object" 11185 properties: 11186 Architecture: 11187 type: "string" 11188 OS: 11189 type: "string" 11190 OSVersion: 11191 type: "string" 11192 OSFeatures: 11193 type: "array" 11194 items: 11195 type: "string" 11196 Variant: 11197 type: "string" 11198 Features: 11199 type: "array" 11200 items: 11201 type: "string" 11202 examples: 11203 application/json: 11204 Descriptor: 11205 MediaType: "application/vnd.docker.distribution.manifest.v2+json" 11206 Digest: "sha256:c0537ff6a5218ef531ece93d4984efc99bbf3f7497c0a7726c88e2bb7584dc96" 11207 Size: 3987495 11208 URLs: 11209 - "" 11210 Platforms: 11211 - Architecture: "amd64" 11212 OS: "linux" 11213 OSVersion: "" 11214 OSFeatures: 11215 - "" 11216 Variant: "" 11217 Features: 11218 - "" 11219 401: 11220 description: "Failed authentication or no image found" 11221 schema: 11222 $ref: "#/definitions/ErrorResponse" 11223 examples: 11224 application/json: 11225 message: "No such image: someimage (tag: latest)" 11226 500: 11227 description: "Server error" 11228 schema: 11229 $ref: "#/definitions/ErrorResponse" 11230 parameters: 11231 - name: "name" 11232 in: "path" 11233 description: "Image name or id" 11234 type: "string" 11235 required: true 11236 tags: ["Distribution"] 11237 /session: 11238 post: 11239 summary: "Initialize interactive session" 11240 description: | 11241 Start a new interactive session with a server. Session allows server to 11242 call back to the client for advanced capabilities. 11243 11244 > **Note**: This endpoint is *experimental* and only available if the daemon is started with experimental 11245 > features enabled. The specifications for this endpoint may still change in a future version of the API. 11246 11247 ### Hijacking 11248 11249 This endpoint hijacks the HTTP connection to HTTP2 transport that allows 11250 the client to expose gPRC services on that connection. 11251 11252 For example, the client sends this request to upgrade the connection: 11253 11254 ``` 11255 POST /session HTTP/1.1 11256 Upgrade: h2c 11257 Connection: Upgrade 11258 ``` 11259 11260 The Docker daemon responds with a `101 UPGRADED` response follow with 11261 the raw stream: 11262 11263 ``` 11264 HTTP/1.1 101 UPGRADED 11265 Connection: Upgrade 11266 Upgrade: h2c 11267 ``` 11268 operationId: "Session" 11269 produces: 11270 - "application/vnd.docker.raw-stream" 11271 responses: 11272 101: 11273 description: "no error, hijacking successful" 11274 400: 11275 description: "bad parameter" 11276 schema: 11277 $ref: "#/definitions/ErrorResponse" 11278 500: 11279 description: "server error" 11280 schema: 11281 $ref: "#/definitions/ErrorResponse" 11282 tags: ["Session (experimental)"]