Search or ask Docker

NodeSpec

NodeSpec schema in Docker Engine API 1.57.

View Markdown

Schema

Type: object

Availability

Type: string

Availability of the node.
All schema constraints and annotations
{
  "description": "Availability of the node.",
  "enum": [
    "active",
    "pause",
    "drain"
  ],
  "example": "active",
  "type": "string"
}
Labels

Type: object

User-defined key/value metadata.
All schema constraints and annotations
{
  "additionalProperties": {
    "type": "string"
  },
  "description": "User-defined key/value metadata.",
  "type": "object"
}
Name

Type: string

Name for the node.
All schema constraints and annotations
{
  "description": "Name for the node.",
  "example": "my-node",
  "type": "string"
}
Role

Type: string

Role of the node.
All schema constraints and annotations
{
  "description": "Role of the node.",
  "enum": [
    "worker",
    "manager"
  ],
  "example": "manager",
  "type": "string"
}
All schema constraints and annotations
{
  "example": {
    "Availability": "active",
    "Labels": {
      "foo": "bar"
    },
    "Name": "node-name",
    "Role": "manager"
  },
  "properties": {
    "Availability": {
      "description": "Availability of the node.",
      "enum": [
        "active",
        "pause",
        "drain"
      ],
      "example": "active",
      "type": "string"
    },
    "Labels": {
      "additionalProperties": {
        "type": "string"
      },
      "description": "User-defined key/value metadata.",
      "type": "object"
    },
    "Name": {
      "description": "Name for the node.",
      "example": "my-node",
      "type": "string"
    },
    "Role": {
      "description": "Role of the node.",
      "enum": [
        "worker",
        "manager"
      ],
      "example": "manager",
      "type": "string"
    }
  },
  "type": "object"
}