Skip to content

Commit

Permalink
Fix schema generation for inline elements
Browse files Browse the repository at this point in the history
Signed-off-by: David Gageot <[email protected]>
  • Loading branch information
dgageot committed Feb 20, 2019
1 parent 601a014 commit 9d59806
Show file tree
Hide file tree
Showing 11 changed files with 437 additions and 114 deletions.
26 changes: 19 additions & 7 deletions docs/content/en/schemas/v1alpha1.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"type": "object",
"oneOf": [
"anyOf": [
{
"$ref": "#/definitions/SkaffoldPipeline"
}
Expand All @@ -23,6 +23,7 @@
"$ref": "#/definitions/DeployConfig"
}
},
"additionalProperties": false,
"description": "top level config object that is parsed from a skaffold.yaml"
},
"BuildConfig": {
Expand All @@ -38,7 +39,8 @@
"default": "\"\""
}
},
"oneOf": [
"additionalProperties": false,
"anyOf": [
{
"properties": {
"local": {
Expand All @@ -65,6 +67,7 @@
"$ref": "#/definitions/GoogleCloudBuild"
}
},
"additionalProperties": false,
"description": "contains the specific implementation and parameters needed for the build step. Only one field should be populated."
},
"LocalBuild": {
Expand All @@ -73,6 +76,7 @@
"type": "boolean"
}
},
"additionalProperties": false,
"description": "contains the fields needed to do a build on the local docker daemon and optionally push to a repository."
},
"GoogleCloudBuild": {
Expand All @@ -81,7 +85,8 @@
"type": "string",
"default": "\"\""
}
}
},
"additionalProperties": false
},
"DeployConfig": {
"properties": {
Expand All @@ -90,7 +95,8 @@
"default": "\"\""
}
},
"oneOf": [
"additionalProperties": false,
"anyOf": [
{
"properties": {
"helm": {
Expand All @@ -117,6 +123,7 @@
"$ref": "#/definitions/KubectlDeploy"
}
},
"additionalProperties": false,
"description": "contains the specific implementation and parameters needed for the deploy step. Only one field should be populated."
},
"KubectlDeploy": {
Expand All @@ -128,6 +135,7 @@
"type": "array"
}
},
"additionalProperties": false,
"description": "contains the configuration needed for deploying with <code>kubectl apply</code>"
},
"Manifest": {
Expand All @@ -148,7 +156,8 @@
"type": "object",
"default": "{}"
}
}
},
"additionalProperties": false
},
"HelmDeploy": {
"properties": {
Expand All @@ -158,7 +167,8 @@
},
"type": "array"
}
}
},
"additionalProperties": false
},
"HelmRelease": {
"properties": {
Expand Down Expand Up @@ -190,7 +200,8 @@
"type": "string",
"default": "\"\""
}
}
},
"additionalProperties": false
},
"Artifact": {
"properties": {
Expand All @@ -214,6 +225,7 @@
"default": "{}"
}
},
"additionalProperties": false,
"description": "represents items that need should be built, along with the context in which they should be built."
}
}
Expand Down
52 changes: 40 additions & 12 deletions docs/content/en/schemas/v1alpha2.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"type": "object",
"oneOf": [
"anyOf": [
{
"$ref": "#/definitions/SkaffoldPipeline"
}
Expand Down Expand Up @@ -28,7 +28,8 @@
},
"type": "array"
}
}
},
"additionalProperties": false
},
"BuildConfig": {
"properties": {
Expand All @@ -42,7 +43,8 @@
"$ref": "#/definitions/TagPolicy"
}
},
"oneOf": [
"additionalProperties": false,
"anyOf": [
{
"properties": {
"local": {
Expand Down Expand Up @@ -82,12 +84,15 @@
"$ref": "#/definitions/DateTimeTagger"
}
},
"additionalProperties": false,
"description": "contains all the configuration for the tagging step"
},
"ShaTagger": {
"additionalProperties": false,
"description": "contains the configuration for the SHA tagger."
},
"GitTagger": {
"additionalProperties": false,
"description": "contains the configuration for the git tagger."
},
"EnvTemplateTagger": {
Expand All @@ -97,6 +102,7 @@
"default": "\"\""
}
},
"additionalProperties": false,
"description": "contains the configuration for the envTemplate tagger."
},
"DateTimeTagger": {
Expand All @@ -110,6 +116,7 @@
"default": "\"\""
}
},
"additionalProperties": false,
"description": "contains the configuration for the DateTime tagger."
},
"BuildType": {
Expand All @@ -124,6 +131,7 @@
"$ref": "#/definitions/KanikoBuild"
}
},
"additionalProperties": false,
"description": "contains the specific implementation and parameters needed for the build step. Only one field should be populated."
},
"LocalBuild": {
Expand All @@ -140,6 +148,7 @@
"default": "false"
}
},
"additionalProperties": false,
"description": "contains the fields needed to do a build on the local docker daemon and optionally push to a repository."
},
"GoogleCloudBuild": {
Expand All @@ -165,6 +174,7 @@
"default": "\"\""
}
},
"additionalProperties": false,
"description": "contains the fields needed to do a remote build on Google Cloud Build."
},
"KanikoBuild": {
Expand All @@ -190,10 +200,12 @@
"default": "\"\""
}
},
"additionalProperties": false,
"description": "contains the fields needed to do a on-cluster build using the kaniko image"
},
"DeployConfig": {
"oneOf": [
"additionalProperties": false,
"anyOf": [
{
"properties": {
"helm": {
Expand Down Expand Up @@ -230,6 +242,7 @@
"$ref": "#/definitions/KustomizeDeploy"
}
},
"additionalProperties": false,
"description": "contains the specific implementation and parameters needed for the deploy step. Only one field should be populated."
},
"KubectlDeploy": {
Expand All @@ -254,6 +267,7 @@
"$ref": "#/definitions/KubectlFlags"
}
},
"additionalProperties": false,
"description": "contains the configuration needed for deploying with <code>kubectl apply</code>"
},
"KubectlFlags": {
Expand Down Expand Up @@ -283,6 +297,7 @@
"default": "[]"
}
},
"additionalProperties": false,
"description": "describes additional options flags that are passed on the command line to kubectl either on every command (Global), on creations (Apply) or deletions (Delete)."
},
"HelmDeploy": {
Expand All @@ -294,6 +309,7 @@
"type": "array"
}
},
"additionalProperties": false,
"description": "contains the configuration needed for deploying with helm"
},
"KustomizeDeploy": {
Expand All @@ -305,7 +321,8 @@
"flags": {
"$ref": "#/definitions/KubectlFlags"
}
}
},
"additionalProperties": false
},
"HelmRelease": {
"properties": {
Expand Down Expand Up @@ -372,7 +389,8 @@
"imageStrategy": {
"$ref": "#/definitions/HelmImageStrategy"
}
}
},
"additionalProperties": false
},
"HelmPackaged": {
"properties": {
Expand All @@ -387,10 +405,12 @@
"default": "\"\""
}
},
"additionalProperties": false,
"description": "represents parameters for packaging helm chart."
},
"HelmImageStrategy": {
"oneOf": [
"additionalProperties": false,
"anyOf": [
{
"properties": {
"fqn": {
Expand All @@ -415,7 +435,8 @@
"helm": {
"$ref": "#/definitions/HelmConventionConfig"
}
}
},
"additionalProperties": false
},
"HelmFQNConfig": {
"properties": {
Expand All @@ -424,9 +445,11 @@
"default": "\"\""
}
},
"additionalProperties": false,
"description": "represents image config to use the FullyQualifiedImageName as param to set"
},
"HelmConventionConfig": {
"additionalProperties": false,
"description": "represents image config in the syntax of image.repository and image.tag"
},
"Artifact": {
Expand All @@ -440,7 +463,8 @@
"default": "\"\""
}
},
"oneOf": [
"additionalProperties": false,
"anyOf": [
{
"properties": {
"docker": {
Expand Down Expand Up @@ -471,6 +495,7 @@
"$ref": "#/definitions/DeployConfig"
}
},
"additionalProperties": false,
"description": "additional configuration that overrides default configuration when it is activated."
},
"ArtifactType": {
Expand All @@ -481,7 +506,8 @@
"bazel": {
"$ref": "#/definitions/BazelArtifact"
}
}
},
"additionalProperties": false
},
"DockerArtifact": {
"properties": {
Expand All @@ -508,15 +534,17 @@
"type": "string",
"default": "\"\""
}
}
},
"additionalProperties": false
},
"BazelArtifact": {
"properties": {
"target": {
"type": "string",
"default": "\"\""
}
}
},
"additionalProperties": false
}
}
}
Loading

0 comments on commit 9d59806

Please sign in to comment.