Skip to content

Commit

Permalink
schema conditions
Browse files Browse the repository at this point in the history
  • Loading branch information
donavanbecker committed Feb 2, 2024
1 parent 48a1dc8 commit 71386d7
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 35 deletions.
35 changes: 25 additions & 10 deletions config.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,36 +9,48 @@
"schema": {
"type": "object",
"properties": {
"acceptCloudflareNotice": {
"type": "boolean",
"title": "Auto Start Tunnel Install",
"required": true,
"description": "Automatically start the Cloudflared Tunnel install process."
},
"name": {
"type": "string",
"title": "Name",
"default": "CloudflaredTunnel",
"required": true
},
"acceptCloudflareNotice": {
"type": "boolean",
"title": "Auto Start Tunnel Install",
"required": true,
"description": "Automatically start the Cloudflared Tunnel install process.",
"condition": {
"functionBody": "return (model.url || model.port || model.hostname || model.protocol);"
}
},
"url": {
"type": "string",
"title": "URL",
"placeholder": "http://localhost:8581",
"pattern": "^https?://",
"required": false
"required": false,
"condition": {
"functionBody": "return (model.acceptCloudflareNotice);"
}
},
"port": {
"type": "number",
"title": "Port",
"placeholder": "8581",
"required": false
"required": false,
"condition": {
"functionBody": "return (model.acceptCloudflareNotice);"
}
},
"hostname": {
"type": "string",
"title": "hostname",
"placeholder": "homebridge.local",
"required": true
"required": true,
"condition": {
"functionBody": "return (model.acceptCloudflareNotice);"
}
},
"protocol": {
"type": "string",
Expand All @@ -54,7 +66,10 @@
"title": "HTTPS",
"enum": ["https"]
}
]
],
"condition": {
"functionBody": "return (model.acceptCloudflareNotice);"
}
},
"verifyTLS": {
"type": "boolean",
Expand Down
48 changes: 24 additions & 24 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
"untun": "^0.1.3"
},
"devDependencies": {
"@types/node": "^20.11.13",
"@types/node": "^20.11.16",
"@typescript-eslint/eslint-plugin": "^6.20.0",
"@typescript-eslint/parser": "^6.20.0",
"eslint": "^8.56.0",
Expand Down

0 comments on commit 71386d7

Please sign in to comment.