Perform schema validation

Define a schema that we can pass to jsonschema to validate against the
config a user has supplied. This will help catch a wide variety of common
errors that occur.

If the config does not pass schema validation then it raises an exception
and prints out human readable reasons.

Signed-off-by: Mazz Mosley <mazz@houseofmnowster.com>
This commit is contained in:
Mazz Mosley 2015-07-27 15:15:07 +01:00
commit da36ee7cbc
8 changed files with 175 additions and 75 deletions

View file

@ -33,6 +33,7 @@ install_requires = [
'docker-py >= 1.3.1, < 1.4',
'dockerpty >= 0.3.4, < 0.4',
'six >= 1.3.0, < 2',
'jsonschema >= 2.5.1, < 3',
]