{ "$schema": "http://json-schema.org/draft-04/schema#", "title": "Generic manifest", "type": "object", "properties": { "provider": { "type": "string" }, "bootstrapper": { "type": "object", "properties": { "workspace": { "$ref": "#/definitions/path" }, "mirror": { "type": "string", "format": "uri" }, "tarball": { "type": "boolean" } }, "required": ["workspace"] }, "image": { "type": "object", "properties": { "name": { "type": "string" } }, "required": ["name"] }, "system": { "type": "object", "properties": { "release": { "enum": ["wheezy", "jessie", "testing", "unstable"] }, "sections": { "type": "array", "minItems": 1 }, "architecture": { "enum": ["i386", "amd64"] }, "bootloader": { "enum": ["pvgrub", "grub", "extlinux"] }, "timezone": { "type": "string" }, "locale": { "type": "string" }, "charmap": { "type": "string" } }, "required": ["release", "architecture", "bootloader", "timezone", "locale", "charmap"] }, "packages": { "type": "object", "properties": { "mirror": { "type": "string", "format": "uri" }, "sources": { "type": "object", "patternProperties": { "^[^\/\\0]+$": { "type": "array", "items": { "type": "string", "pattern": "^(deb|deb-src)\\s+(\\[\\s*(.+\\S)?\\s*\\]\\s+)?\\S+\\s+\\S+(\\s+(.+\\S))?\\s*$" }, "minItems": 1 } }, "additionalProperties": false, "minItems": 1 }, "trusted-keys": { "type": "array", "items": { "$ref": "#/definitions/absolute_path" }, "minItems": 1 }, "install": { "type": "array", "items": { "anyOf": [ { "pattern": "^[^/]+(/[^/]+)?$" }, { "$ref": "#/definitions/absolute_path" } ] }, "minItems": 1 } }, "additionalProperties": false }, "volume": { "type": "object", "properties": { "backing": { "type": "string" }, "partitions": { "type": "object", "oneOf": [ { "$ref": "#/definitions/no_partitions" }, { "$ref": "#/definitions/partition_table" } ] } }, "required": ["partitions"] }, "plugins": { "type": "object", "patternProperties": { "^\\w+$": { "type": "object" } }, "additionalProperties": false } }, "required": ["provider", "bootstrapper", "image", "volume", "system"], "definitions": { "path": { "type": "string", "pattern": "^[^\\0]+$" }, "absolute_path": { "type": "string", "pattern": "^/[^\\0]+$" }, "bytes": { "type": "string", "pattern": "^\\d+([KMGT]i?B|B)$" }, "no_partitions": { "type": "object", "properties": { "type": { "enum": ["none"] }, "root": { "$ref": "#/definitions/partition" } }, "required": ["root"], "additionalProperties": false }, "partition_table": { "type": "object", "properties": { "type": { "enum": ["msdos", "gpt"] }, "boot": { "$ref": "#/definitions/partition" }, "root": { "$ref": "#/definitions/partition" }, "swap": { "type": "object", "properties": { "size": { "$ref": "#/definitions/bytes" } }, "required": ["size"] } }, "required": ["root"], "additionalProperties": false }, "partition": { "type": "object", "properties": { "size": { "$ref": "#/definitions/bytes" }, "filesystem": { "enum": ["ext2", "ext3", "ext4", "xfs"] }, "format_command": { "type": "array", "items": {"type": "string"}, "minItems": 1 } }, "required": ["size", "filesystem"] } }, "required": ["provider", "bootstrapper", "system", "packages", "volume"] }