Commit b19556a8 authored by Łukasz Nowak's avatar Łukasz Nowak

caddy-frontend: Add json autodocumentation

parent 5dc76934
{
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema",
"title": "Input Parameters",
"properties": {
"public-ipv4": {
"title": "Public IPv4",
"description": "Public ipv4 of the frontend (the one Caddy will be indirectly listening to).",
"type": "string"
},
"mpm-graceful-shutdown-timeout": {
"title": "Duration of the graceful shutdown period",
"description": "Value passed to -grace parameter of Caddy, see https://caddyserver.com/docs/cli .",
"type": "integer",
"default": 5
},
"enable-http2-by-default": {
"title": "Enable HTTP2 by Default",
"description": "Use HTTP2 as default Protocol",
"type": "string",
"default": "true",
"enum": ["true", "false"]
},
"re6st-verification-url": {
"title": "Test Verification URL",
"description": "Url to verify if the internet and/or re6stnet is working.",
"type": "string"
},
"-frontend-authorized-slave-string": {
"title": "Authorized Slave String",
"description": "List of SOFTINST-XXX of Slaves, separated by space which is allowed to use custom configuration.",
"type": "string"
},
"apache-key": {
"title": "SSL Key",
"description": "SSL Key used by the server.",
"textarea": true,
"type": "string"
},
"apache-certificate": {
"title": "SSL Certificate",
"description": "SSL Certificate used by the server.",
"textarea": true,
"type": "string"
},
"apache-ca-certificate": {
"title": "[NOT IMPLEMENTED] SSL CA Certificate",
"description": "[NOT IMPLEMENTED] SSL CA Certificate used by the server.",
"textarea": true,
"type": "string"
},
"domain": {
"title": "Domain",
"description": "Base Domain for create subdomains (ie.: example.com).",
"type": "string",
"pattern": "^([a-zA-Z0-9]([a-zA-Z0-9\\-]{0,61}[a-zA-Z0-9])?\\.)+[a-zA-Z]{2,6}$"
},
"nginx-domain": {
"title": "Nginx Domain",
"description": "Base Domain for create subdomains (ie.: example2.com) for websocket, notebook and eventsource.",
"type": "string",
"pattern": "^([a-zA-Z0-9]([a-zA-Z0-9\\-]{0,61}[a-zA-Z0-9])?\\.)+[a-zA-Z]{2,6}$"
},
"-frontend-quantity": {
"title": "Frontend Replication Quantity",
"description": "Quantity of Frontends Replicate.",
"type": "integer"
}
}
}
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Values returned by Caddy Frontend instanciation",
"properties": {
"accepted-slave-amount": {
"description": "Amount of Slaves allocated to the Instance which are deployed",
"type": "integer"
},
"slave-amount": {
"description": "Total amount of Slaves allocated to the Instance (include blocked ones)",
"type": "integer"
},
"reject-slave-amount": {
"description": "Rejected Amount of Slaves allocated to the Instance which are not deployed",
"type": "integer"
},
"rejected-slave-list": {
"description": "List of slave instances references which are rejected",
"type": "array"
},
"domain": {
"description": "Base domain used by the instance",
"type": "string"
},
"monitor-base-url": {
"description": "Base url for monitor",
"type": "string"
},
"monitor-url": {
"description": "Url of Monitor (opml)",
"type": "string"
},
"monitor-password": {
"description": "Password to access the monitor",
"type": "string"
},
"monitor-user": {
"description": "User to access the monitor",
"type": "string"
}
},
"type": "object"
}
{
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema",
"title": "Input Parameters",
"properties": {
"url": {
"title": "Backend URL",
"description": "Url of the backend",
"type": "string",
"pattern": "^(http|https|ftp)://"
},
"https-url": {
"title": "HTTPS Backend URL",
"description": "HTTPS Url of the backend if it is diferent from url parameter",
"type": "string",
"pattern": "^(http|https|ftp)://"
},
"custom_domain": {
"title": "Custom Domain",
"description": "Custom Domain to use for the website",
"type": "string",
"pattern": "^([a-zA-Z0-9]([a-zA-Z0-9\\-]{0,61}[a-zA-Z0-9])?\\.)+[a-zA-Z]{2,6}$"
},
"server-alias": {
"title": "Server Alias",
"description": "Server Alias List separated by space",
"type": "string",
"default": ""
},
"type": {
"title": "Backend Type",
"description": "Type of slave. If redirect, the slave will redirect to the given url. If zope, the rewrite rules will be compatible with Virtual Host Monster. Implemented are default, zope and redirect, not implemneted are notebook and eventsource.",
"type": "string",
"default": "",
"enum": ["", "zope", "redirect", "notebook", "eventsource"]
},
"path": {
"title": "type:zope Backend Path",
"description": "Path to proxy to in the backend",
"type": "string",
"default": ""
},
"default-path": {
"title": "type:zope Default Path",
"description": "Provide default path to redirect user to when user access / (the site root)",
"type": "string",
"default": ""
},
"ssl_crt": {
"title": "SSL Certificate",
"description": "Content of the SSL Certificate file",
"type": "string",
"textarea": true,
"default": ""
},
"ssl_key": {
"title": "SSL Key",
"description": "Content of the SSL Key file",
"type": "string",
"textarea": true,
"default": ""
},
"ssl_ca_crt": {
"title": "[NOT Implemented] SSL Certificate Authority's Certificate",
"description": "[NOT Implemented] Content of the CA certificate file",
"type": "string",
"textarea": true,
"default": ""
},
"https-only": {
"title": "HTTPS Only",
"description": "If set to true, http requests will be redirected to https",
"type": "string",
"default": "false",
"enum": ["false", "true"]
},
"ssl-proxy-verify": {
"title": "[NOT Implemented] Verify Backend Certificates",
"description": "[NOT Implemented] If set to true, Backend SSL Certificates will be checked and frontend will refuse to proxy if certificate is invalid",
"type": "string",
"default": "false",
"enum": ["false", "true"]
},
"ssl_proxy_ca_crt": {
"title": "[NOT Implemented] SSL Backend Authority's Certificate",
"description": "[NOT Implemented] Content of the SSL Certificate Authority file of the backend (to be used with ssl-proxy-verify)",
"type": "string",
"default": ""
},
"monitor-ipv6-test": {
"title": "IPv6 Address to Monitor Packet Lost",
"description": "IPv6 Address for the frontend keep monitoring with ping6 (without brackets)",
"type": "string",
"default": ""
},
"monitor-ipv4-test": {
"title": "IPv4 Address to Monitor Packet Lost",
"description": "IPv4 Address for the frontend keep monitoring with ping",
"type": "string",
"default": ""
},
"re6st-optimal-test": {
"title": "IPv6 and IPv4 Address to test Re6st",
"description": "IPv6 and IPv6 Address for the frontend test if re6st is on the optimal status (use ipv6,ipv4)",
"type": "string",
"default": ""
},
"enable_cache": {
"title": "Enable Cache",
"description": "If set to true, http caching server (Apache Traffic Server) will be used between frontend Caddy and backend",
"type": "string",
"default": "false",
"enum": ["false", "true"]
},
"disable-no-cache-request": {
"title": "enable_cache: Disable 'no-cache' requests",
"description": "If set to true, Cache-Control and Pragma requests headers will not be sent to cache and backend servers. This prevents clients from bypassing cache when enable_cache is true",
"type": "string",
"default": "false",
"enum": ["false", "true"]
},
"disable-via-header": {
"title": "enable_cache: Disable 'Via' headers from cache",
"description": "If set to true, Via response headers will not be sent to client",
"type": "string",
"default": "false",
"enum": ["false", "true"]
},
"enable-http2": {
"title": "Enable HTTP2 Protocol",
"description": "Use HTTP2 Protocol for the site",
"type": "string",
"default": "true",
"enum": ["true", "false"]
},
"prefer-gzip-encoding-to-backend": {
"title": "[NOT Implemented] Prefer gzip Encoding for Backend",
"description": "[NOT Implemented] If set to true, frontend will rewrite Accept-Encoding request header to simply 'gzip' for all variants of Accept-Encoding containing 'gzip', in order to maximize cache hits for resources cached with Vary: Accept-Encoding when enable_cache is used",
"type": "string",
"default": "false",
"enum": ["false", "true"]
},
"disabled-cookie-list": {
"title": "[NOT Implemented] Disabled Cookies",
"description": "[NOT Implemented] List of Cookies separated by space that will not be sent to cache and backend servers. This is especially useful to discard analytics tracking cookies when using Vary: Cookie cache headers",
"type": "string",
"default": ""
},
"apache_custom_http": {
"title": "HTTP configuration",
"description": "Raw http configuration in python template format. Your site will be rejected if you use it without notification and approval of frontend administrators",
"default": "",
"textarea": true,
"type": "string"
},
"apache_custom_https": {
"title": "HTTPS configuration",
"description": "Raw https configuration in python template format. Your site will be rejected if you use it without notification and approval of frontend administrators",
"default": "",
"textarea": true,
"type": "string"
},
"virtualhostroot-http-port": {
"title": "type:zope virtualhostroot-http-port",
"description": "Port where http requests to frontend will be redirected.",
"default": 80,
"type": "integer"
},
"virtualhostroot-https-port": {
"title": "type:zope virtualhostroot-https-port",
"description": "Port where https requests to frontend will be redirected.",
"default": 443,
"type": "integer"
}
}
}
{
"$schema": "http://json-schema.org/draft-04/schema#",
"description": "Values returned by Caddy Frontend instanciation",
"properties": {
"replication_number": {
"description": "Number of nodes the slave is replicated",
"type": "integer"
},
"domain": {
"description": "Base domain used by the instance",
"type": "string"
},
"url": {
"description": "Default URL provided",
"type": "string"
},
"site_url": {
"description": "URL for HTTP access",
"type": "string"
},
"secure_access": {
"description": "URL for HTTP access",
"type": "string"
},
"public-ipv4": {
"description": "Public IPv4 to be included on DNS",
"type": "string"
},
"log-access-url": {
"description": "List of URLs to access logs",
"type": "array"
}
},
"type": "object"
}
{
"name": "Caddy Frontend",
"description": "Caddy Frontend",
"serialisation": "xml",
"software-type": {
"custom-personal-slave": {
"title": "Custom Personal (Slave)",
"description": "Custom Personal",
"request": "instance-slave-caddy-input-schema.json",
"response": "instance-output-schema.json",
"index": 1,
"software-type": "custom-personal",
"shared": true
},
"custom-personal": {
"title": "Custom Personal",
"description": "",
"request": "instance-caddy-input-schema.json",
"response": "instance-output-schema.json",
"index": 2
},
"default": {
"title": "Default",
"software-type": "default",
"description": "Default",
"request": "instance-caddy-input-schema.json",
"response": "instance-output-schema.json",
"index": 3
},
"default-slave": {
"title": "Default (slave)",
"software-type": "default",
"description": "Default",
"request": "instance-slave-caddy-input-schema.json",
"response": "instance-output-schema.json",
"index": 4,
"shared": true
}
}
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment