Onedata API Reference

REST API references for Onezone, Oneprovider, and Onepanel.

Configure provider deployment

POST /provider/configuration

Configures and starts provider services, such as database, cluster manager and cluster worker. Depending on the configuration, sets up provider storage and registers in the zone. This request can be executed unauthorized as long as there are no admin users.

Request body

application/json application/x-yaml

The provider configuration description.

PropertyType & Description
cluster
object (ProviderClusterConfiguration)

The provider cluster configuration.

domainName
string

Hostname suffix common for all services in the cluster. Together with a node hostname constitutes a fully qualified domain name (FQDN) of the node. May be skipped to allow unrelated hostnames for each node.

nodes required
object

The collection of nodes aliases associated with nodes properties.

databases required
object (ClusterDatabases)

The cluster database service configuration.

nodes required
array of strings

The list of aliases of cluster database nodes.

serverQuota
integer

The server quota is the RAM memory in MiB that is allocated to the server when Couchbase Server is first installed. This sets the limit of RAM allocated by Couchbase for caching data for all buckets on each of the nodes. Optional, defaults to 4096 (4 GiB).

bucketQuota
integer

The bucket quota is the amount of RAM memory in MiB allocated to each individual bucket for caching data. Optional, defaults to 4096 (4 GiB). Optimally, should be set to the same value as serverQuota.

managers required
object (ClusterManagers)

The cluster manager service configuration.

mainNode required
string

The alias of the main cluster manager node.

nodes required
array of strings

The list of aliases of cluster manager nodes.

oneS3
object (ClusterOneS3)

The OneS3 service configuration.

nodes required
array of strings

The list of aliases of OneS3 nodes.

port
integer

The port on which the OneS3 service will be available.

workers required
object (ClusterWorkers)

The cluster worker service configuration.

nodes required
array of strings

The list of aliases of cluster worker nodes.

storages
object (StorageCreateRequest)

The configuration details required to add storage resources.

oneprovider
object

The provider registration data.

register required
boolean

Defines whether the provider should be registered in a zone.

tokenProvisionMethod
string

Indicates how the Oneprovider registration token will be provided:

  • "inline" - the registration token must be placed in the token field (consult for more information).
  • "fromFile" - the registration token will be read from given file, specified in the tokenFile field (consult for more information).
Enum:
inlinefromFile
token
string

Registration token obtained from Onezone. This token identifies the Onezone service where the Oneprovider will be registered and authorizes the registration request. Required when the tokenProvisionMethod is set to "inline".

tokenFile
string

Absolute path to the file containing the Oneprovider registration token. The token (and nothing else) should be placed in the file as plaintext. The file does not have to pre-exist - it may be created after this request is made (Onepanel will wait for the file to appear for some time). Required when the tokenProvisionMethod is set to "fromFile".

name required
string

The name under which the provider will be registered in a zone.

subdomainDelegation
boolean

If enabled, the storage provider will be assigned a subdomain in onezone's domain and 'subdomain' property must be provided. If disabled, 'domain' property should be provided.

subdomain
string

Unique subdomain in onezone's domain for the provider. Required if subdomain delegation is enabled.

letsEncryptEnabled
boolean

If enabled the provider will use Let's Encrypt service to obtain SSL certificates. Otherwise certificates must be manually provided. This option cannot be enabled if subdomainDelegation is false. By enabling this option you agree to the Let's Encrypt Subscriber Agreement.

domain
string

The fully qualified domain name of the provider or its IP address (only for single-node deployments or clusters with a reverse proxy). Required if subdomain delegation is disabled.

geoLongitude
number

The geographical longitude of the provider.

geoLatitude
number

The geographical latitude of the provider.

adminEmail required
string

Email address of the oneprovider administrator.

onepanel
object (PanelConfiguration)

The panel configuration.

interactiveDeployment
boolean

Indicates that interactive deployment is being performed. If false, users entering GUI will not be asked to complete the configuration. In that case default values will be used, available for change later via appropriate Onepanel GUI pages or REST.

guiDebugMode
boolean

When true, all GUIs hosted in this cluster will print debug logs to browser console.

Request Examples

application/json
{
  "cluster": {
    "domainName": "oneprovider.onedata.example.com",
    "nodes": {
      "node1": {
        "hostname": "node1",
        "externalIp": "128.128.64.64"
      },
      "node2": {
        "hostname": "node2"
      }
    },
    "manager": {
      "mainNode": "node1",
      "nodes": [
        "node1",
        "node2"
      ]
    },
    "worker": {
      "nodes": [
        "node1"
      ]
    },
    "database": {
      "nodes": [
        "node1"
      ]
    },
    "storage": {
      "NFS": {
        "type": "posix",
        "mountPoint": "/volumes/storage"
      }
    }
  },
  "oneprovider": {
    "register": true,
    "token": "MDAzM2xvY2F00aW9uIGRldi1vbmV6b25lLmRlZmF1...",
    "name": "example",
    "subdomainDelegation": "false,",
    "letsEncryptEnabled": "false,",
    "domain": "provider.example.com",
    "adminEmail": "admin@example.eu",
    "geoLongitude": -24.3776025,
    "geoLatitude": -128.3519364
  }
}

Responses

application/json
202
No description.
400

Invalid request.

PropertyType & Description
error
object (ErrorDetails)

Object describing an error.

id required
string

String identifying the error type. Does not change between error instances.

description required
string

Human readable error description. May contain information specific to given error instance.

details
object

Details about the error instance. The object schema is specific to each error type.

Example

application/json
{
  "error": {
    "id": "badValueString",
    "details": {
      "key": "name"
    },
    "description": "Bad value: provided \"name\" must be a string."
  }
}
403

Forbidden request.

409

Cluster already deployed.

500

Internal server error.

PropertyType & Description
error
object (ErrorDetails)

Object describing an error.

id required
string

String identifying the error type. Does not change between error instances.

description required
string

Human readable error description. May contain information specific to given error instance.

details
object

Details about the error instance. The object schema is specific to each error type.

Example

application/json
{
  "error": {
    "id": "badValueString",
    "details": {
      "key": "name"
    },
    "description": "Bad value: provided \"name\" must be a string."
  }
}