You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@superset.apache.org by cr...@apache.org on 2022/01/25 23:35:50 UTC

[superset] branch master updated: feat(helm): Add schema of values in Helm Chart (#18161)

This is an automated email from the ASF dual-hosted git repository.

craigrueda pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/superset.git


The following commit(s) were added to refs/heads/master by this push:
     new 6200977  feat(helm): Add schema of values in Helm Chart (#18161)
6200977 is described below

commit 62009773a63b9a149b259135d762102aedaae2b3
Author: Adam Dobrawy <ad...@users.noreply.github.com>
AuthorDate: Wed Jan 26 00:33:39 2022 +0100

    feat(helm): Add schema of values in Helm Chart (#18161)
    
    * Add schema of values in Helm Chart
    
    * chore(helm): bump our Chart version
    
    * Fix schema values in Helm Chart
    
    * fix(helm): fix relax required parameters for postgres & redis password, apply review comments
---
 helm/superset/Chart.yaml         |   2 +-
 helm/superset/values.schema.json | 569 +++++++++++++++++++++++++++++++++++++++
 helm/superset/values.yaml        |   2 +-
 3 files changed, 571 insertions(+), 2 deletions(-)

diff --git a/helm/superset/Chart.yaml b/helm/superset/Chart.yaml
index 1e0b13e..7424f43 100644
--- a/helm/superset/Chart.yaml
+++ b/helm/superset/Chart.yaml
@@ -22,7 +22,7 @@ maintainers:
   - name: craig-rueda
     email: craig@craigrueda.com
     url: https://github.com/craig-rueda
-version: 0.5.4
+version: 0.5.5
 dependencies:
 - name: postgresql
   version: 10.2.0
diff --git a/helm/superset/values.schema.json b/helm/superset/values.schema.json
new file mode 100644
index 0000000..13e695c
--- /dev/null
+++ b/helm/superset/values.schema.json
@@ -0,0 +1,569 @@
+{
+    "$schema": "http://json-schema.org/draft-04/schema#",
+    "type": "object",
+    "additionalProperties": false,
+    "properties": {
+        "replicaCount": {
+            "type": "integer"
+        },
+        "runAsUser": {
+            "type": "integer"
+        },
+        "serviceAccount": {
+            "type": "object",
+            "additionalProperties": false,
+            "properties": {
+                "create": {
+                    "type": "boolean"
+                }
+            },
+            "required": [
+                "create"
+            ]
+        },
+        "bootstrapScript": {
+            "type": "string"
+        },
+        "configFromSecret": {
+            "type": "string"
+        },
+        "envFromSecret": {
+            "type": "string"
+        },
+        "envFromSecrets": {
+            "type": "array"
+        },
+        "extraEnv": {
+            "type": "object"
+        },
+        "extraEnvRaw": {
+            "type": "array"
+        },
+        "extraSecretEnv": {
+            "type": "object"
+        },
+        "extraConfigs": {
+            "type": "object"
+        },
+        "extraSecrets": {
+            "type": "object"
+        },
+        "extraVolumes": {
+            "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.apps.v1.PodSpec/properties/volumes"
+        },
+        "extraVolumeMounts": {
+            "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.apps.v1.PodSpec/properties/volumeMounts"
+        },
+        "configOverrides": {
+            "type": "object",
+            "additionalProperties": {
+                "type": "string"
+            },
+            "properties": {
+                "extend_timeout": {
+                    "type": "string"
+                },
+                "enable_oauth": {
+                    "type": "string"
+                }
+            }
+        },
+        "configOverridesFiles": {
+            "type": "object",
+            "additionalProperties": {
+                "type": "string"
+            },
+            "properties": {
+                "extend_timeout": {
+                    "type": "string"
+                },
+                "enable_oauth": {
+                    "type": "string"
+                }
+            }
+        },
+        "configMountPath": {
+            "type": "string"
+        },
+        "extraConfigMountPath": {
+            "type": "string"
+        },
+        "image": {
+            "type": "object",
+            "additionalProperties": false,
+            "properties": {
+                "repository": {
+                    "type": "string"
+                },
+                "tag": {
+                    "type": "string"
+                },
+                "pullPolicy": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.Container/properties/imagePullPolicy"
+                }
+            },
+            "required": [
+                "repository",
+                "tag",
+                "pullPolicy"
+            ]
+        },
+        "imagePullSecrets": {
+            "type": "array"
+        },
+        "service": {
+            "type": "object",
+            "additionalProperties": false,
+            "properties": {
+                "type": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.ServiceSpec/properties/type"
+                },
+                "port": {
+                    "type": "integer"
+                },
+                "annotations": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta/properties/annotations"
+                },
+                "loadBalancerIP": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.ServiceSpec/properties/loadBalancerIP"
+                }
+            },
+            "required": [
+                "type",
+                "port"
+            ]
+        },
+        "ingress": {
+            "type": "object",
+            "additionalProperties": false,
+            "properties": {
+                "enabled": {
+                    "type": "boolean"
+                },
+                "annotations": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta/properties/annotations"
+                },
+                "path": {
+                    "type": "string"
+                },
+                "pathType": {
+                    "type": "string"
+                },
+                "hosts": {
+                    "type": "array",
+                    "items": {
+                        "type": "string"
+                    }
+                },
+                "tls": {
+                    "type": "array",
+                    "items": {
+                        "type": "object",
+                        "additionalProperties": false,
+                        "properties": {
+                            "secretName": {
+                                "type": "string"
+                            },
+                            "hosts": {
+                                "type": "array",
+                                "items": {
+                                    "type": "string"
+                                }
+                            }
+                        }
+                    }
+                }
+            },
+            "required": [
+                "enabled",
+                "annotations",
+                "path",
+                "pathType",
+                "hosts",
+                "tls"
+            ]
+        },
+        "resources": {
+            "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.Container/properties/resources"
+        },
+        "hostAliases": {
+            "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.PodSpec/properties/hostAliases"
+        },
+        "supersetNode": {
+            "type": "object",
+            "additionalProperties": false,
+            "properties": {
+                "command": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.Container/properties/command"
+                },
+                "connections": {
+                    "type": "object",
+                    "additionalProperties": false,
+                    "properties": {
+                        "redis_host": {
+                            "type": "string"
+                        },
+                        "redis_port": {
+                            "type": "string"
+                        },
+                        "db_host": {
+                            "type": "string"
+                        },
+                        "db_port": {
+                            "type": "string"
+                        },
+                        "db_user": {
+                            "type": "string"
+                        },
+                        "db_pass": {
+                            "type": "string"
+                        },
+                        "db_name": {
+                            "type": "string"
+                        }
+                    },
+                    "required": [
+                        "redis_host",
+                        "redis_port",
+                        "db_host",
+                        "db_port",
+                        "db_user",
+                        "db_pass",
+                        "db_name"
+                    ]
+                },
+                "env": {
+                    "type": "object"
+                },
+                "forceReload": {
+                    "type": "boolean"
+                },
+                "initContainers": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.PodSpec/properties/initContainers"
+                },
+                "deploymentAnnotations": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta/properties/annotations"
+                },
+                "podAnnotations": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta/properties/annotations"
+                }
+            },
+            "required": [
+                "command",
+                "connections",
+                "env",
+                "forceReload"
+            ]
+        },
+        "supersetWorker": {
+            "type": "object",
+            "additionalProperties": false,
+            "properties": {
+                "command": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.Container/properties/command"
+                },
+                "forceReload": {
+                    "type": "boolean"
+                },
+                "initContainers": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.PodSpec/properties/initContainers"
+                },
+                "deploymentAnnotations": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta/properties/annotations"
+                },
+                "podAnnotations": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta/properties/annotations"
+                }
+            },
+            "required": [
+                "command",
+                "forceReload"
+            ]
+        },
+        "supersetCeleryBeat": {
+            "type": "object",
+            "additionalProperties": false,
+            "properties": {
+                "enabled": {
+                    "type": "boolean"
+                },
+                "command": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.Container/properties/command"
+                },
+                "forceReload": {
+                    "type": "boolean"
+                },
+                "initContainers": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.PodSpec/properties/initContainers"
+                },
+                "deploymentAnnotations": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta/properties/annotations"
+                },
+                "podAnnotations": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta/properties/annotations"
+                }
+            },
+            "required": [
+                "enabled",
+                "command",
+                "forceReload"
+            ]
+        },
+        "init": {
+            "type": "object",
+            "additionalProperties": false,
+            "properties": {
+                "resources": {
+                    "type": "object"
+                },
+                "command": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.Container/properties/command"
+                },
+                "enabled": {
+                    "type": "boolean"
+                },
+                "loadExamples": {
+                    "type": "boolean"
+                },
+                "createAdmin": {
+                    "type": "boolean"
+                },
+                "adminUser": {
+                    "type": "object",
+                    "additionalProperties": false,
+                    "properties": {
+                        "username": {
+                            "type": "string"
+                        },
+                        "firstname": {
+                            "type": "string"
+                        },
+                        "lastname": {
+                            "type": "string"
+                        },
+                        "email": {
+                            "type": "string"
+                        },
+                        "password": {
+                            "type": "string"
+                        }
+                    },
+                    "required": [
+                        "username",
+                        "firstname",
+                        "lastname",
+                        "email",
+                        "password"
+                    ]
+                },
+                "initContainers": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.core.v1.PodSpec/properties/initContainers"
+                },
+                "initscript": {
+                    "type": "string"
+                },
+                "podAnnotations": {
+                    "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta/properties/annotations"
+                }
+            },
+            "required": [
+                "resources",
+                "command",
+                "enabled",
+                "loadExamples",
+                "createAdmin",
+                "adminUser",
+                "initscript"
+            ]
+        },
+        "postgresql": {
+            "type": "object",
+            "additionalProperties": true,
+            "properties": {
+                "enabled": {
+                    "type": "boolean"
+                },
+                "existingSecret": {
+                    "type": [
+                        "string",
+                        "null"
+                    ]
+                },
+                "existingSecretKey": {
+                    "type": [
+                        "string",
+                        "null"
+                    ]
+                },
+                "service": {
+                    "type": "object",
+                    "additionalProperties": true,
+                    "properties": {
+                        "port": {
+                            "type": "integer"
+                        }
+                    },
+                    "required": [
+                        "port"
+                    ]
+                },
+                "postgresqlUsername": {
+                    "type": "string"
+                },
+                "postgresqlPassword": {
+                    "type": "string"
+                },
+                "postgresqlDatabase": {
+                    "type": "string"
+                },
+                "persistence": {
+                    "type": "object",
+                    "additionalProperties": true,
+                    "properties": {
+                        "enabled": {
+                            "type": "boolean"
+                        },
+                        "accessModes": {
+                            "type": "array",
+                            "items": [
+                                {
+                                    "type": "string"
+                                }
+                            ]
+                        }
+                    },
+                    "required": [
+                        "enabled",
+                        "accessModes"
+                    ]
+                }
+            },
+            "required": [
+                "enabled",
+                "service",
+                "postgresqlUsername",
+                "postgresqlDatabase",
+                "persistence"
+            ]
+        },
+        "redis": {
+            "type": "object",
+            "additionalProperties": true,
+            "properties": {
+                "enabled": {
+                    "type": "boolean"
+                },
+                "usePassword": {
+                    "type": "boolean"
+                },
+                "existingSecret": {
+                    "type": [
+                        "string",
+                        "null"
+                    ]
+                },
+                "existingSecretKey": {
+                    "type": [
+                        "string",
+                        "null"
+                    ]
+                },
+                "password": {
+                    "type": "string"
+                },
+                "master": {
+                    "type": "object",
+                    "additionalProperties": true,
+                    "properties": {
+                        "persistence": {
+                            "type": "object",
+                            "additionalProperties": true,
+                            "properties": {
+                                "enabled": {
+                                    "type": "boolean"
+                                },
+                                "accessModes": {
+                                    "type": "array",
+                                    "items": [
+                                        {
+                                            "type": "string"
+                                        }
+                                    ]
+                                }
+                            },
+                            "required": [
+                                "enabled",
+                                "accessModes"
+                            ]
+                        }
+                    },
+                    "required": [
+                        "persistence"
+                    ]
+                },
+                "cluster": {
+                    "type": "object",
+                    "additionalProperties": true,
+                    "properties": {
+                        "enabled": {
+                            "type": "boolean"
+                        }
+                    },
+                    "required": [
+                        "enabled"
+                    ]
+                }
+            },
+            "required": [
+                "enabled",
+                "usePassword",
+                "master",
+                "cluster"
+            ]
+        },
+        "nodeSelector": {
+            "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.apps.v1.PodSpec/properties/nodeSelector"
+        },
+        "tolerations": {
+            "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json##/definitions/io.k8s.api.apps.v1.PodSpec/properties/tolerations"
+        },
+        "affinity": {
+            "$ref": "https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master/v1.23.0/_definitions.json#/definitions/io.k8s.api.core.v1.Affinity"
+        }
+    },
+    "required": [
+        "replicaCount",
+        "runAsUser",
+        "serviceAccount",
+        "bootstrapScript",
+        "configFromSecret",
+        "envFromSecret",
+        "envFromSecrets",
+        "extraEnv",
+        "extraEnvRaw",
+        "extraSecretEnv",
+        "extraConfigs",
+        "extraSecrets",
+        "extraVolumes",
+        "extraVolumeMounts",
+        "configOverrides",
+        "configOverridesFiles",
+        "configMountPath",
+        "extraConfigMountPath",
+        "image",
+        "imagePullSecrets",
+        "service",
+        "ingress",
+        "resources",
+        "hostAliases",
+        "supersetNode",
+        "supersetWorker",
+        "supersetCeleryBeat",
+        "init",
+        "postgresql",
+        "redis",
+        "nodeSelector",
+        "tolerations",
+        "affinity"
+    ]
+}
diff --git a/helm/superset/values.yaml b/helm/superset/values.yaml
index e5eb9a5..a30323f 100644
--- a/helm/superset/values.yaml
+++ b/helm/superset/values.yaml
@@ -149,7 +149,7 @@ configOverrides: {}
   #   # The default user self registration role
   #   AUTH_USER_REGISTRATION_ROLE = "Admin"
 # Same as above but the values are files
-configOverridesFiles:
+configOverridesFiles: {}
   # extend_timeout: extend_timeout.py
   # enable_oauth: enable_oauth.py