mirror of
https://github.com/yusing/godoxy.git
synced 2026-03-28 11:51:53 +01:00
preparing for v0.5
This commit is contained in:
@@ -8,31 +8,63 @@
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"email": {
|
||||
"description": "ACME Email",
|
||||
"title": "ACME Email",
|
||||
"type": "string",
|
||||
"pattern": "^[\\w-\\.]+@([\\w-]+\\.)+[\\w-]{2,4}$",
|
||||
"patternErrorMessage": "Invalid email"
|
||||
},
|
||||
"domains": {
|
||||
"description": "Cert Domains",
|
||||
"title": "Cert Domains",
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"minItems": 1
|
||||
},
|
||||
"cert_path": {
|
||||
"title": "path of cert file to load/store",
|
||||
"description": "default: certs/cert.crt",
|
||||
"type": "string"
|
||||
},
|
||||
"key_path": {
|
||||
"title": "path of key file to load/store",
|
||||
"description": "default: certs/priv.key",
|
||||
"type": "string"
|
||||
},
|
||||
"provider": {
|
||||
"description": "DNS Challenge Provider",
|
||||
"title": "DNS Challenge Provider",
|
||||
"type": "string",
|
||||
"enum": ["cloudflare", "clouddns", "duckdns"]
|
||||
"enum": [
|
||||
"local",
|
||||
"cloudflare",
|
||||
"clouddns",
|
||||
"duckdns"
|
||||
]
|
||||
},
|
||||
"options": {
|
||||
"description": "Provider specific options",
|
||||
"title": "Provider specific options",
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": ["email", "domains", "provider", "options"],
|
||||
"allOf": [
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
"provider": {
|
||||
"not": true,
|
||||
"const": "local"
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"required": [
|
||||
"email",
|
||||
"domains",
|
||||
"provider",
|
||||
"options"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
@@ -44,7 +76,9 @@
|
||||
"then": {
|
||||
"properties": {
|
||||
"options": {
|
||||
"required": ["auth_token"],
|
||||
"required": [
|
||||
"auth_token"
|
||||
],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"auth_token": {
|
||||
@@ -67,7 +101,11 @@
|
||||
"then": {
|
||||
"properties": {
|
||||
"options": {
|
||||
"required": ["client_id", "email", "password"],
|
||||
"required": [
|
||||
"client_id",
|
||||
"email",
|
||||
"password"
|
||||
],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"client_id": {
|
||||
@@ -98,7 +136,9 @@
|
||||
"then": {
|
||||
"properties": {
|
||||
"options": {
|
||||
"required": ["token"],
|
||||
"required": [
|
||||
"token"
|
||||
],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"token": {
|
||||
@@ -123,13 +163,19 @@
|
||||
"kind": {
|
||||
"description": "Proxy provider kind",
|
||||
"type": "string",
|
||||
"enum": ["docker", "file"]
|
||||
"enum": [
|
||||
"docker",
|
||||
"file"
|
||||
]
|
||||
},
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["kind", "value"],
|
||||
"required": [
|
||||
"kind",
|
||||
"value"
|
||||
],
|
||||
"allOf": [
|
||||
{
|
||||
"if": {
|
||||
@@ -190,5 +236,7 @@
|
||||
}
|
||||
},
|
||||
"additionalProperties": false,
|
||||
"required": ["providers"]
|
||||
}
|
||||
"required": [
|
||||
"providers"
|
||||
]
|
||||
}
|
||||
@@ -3,10 +3,10 @@
|
||||
"title": "go-proxy providers file",
|
||||
"anyOf": [
|
||||
{
|
||||
"type":"object"
|
||||
"type": "object"
|
||||
},
|
||||
{
|
||||
"type":"null"
|
||||
"type": "null"
|
||||
}
|
||||
],
|
||||
"patternProperties": {
|
||||
@@ -19,11 +19,20 @@
|
||||
"anyOf": [
|
||||
{
|
||||
"type": "string",
|
||||
"enum": ["http", "https", "tcp", "udp"]
|
||||
"enum": [
|
||||
"http",
|
||||
"https",
|
||||
"tcp",
|
||||
"udp",
|
||||
"tcp:tcp",
|
||||
"udp:udp",
|
||||
"tcp:udp",
|
||||
"udp:tcp"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "null",
|
||||
"description": "HTTP proxy"
|
||||
"description": "Auto detect base on port number"
|
||||
}
|
||||
]
|
||||
},
|
||||
@@ -50,8 +59,9 @@
|
||||
"port": {
|
||||
"title": "Proxy port"
|
||||
},
|
||||
"path": {},
|
||||
"path_mode": {},
|
||||
"path": {
|
||||
"title": "Proxy path pattern (See https://pkg.go.dev/net/http#ServeMux)"
|
||||
},
|
||||
"no_tls_verify": {
|
||||
"description": "Disable TLS verification for https proxy",
|
||||
"type": "boolean"
|
||||
@@ -59,7 +69,9 @@
|
||||
"set_headers": {},
|
||||
"hide_headers": {}
|
||||
},
|
||||
"required": ["host"],
|
||||
"required": [
|
||||
"host"
|
||||
],
|
||||
"additionalProperties": false,
|
||||
"allOf": [
|
||||
{
|
||||
@@ -68,7 +80,10 @@
|
||||
{
|
||||
"properties": {
|
||||
"scheme": {
|
||||
"enum": ["http", "https"]
|
||||
"enum": [
|
||||
"http",
|
||||
"https"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -119,19 +134,6 @@
|
||||
}
|
||||
]
|
||||
},
|
||||
"path_mode": {
|
||||
"anyOf": [
|
||||
{
|
||||
"description": "Proxy path mode (forward, sub, empty)",
|
||||
"type": "string",
|
||||
"enum": ["", "forward", "sub"]
|
||||
},
|
||||
{
|
||||
"description": "Default proxy path mode (sub)",
|
||||
"type": "null"
|
||||
}
|
||||
]
|
||||
},
|
||||
"set_headers": {
|
||||
"type": "object",
|
||||
"description": "Proxy headers to set",
|
||||
@@ -143,7 +145,7 @@
|
||||
}
|
||||
},
|
||||
"hide_headers": {
|
||||
"type":"array",
|
||||
"type": "array",
|
||||
"description": "Proxy headers to hide",
|
||||
"items": {
|
||||
"type": "string"
|
||||
@@ -154,17 +156,14 @@
|
||||
"else": {
|
||||
"properties": {
|
||||
"port": {
|
||||
"markdownDescription": "`listening port`:`target port | service type`",
|
||||
"markdownDescription": "`listening port`:`proxy port | service name`",
|
||||
"type": "string",
|
||||
"pattern": "^[0-9]+\\:[0-9a-z]+$",
|
||||
"patternErrorMessage": "'port' must be in the format of '<listening port>:<target port | service type>'"
|
||||
"patternErrorMessage": "'port' must be in the format of '<listening port>:<proxy port | service name>'"
|
||||
},
|
||||
"path": {
|
||||
"not": true
|
||||
},
|
||||
"path_mode": {
|
||||
"not": true
|
||||
},
|
||||
"set_headers": {
|
||||
"not": true
|
||||
},
|
||||
@@ -172,7 +171,9 @@
|
||||
"not": true
|
||||
}
|
||||
},
|
||||
"required": ["port"]
|
||||
"required": [
|
||||
"port"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -197,4 +198,4 @@
|
||||
}
|
||||
},
|
||||
"additionalProperties": false
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user