instance-erp5-input-schema.json 12.5 KB
Newer Older
1 2 3 4 5
{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "description": "Parameters to instantiate ERP5",
  "additionalProperties": false,
  "properties": {
6
    "sla-dict": {
7
      "description": "Where to request instances. Each key is a query string for criterions (e.g. \"computer_guid=foo\"), and each value is a list of partition references (note: Zope partitions reference must be prefixed with \"zope-\").",
8 9 10 11
      "additionalProperties": {
        "type": "array",
        "items": { "type": "string" },
        "uniqueItems": true
12 13 14
      },
      "type": "object"
    },
15
    "site-id": {
16
      "description": "ERP5Site object's id. An empty value disables automatic site creation.",
17 18 19
      "default": "erp5",
      "type": "string"
    },
20
    "bt5": {
21
      "description": "Business Template to install at automatic site creation. By default, all configurators are installed.",
22 23
      "type": "string"
    },
24 25 26 27
    "id-store-interval": {
      "description": "Set Store Interval of default SQL Non Continuous Increasing Id Generator at automatic site creation. If unset, the value from the erp5_core Business Template is not touched.",
      "type": "integer"
    },
28
    "timezone": {
29
      "description": "Zope's timezone. Possible values are determined by host's libc, and typically come from a separate package (tzdata, ...)",
30 31 32
      "default": "UTC",
      "type": "string"
    },
33 34 35
    "deadlock-debugger-password": {
      "description": "Password for /manage_debug_threads",
      "type": "string"
36
    },
37 38 39 40 41 42 43 44 45
    "inituser-login": {
      "description": "Login of the initial/rescue user",
      "default": "zope",
      "type": "string"
    },
    "inituser-password": {
      "description": "Password of the initial/rescue user",
      "type": "string"
    },
46
    "developer-list": {
47
      "description": "List of logins which should get the Developper role (required to modify portal_components' content), defaulting to inituser-login's value",
48
      "items": {
49
        "pattern": "^\\S+$",
50 51 52 53 54
        "type": "string"
      },
      "uniqueItems": true,
      "type": "array"
    },
55
    "hostalias-dict": {
56
      "description": "Hostname-to-domain-name mapping",
57
      "default": {},
58 59 60
      "additionalProperties": {
        "description": "A hostname to which current entry will resolve",
        "type": "string"
61 62 63
      },
      "type": "object"
    },
64
    "hosts-dict": {
65
      "description": "Host entries to be used in addition to and/or overriding auto-generated ones (erp5-catalog-0, erp5-cloudooo, erp5-memcached-persistent, erp5-memcached-volatile and erp5-smtp)",
66 67
      "patternProperties": {
        ".*": {
68
          "description": "An IP or domain name to which current entry will resolve",
69 70 71 72 73
          "type": "string"
        }
      },
      "type": "object"
    },
74 75 76 77
    "frontend": {
      "description": "Front-end slave instance request parameters",
      "properties": {
        "software-url": {
78
          "description": "Front-end's software type. If this parameter is empty, no front-end instance is requested. Else, sla-dict must specify 'frontend' which is a special value matching all frontends (e.g. {\"instance_guid=bar\": [\"frontend\"]}).",
79 80 81 82 83 84 85 86 87 88 89
          "default": "",
          "type": "string"
        },
        "domain": {
          "description": "The domain name to request front-end to respond as.",
          "default": "",
          "type": "string"
        },
        "software-type": {
          "description": "Request a front-end slave instance of this software type.",
          "default": "RootSoftwareInstance",
90
          "type": "object"
91 92 93 94 95 96 97 98 99 100 101
        },
	"virtualhostroot-http-port": {
	  "description": "Front-end slave http port. Port where http requests to frontend will be redirected.",
	  "default": 80,
	  "type": "integer"
	},
	"virtualhostroot-https-port": {
	  "description": "Front-end slave https port. Port where https requests to frontend will be redirected.",
	  "default": 443,
	  "type": "integer"
	}
102 103 104
      },
      "type": "object"
    },
105 106
    "zope-partition-dict": {
      "description": "Zope layout definition",
107
      "default": {"1": {}},
108 109 110 111 112
      "patternProperties": {
        ".*": {
          "additionalProperties": false,
          "properties": {
            "family": {
113
              "description": "The family this partition is part of. For example: 'public', 'admin', 'backoffice', 'web-service'... Each family gets its own balancer entry. It has no special meaning for the system.",
114 115 116 117 118 119 120 121 122 123
              "default": "default",
              "type": "string"
            },
            "instance-count": {
              "description": "Number of Zopes to setup on this partition",
              "default": 1,
              "type": "integer"
            },
            "thread-amount": {
              "description": "Number of worker threads for each created Zope process",
124
              "default": 4,
125 126 127 128 129
              "type": "integer"
            },
            "timerserver-interval": {
              "description": "Timerserver tick perdiod, in seconds, or 0 to disable",
              "default": 5,
130
              "type": "number"
131
            },
132 133 134 135
            "private-dev-shm": {
              "description": "Size of private /dev/shm for wendelin.core. If sysctl kernel.unprivileged_userns_clone exists, it must be set to 1.",
              "type": "string"
            },
136 137 138 139 140 141
            "ssl-authentication": {
              "title": "Enable SSL Client authentication on this zope instance.",
              "description": "If set to true, will set SSL Client verification to required on apache VirtualHost which allow to access this zope instance.",
              "type": "boolean",
              "default": false
            },
142 143 144 145 146
            "webdav": {
              "description": "Serve webdav queries, implies timerserver-interval=0 (disabled). Mixing webdav and non-webdav nodes in a single family will give unspecified results.",
              "default": false,
              "type": "boolean"
            },
147 148 149 150 151 152 153 154 155 156
            "longrequest-logger-interval": {
              "description": "Period, in seconds, with which LongRequestLogger polls worker thread stack traces, or -1 to disable",
              "default": -1,
              "type": "integer"
            },
            "longrequest-logger-timeout": {
              "description": "Transaction duration after which LongRequestLogger will start logging its stack trace, in seconds",
              "default": 1,
              "type": "integer"
            },
157 158
            "large-file-threshold": {
              "description": "Requests bigger than this size get saved into a temporary file instead of being read completely into memory, in bytes",
159
              "default": "10MB",
160 161
              "type": "string"
            },
162 163 164 165 166 167 168
            "port-base": {
              "allOf": [{
                "$ref": "#/definitions/tcpv4port"
              }, {
                "description": "Start allocating ports at this value. Useful if one needs to make several partitions share the same port range (ie, several partitions bound to a single address)",
                "default": 2200
              }]
169
            }
170 171 172 173 174 175 176 177 178
          },
          "type": "object"
        }
      },
      "type": "object"
    },
    "kumofs": {
      "description": "Persistent memcached service",
      "additionalProperties": {
179
        "$ref": "./instance-kumofs-schema.json#/properties"
180 181 182 183 184 185
      },
      "type": "object"
    },
    "memcached": {
      "description": "Volatile memcached service",
      "additionalProperties": {
186
        "$ref": "./instance-kumofs-schema.json#/properties"
187 188 189
      },
      "type": "object"
    },
190 191 192 193
    "cloudooo-url": {
      "description": "Format conversion service URL",
      "pattern": "^https?://",
      "type": "string"
194
    },
195 196 197 198 199
    "cloudooo-retry-count": {
      "description": "Define retry count for cloudooo in network error case in test",
      "type": "integer",
      "default": 2
    },
200 201 202 203 204 205 206
    "smtp": {
      "description": "Mail queuing and relay service",
      "additionalProperties": {
        "$ref": "./instance-smtp-schema.json#/properties"
      },
      "type": "object"
    },
207 208 209
    "mariadb": {
      "description": "Relational database service",
      "additionalProperties": {
210
        "$ref": "./instance-mariadb-schema.json#/properties"
211 212 213
      },
      "type": "object"
    },
214 215 216 217 218 219 220 221 222 223 224 225 226
    "zodb-zeo": {
      "description": "Common settings ZEO servers",
      "properties": {
        "tcpv4-port": {
          "allOf": [{
            "$ref": "#/definitions/tcpv4port"
          }, {
            "description": "Start allocating ports at this value, going upward"
          }]
        },
        "backup-periodicity": {
          "description": "When to backup, specified in the same format as for systemd.time(7) calendar events (years & seconds not supported, DoW & DoM can not be combined). Enter 'never' to disable backups.",
          "default": "daily",
227
          "type": "string"
228
        },
229 230 231
        "tidstorage-repozo-path": {
          "description": "Directory for backup timestamp and tidstorage status files.",
          "default": "~/srv/backup/tidstorage",
232 233 234 235
          "type": "string"
        }
      },
      "type": "object"
236 237
    },
    "zodb": {
238
      "description": "Zope Object DataBase mountpoints. See https://github.com/zopefoundation/ZODB/blob/3.10/src/ZODB/component.xml for extra options.",
239
      "items": {
240
        "required": ["type"],
241 242 243 244 245 246
        "properties": {
          "name": {
            "description": "Database name",
            "default": "main",
            "type": "string"
          },
247
          "mount-point": {
248 249 250 251
            "description": "Mount point",
            "default": "/",
            "type": "string"
          },
252
          "type": {
253
            "description": "Storage type",
254
            "enum": ["zeo", "neo"],
255 256
            "type": "string"
          },
257
          "server": {
258
            "description": "Instantiate a server. If missing, 'storage-dict' must contain the necessary properties to mount the ZODB. For ZEO, the partition reference is 'zodb'. For NEO, they are 'neo-0', 'neo-1', ...",
259
            "anyOf": [
260 261
              {"$ref": "./instance-zeo-schema.json"},
              {"$ref": "../neoppod/instance-neo-input-schema.json"}
262 263
            ]
          },
264
          "storage-dict": {
265
            "description": "Storage configuration. For NEO, 'logfile' is automatically set (see https://lab.nexedi.com/nexedi/neoppod/blob/master/neo/client/component.xml for other settings).",
266 267 268 269 270 271 272
            "properties": {
              "ssl": {
                "description": "For external NEO. Pass false if you want to disable SSL or pass custom values for ca/cert/key.",
                "default": true,
                "type": "boolean"
              }
            },
273
            "additionalProperties": {"type": "string"},
274
            "type": "object"
Vincent Pelletier's avatar
Vincent Pelletier committed
275
          }
276
        },
277
        "additionalProperties": {"type": "string"},
278 279 280
        "type": "object"
      },
      "type": "array"
281 282
    },
    "jupyter": {
283
      "description": "Jupyter subinstance parameters",
284 285
      "properties": {
        "enable": {
286
          "description": "Whether to enable creation of associated Jupyter subinstance",
287 288 289 290 291 292 293 294 295 296
          "default": false,
          "type": "boolean"
        },
        "zope-family": {
          "description": "Zope family to connect Jupyter to by default",
          "default": "<first instantiated Zope family>",
          "type": "string"
        }
      },
      "type": "object"
297 298 299
    },
    "wendelin-core-zblk-fmt": {
      "description": "In wendelin.core there are 2 formats for storing data, so called ZBlk0 and ZBlk1. See https://lab.nexedi.com/nexedi/wendelin.core/blob/2e5e1d3d/bigfile/file_zodb.py#L19 for more details.",
300
      "default": "",
301
      "type": "string"
302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323
    },
    "caucase": {
      "description": "Caucase certificate authority parameters",
      "properties": {
        "url": {
          "title": "Caucase URL",
          "description": "URL of existing caucase instance to use. If empty, a new caucase instance will be deployed. If not empty, other properties in this section will be ignored.",
          "default": "",
          "type": "string",
          "format": "uri"
        },
        "crl-update-periodicity": {
            "title": "Periodicity of CRL update",
            "description": "Periodicity of CRL update, in cron format. The CRL will be downloaded from caucase URL and the new content will be saved if there was a change. Everytime a new CRL is writen, Apache reload will be called.",
            "type": "string",
            "default": "0 0 * * *"
        }
      },
      "additionalProperties": {
        "$ref": "../caucase/instance-caucase-input-schema.json#/properties"
      },
      "type": "object"
324 325 326
    }
  }
}