Swarm
post/swarm/update

Request

  • Base URL
    /v1.57 (relative, and the document was published on a file host, not at the API’s origin)
  • Auth
    none declared

Query parameters

versioninteger required

The version number of the swarm object being updated. This is required to avoid conflicting writes.

rotateWorkerTokenboolean

Rotate the worker join token.

rotateManagerTokenboolean

Rotate the manager join token.

rotateManagerUnlockKeyboolean

Rotate the manager unlock key.

Request body

Namestring

Name of the swarm.

Labelsobject

User-defined key/value metadata.

Example request

{
  "Name": "default",
  "Labels": {
    "com.example.corp.type": "production",
    "com.example.corp.department": "engineering"
  },
  "Orchestration": {
    "TaskHistoryRetentionLimit": 10
  },
  "Raft": {
    "SnapshotInterval": 10000,
    "LogEntriesForSlowFollowers": 500,
    "ElectionTick": 3,
    "HeartbeatTick": 1
  },
  "Dispatcher": {
    "HeartbeatPeriod": 5000000000
  },
  "CAConfig": {
    "NodeCertExpiry": 7776000000000000
  },
  "TaskDefaults": {
    "LogDriver": {
      "Name": "json-file",
      "Options": {
        "max-file": "10",
        "max-size": "100m"
      }
    }
  }
}

Response

no error

Changes

    • breaking

      removed the request body

    • breaking

      removed the success response with the status

    • info

      api tag Swarm added

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    • info

      added the success response with the status

    • breaking

      removed the media type text/plain from the request body

    • breaking

      for the query request parameter rotateManagerToken, default value false was removed

    • breaking

      for the query request parameter rotateManagerUnlockKey, default value false was removed

    • breaking

      for the query request parameter rotateWorkerToken, default value false was removed

    • breaking

      the / request property format changed from no format to int32

    • breaking

      the / request property format changed from no format to int32

    • breaking

      removed the success response with the status

    • info

      api tag Swarm removed

    • info

      the request property default value cfssl was removed

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      removed the non-success response with the status

    • info

      added the success response with the status