Helm UI schema

This commit is contained in:
Laszlo Fogas
2020-11-17 13:13:11 +01:00
parent 0d4f3c1150
commit 898316874e
7 changed files with 249 additions and 79 deletions
+1 -1
View File
@@ -15,4 +15,4 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.8.2
version: 0.9.0
+82
View File
@@ -0,0 +1,82 @@
[
{
"schemaIDs": [
"#/properties/image",
"#/properties/containerPort",
"#/properties/replicas"
],
"uiSchema": {
"#/properties/replicas": {
"ui:widget": "range"
}
},
"metaData": {
"name": "Basics",
"icon": "M17 8l4 4m0 0l-4 4m4-4H3"
}
},
{
"schemaIDs": [
"#/properties/resources"
],
"uiSchema": {
},
"metaData": {
"name": "Resources",
"icon": "M9 7h6m0 10v-3m-3 3h.01M9 17h.01M9 14h.01M12 14h.01M15 11h.01M12 11h.01M9 11h.01M7 21h10a2 2 0 002-2V5a2 2 0 00-2-2H7a2 2 0 00-2 2v14a2 2 0 002 2z"
}
},
{
"schemaIDs": [
"#/properties/probe"
],
"uiSchema": {
},
"metaData": {
"name": "Health",
"icon": "M4.318 6.318a4.5 4.5 0 000 6.364L12 20.364l7.682-7.682a4.5 4.5 0 00-6.364-6.364L12 7.636l-1.318-1.318a4.5 4.5 0 00-6.364 0z"
}
},
{
"schemaIDs": [
"#/properties/vars"
],
"uiSchema": {
"#/properties/vars": {
"additionalProperties": {
"type": "string"
}
}
},
"metaData": {
"name": "Environment Variables",
"icon": "M12 8c-1.657 0-3 .895-3 2s1.343 2 3 2 3 .895 3 2-1.343 2-3 2m0-8c1.11 0 2.08.402 2.599 1M12 8V7m0 1v8m0 0v1m0-1c-1.11 0-2.08-.402-2.599-1M21 12a9 9 0 11-18 0 9 9 0 0118 0z"
}
},
{
"schemaIDs": [
"#/properties/sealedSecrets"
],
"uiSchema": {
"#/properties/sealedSecrets": {
"additionalProperties": {
"type": "string"
}
}
},
"metaData": {
"name": "Sealed Secrets",
"icon": "M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z"
}
},
{
"schemaIDs": [
"#/properties/ingress"
],
"uiSchema": {},
"metaData": {
"name": "Host Names",
"icon": "M13.828 10.172a4 4 0 00-5.656 0l-4 4a4 4 0 105.656 5.656l1.102-1.101m-.758-4.899a4 4 0 005.656 0l4-4a4 4 0 00-5.656-5.656l-1.1 1.1"
}
}
]
+131 -53
View File
@@ -48,8 +48,8 @@
"image": {
"$id": "#/properties/image",
"type": "object",
"title": "The image schema",
"description": "An explanation about the purpose of this instance.",
"title": "Image",
"description": "The image to deploy",
"default": {},
"examples": [
{
@@ -65,9 +65,9 @@
"repository": {
"$id": "#/properties/image/properties/repository",
"type": "string",
"title": "The repository schema",
"description": "An explanation about the purpose of this instance.",
"default": "",
"title": "Repository",
"description": "",
"default": "nginx",
"examples": [
"nginx"
]
@@ -75,22 +75,23 @@
"tag": {
"$id": "#/properties/image/properties/tag",
"type": "string",
"title": "The tag schema",
"description": "An explanation about the purpose of this instance.",
"default": "",
"title": "Tag",
"description": "",
"default": "1.19.3",
"examples": [
"latest"
]
}
},
"additionalProperties": true
}
},
"replicas": {
"$id": "#/properties/replicas",
"type": "integer",
"title": "The replicas schema",
"description": "An explanation about the purpose of this instance.",
"default": 0,
"title": "Replicas",
"description": "",
"default": 1,
"minimum": 0,
"maximum": 16,
"examples": [
1
]
@@ -170,9 +171,9 @@
"containerPort": {
"$id": "#/properties/containerPort",
"type": "integer",
"title": "The containerPort schema",
"description": "An explanation about the purpose of this instance.",
"default": 0,
"title": "Port",
"description": "The port your app is listening on",
"default": 80,
"examples": [
80
]
@@ -180,8 +181,8 @@
"resources": {
"$id": "#/properties/resources",
"type": "object",
"title": "The resources schema",
"description": "An explanation about the purpose of this instance.",
"title": "",
"description": "",
"default": {},
"examples": [
{
@@ -195,16 +196,13 @@
}
}
],
"required": [
"requests",
"limits"
],
"required": [],
"properties": {
"requests": {
"$id": "#/properties/resources/properties/requests",
"type": "object",
"title": "The requests schema",
"description": "An explanation about the purpose of this instance.",
"title": "Requests",
"description": "The typical resources your app uses",
"default": {},
"examples": [
{
@@ -220,9 +218,9 @@
"cpu": {
"$id": "#/properties/resources/properties/requests/properties/cpu",
"type": "string",
"title": "The cpu schema",
"description": "An explanation about the purpose of this instance.",
"default": "",
"title": "CPU",
"description": "",
"default": "200m",
"examples": [
"200m"
]
@@ -230,21 +228,20 @@
"memory": {
"$id": "#/properties/resources/properties/requests/properties/memory",
"type": "string",
"title": "The memory schema",
"description": "An explanation about the purpose of this instance.",
"default": "",
"title": "Memory",
"description": "",
"default": "200Mi",
"examples": [
"200mi"
]
}
},
"additionalProperties": true
}
},
"limits": {
"$id": "#/properties/resources/properties/limits",
"type": "object",
"title": "The limits schema",
"description": "An explanation about the purpose of this instance.",
"title": "Limits",
"description": "The maximum resources your app may use",
"default": {},
"examples": [
{
@@ -260,9 +257,9 @@
"cpu": {
"$id": "#/properties/resources/properties/limits/properties/cpu",
"type": "string",
"title": "The cpu schema",
"description": "An explanation about the purpose of this instance.",
"default": "",
"title": "CPU",
"description": "The hard ceiling for the app's CPU usage. The app will be throttled to this limit. 1000m or 1000 CPU shares = 1 CPU core",
"default": "200m",
"examples": [
"200m"
]
@@ -270,18 +267,16 @@
"memory": {
"$id": "#/properties/resources/properties/limits/properties/memory",
"type": "string",
"title": "The memory schema",
"description": "An explanation about the purpose of this instance.",
"default": "",
"title": "Memory",
"description": "The hard ceiling for the app's memory usage. The app will be RESTARTED if it reaches this limit",
"default": "200Mi",
"examples": [
"200mi"
]
}
},
"additionalProperties": true
}
}
},
"additionalProperties": true
}
},
"nodeSelector": {
"$id": "#/properties/nodeSelector",
@@ -324,8 +319,8 @@
"probe": {
"$id": "#/properties/probe",
"type": "object",
"title": "The probe schema",
"description": "An explanation about the purpose of this instance.",
"title": "Healthcheck",
"description": "The Kubernetes Readiness probe that determines whether your app is healthy and if should receive traffic",
"default": {},
"examples": [
{
@@ -341,8 +336,8 @@
"enabled": {
"$id": "#/properties/probe/properties/enabled",
"type": "boolean",
"title": "The enabled schema",
"description": "An explanation about the purpose of this instance.",
"title": "",
"description": "",
"default": false,
"examples": [
false
@@ -351,15 +346,14 @@
"path": {
"$id": "#/properties/probe/properties/path",
"type": "string",
"title": "The path schema",
"description": "An explanation about the purpose of this instance.",
"default": "",
"title": "Path",
"description": "The web endpoint that returns HTTP 200 if your application is healthy",
"default": "/",
"examples": [
"/"
]
}
},
"additionalProperties": true
}
},
"secret": {
"$id": "#/properties/secret",
@@ -398,6 +392,90 @@
"examples": [
"/bin/sh"
]
},
"vars": {
"$id": "#/properties/vars",
"type": "object",
"title": "Environment variables",
"description": "",
"default": {},
"examples": [
{
"VAR_1": "value 1",
"VAR_2": "value 2"
}
],
"required": [],
"properties": {},
"additionalProperties": true
},
"sealedSecrets": {
"$id": "#/properties/sealedSecrets",
"type": "object",
"title": "Sealed Secrets",
"description": "",
"default": {},
"examples": [
{
"VAR_1": "value 1",
"VAR_2": "value 2"
}
],
"required": [],
"properties": {},
"additionalProperties": true
},
"ingress": {
"$id": "#/properties/ingress",
"type": "object",
"title": "Incoming traffic",
"description": "",
"default": {},
"examples": [
{
"tlsEnabled": false,
"annotations": {
"kubernetes.io/ingress.class": "nginx"
},
"host": "my-release.mycompany.com"
}
],
"required": [],
"properties": {
"host": {
"$id": "#/properties/ingress/properties/host",
"type": "string",
"title": "Host Name",
"description": "Where your application will be accessible",
"default": "",
"examples": [
"my-release.mycompany.com"
]
},
"tlsEnabled": {
"$id": "#/properties/ingress/properties/tlsEnabled",
"type": "boolean",
"title": "HTTPS",
"description": "",
"default": false,
"examples": [
false
]
},
"annotations": {
"$id": "#/properties/ingress/properties/annotations",
"type": "object",
"title": "Annotations",
"description": "",
"default": {},
"examples": [
{
"kubernetes.io/ingress.class": "nginx"
}
],
"additionalProperties": true
}
}
}
},
"additionalProperties": true