v1
Double column
API
CLI
JS Client

Volumes /

Update volume

Update volume mounts and storage size

Required permission

Project > Volumes > General > Update

Path parameters

    • projectId

      string required

      ID of the project

    • volumeId

      string required

      ID of the volume

Request body

  • {object}
    • mounts

      [array]

      Array of mounts, containerMountPaths must be unique

      • {object}
        • volumeMountPath

          string

          Optionally specify the path inside this volume that should be mounted

          pattern
          ^((?!\.\.).)*$
        • containerMountPath

          string required

          Specify the path into which the volume should be mounted

          pattern
          ^((?!:).)*$
    • spec

      {object}
      • storageSize

        integer

        The size of the storage, in megabytes. Configurable sizes depend on the storage class.

        min
        4096

Response body

  • {object}

    Response object.

    • data

      {object} required

      Result data.

    API
    CLI
    JS Client

    POST /v1/projects/{projectId}/volumes/{volumeId}

    Example request

    Request body
    curl
    curl --header "Content-Type: application/json" \
      --header "Authorization: Bearer NORTHFLANK_API_TOKEN" \
      --request POST \
      --data '{"mounts":[{"volumeMountPath":"","containerMountPath":"/container"}],"spec":{"storageSize":4096}}' \
      http://api.northflank.com/v1/projects/{projectId}/volumes/{volumeId}

    Example response

    200 OK

    The operation was performed successfully.

    JSON

    {
      "data": {}
    }

    © 2022 Northflank Ltd. All rights reserved.