forked from Telodendria/Telodendria
[WIP/ADD] Start replacing the config with a j2s schema.
Note that this *won't* build as of now.
This commit is contained in:
parent
18488d463e
commit
74ab3f350f
1 changed files with 73 additions and 0 deletions
73
Schema/Config.json
Normal file
73
Schema/Config.json
Normal file
|
@ -0,0 +1,73 @@
|
|||
{
|
||||
"guard": "TELODENDRIA_SCHEMA_CONFIG_H",
|
||||
"header": "Schema\/Config.h",
|
||||
"types": {
|
||||
"ConfigTls": {
|
||||
"fields": {
|
||||
"cert": { "type": "string" },
|
||||
"key": { "type": "string" }
|
||||
},
|
||||
"type": "struct"
|
||||
},
|
||||
"ConfigListener": {
|
||||
"fields": {
|
||||
"port": { "type": "integer", "required": true },
|
||||
"threads": { "type": "integer", "required": false },
|
||||
"maxConnections": { "type": "integer", "required": false },
|
||||
"tls": { "type": "ConfigTls", "required": false }
|
||||
},
|
||||
"type": "struct"
|
||||
},
|
||||
"ConfigRunAs": {
|
||||
"fields": {
|
||||
"uid": { "type": "string", "required": false },
|
||||
"gid": { "type": "string", "required": true }
|
||||
},
|
||||
"type": "struct"
|
||||
},
|
||||
"ConfigLogOutput": {
|
||||
"fields": {
|
||||
"stdout": { "name": "CONFIG_LOG_OUTPUT_STDOUT" },
|
||||
"file": { "name": "CONFIG_LOG_OUTPUT_FILE" },
|
||||
"syslog": { "name": "CONFIG_LOG_OUTPUT_SYSLOG" }
|
||||
},
|
||||
"type": "enum"
|
||||
},
|
||||
"ConfigLogLevel": {
|
||||
"fields": {
|
||||
"message": { "name": "CONFIG_LOG_LEVEL_MESSAGE" },
|
||||
"debug": { "name": "CONFIG_LOG_LEVEL_DEBUG" },
|
||||
"notice": { "name": "CONFIG_LOG_LEVEL_NOTICE" },
|
||||
"warning": { "name": "CONFIG_LOG_LEVEL_WARNING" },
|
||||
"error": { "name": "CONFIG_LOG_LEVEL_ERROR" }
|
||||
},
|
||||
"type": "enum"
|
||||
},
|
||||
"ConfigLogConfig": {
|
||||
"fields": {
|
||||
"output": { "type": "ConfigLogOutput", "required": true },
|
||||
"level": { "type": "ConfigLogLevel", "required": false },
|
||||
"timestampFormat":{ "type": "string", "required": false },
|
||||
"color": { "type": "boolean", "required": false }
|
||||
},
|
||||
"type": "struct"
|
||||
},
|
||||
"Config": {
|
||||
"fields": {
|
||||
"listen": { "type": "[ConfigListener]", "required": true },
|
||||
"runAs": { "type": "ConfigRunAs", "required": false },
|
||||
"log": { "type": "ConfigLogConfig", "required": true },
|
||||
|
||||
"serverName": { "type": "string", "required": true },
|
||||
"baseUrl": { "type": "string", "required": false },
|
||||
"identityServer": { "type": "string", "required": false },
|
||||
|
||||
"maxCache": { "type": "integer", "required": false },
|
||||
|
||||
"federation": { "type": "boolean", "required": true },
|
||||
"registration": { "type": "boolean", "required": true }
|
||||
},
|
||||
"type": "struct"
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue