Handle networks.driver_opts for a service

These are endpoint-specific driver options...

services:
  myservice:
    image: myimage
    networks:
      mynet:
        driver_opts:
          "option1": "value1"

The API has had support for a long time, it's only recently been
added to compose (unreleased right now).

Signed-off-by: Rob Murray <rob.murray@docker.com>
This commit is contained in:
Rob Murray
2024-06-07 09:13:21 +01:00
parent a731722652
commit 94f9de5928
8 changed files with 38 additions and 6 deletions

View File

@ -197,6 +197,12 @@
"type": "object",
"properties": {
"aliases": {"$ref": "#/definitions/list_of_strings"},
"driver_opts": {
"type": "object",
"patternProperties": {
"^.+$": { "type": ["string", "number"] }
}
},
"ipv4_address": {"type": "string"},
"ipv6_address": {"type": "string"}
},