-
Notifications
You must be signed in to change notification settings - Fork 32
Move KOTS reference (template func, custom resources) to top level #3747
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
28bb1cf
move kots reference material to top level
paigecalvert bc90a22
wip add custom doc cards for replicated installers generated index
paigecalvert 6c7c921
edit kots specific language in temp func and custom resource docs
paigecalvert b043c14
remove unrealted sidebar edits
paigecalvert 338c7bf
update link text
paigecalvert d69f776
change kots template functions language to replicated template functions
paigecalvert fadf500
edit content on custom resource overview page
paigecalvert ea8ce79
undo unrelated change to script
paigecalvert 06662ca
update link text
paigecalvert 021a709
sidebar edit
paigecalvert bc17256
fix find and replace typos
paigecalvert File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,10 +1,10 @@ | ||
| The `optionalValues.when` field defines a conditional statement that must evaluate to true for the given values to be set. Evaluation of the conditional in the `optionalValues.when` field is deferred until render time in the customer environment. | ||
|
|
||
| Use KOTS template functions to write the `optionalValues.when` conditional statement. The following example shows a conditional statement for selecting a database option on the Admin Console configuration screen: | ||
| Use Replicated template functions to write the `optionalValues.when` conditional statement. The following example shows a conditional statement for selecting a database option on the Admin Console configuration screen: | ||
|
|
||
| ```yaml | ||
| optionalValues: | ||
| - when: repl{{ ConfigOptionEquals "postgres_type" "external_postgres"}} | ||
| ``` | ||
|
|
||
| For more information about using KOTS template functions, see [About Template Functions](/reference/template-functions-about). | ||
| For more information about using Replicated template functions, see [About Replicated Template Functions](/reference/template-functions-about). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,3 @@ | ||
| KOTS template functions are based on the Go text/template library. All functionality of the Go templating language, including if statements, loops, and variables, is supported with KOTS template functions. For more information, see [text/template](https://golang.org/pkg/text/template/) in the Go documentation. | ||
| Replicated template functions are based on the Go text/template library. All functionality of the Go templating language, including if statements, loops, and variables, is supported with Replicated template functions. For more information, see [text/template](https://golang.org/pkg/text/template/) in the Go documentation. | ||
|
|
||
| Additionally, KOTS template functions can be used with all functions in the Sprig library. Sprig provides several template functions for the Go templating language, such as type conversion, string, and integer math functions. For more information, see [Sprig Function Documentation](https://masterminds.github.io/sprig/). | ||
| Additionally, Replicated template functions can be used with all functions in the Sprig library. Sprig provides several template functions for the Go templating language, such as type conversion, string, and integer math functions. For more information, see [Sprig Function Documentation](https://masterminds.github.io/sprig/). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,7 +1,7 @@ | ||
| Common use cases for KOTS template functions include rendering values during installation or upgrade, such as: | ||
| Common use cases for Replicated template functions include rendering values during installation or upgrade, such as: | ||
| * Customer-specific license field values | ||
| * User-provided configuration values | ||
| * Information about the customer environment, such the number of nodes or the Kubernetes version in the cluster where the application is installed | ||
| * Random strings | ||
|
|
||
| KOTS template functions can also be used to work with integer, boolean, float, and string values, such as doing mathematical operations, trimming leading and trailing spaces, or converting string values to integers or booleans. | ||
| Replicated template functions can also be used to work with integer, boolean, float, and string values, such as doing mathematical operations, trimming leading and trailing spaces, or converting string values to integers or booleans. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,31 +1,72 @@ | ||
| # About Custom Resources | ||
|
|
||
| You can include custom resources in releases to control the experience for applications installed with Replicated KOTS. | ||
| You can include custom resources in your releases to control the experience for installations with a Replicated installer, add support air gap installations, and configure functionality like preflight checks, support bundles, and disaster recovery. | ||
|
|
||
| Custom resources are consumed by KOTS, the Admin Console, or by other kubectl plugins. Custom resources are packaged as part of the application, but are _not_ deployed to the cluster. | ||
| Custom resources are consumed by Replicated installers, the Replicated Admin Console, or by other kubectl plugins. Custom resources are packaged as part of the application, but are _not_ deployed to the cluster. | ||
|
|
||
| ## KOTS Custom Resources | ||
| ## Custom Resources | ||
|
|
||
| The following are custom resources in the `kots.io` API group: | ||
|
|
||
| | API Group/Version | Kind | Description | | ||
| |---------------|------|-------------| | ||
| | kots.io/v1beta1 | [Application](custom-resource-application) | Adds additional metadata (branding, release notes and more) to an application | | ||
| | kots.io/v1beta1 | [Config](custom-resource-config)| Defines a user-facing configuration screen in the Admin Console | | ||
| | kots.io/v1beta2 | [HelmChart](custom-resource-helmchart-v2) | Identifies an instantiation of a Helm Chart | | ||
| | kots.io/v1beta1 | [LintConfig](custom-resource-lintconfig) | Customizes the default rule levels for the KOTS release linter | | ||
|
|
||
| ## Other Custom Resources | ||
|
|
||
| The following are custom resources in API groups other than `kots.io` that can be included in a KOTS release to configure additional functionality: | ||
|
|
||
| | API Group/Version | Kind | Description | | ||
| |---------------|------|-------------| | ||
| | app.k8s.io/v1beta1 | [SIG Application](https://github.com/kubernetes-sigs/application#kubernetes-applications) | Defines metadata about the application | | ||
| | cluster.kurl.sh/v1beta1 | [Installer](https://kurl.sh/docs/create-installer/) | Defines a Replicated kURL distribution | | ||
| | embeddedcluster.replicated.com/v1beta1 | [Config](/reference/embedded-config) | Defines a Replicated Embedded Cluster distribution | | ||
| | troubleshoot.sh/v1beta2 | [Preflight](custom-resource-preflight) | Defines the data to collect and analyze for custom preflight checks | | ||
| | troubleshoot.sh/v1beta2 | [Redactor](https://troubleshoot.sh/docs/redact/) | Defines custom redactors that apply to support bundles and preflight checks | | ||
| | troubleshoot.sh/v1beta2 | [Support Bundle](custom-resource-preflight) | Defines the data to collect and analyze for a support bundle | | ||
| | velero.io/v1 | [Backup](https://velero.io/docs/v1.10/api-types/backup/) | A Velero backup request, triggered when the user initiates a backup with Replicated snapshots | | ||
| The following custom resources can be used in releases distributed with Replicated: | ||
|
|
||
| <table> | ||
| <tr> | ||
| <td width="40%">API Group/Version</td> | ||
| <td width="25%">Kind</td> | ||
| <td>Description</td> | ||
| </tr> | ||
| <tr> | ||
| <td>app.k8s.io/v1beta1</td> | ||
| <td>[SIG Application](https://github.com/kubernetes-sigs/application#kubernetes-applications)</td> | ||
| <td>Defines metadata about the application for installations with a Replicated installer (Embedded Cluster, KOTS, kURL)</td> | ||
| </tr> | ||
| <tr> | ||
| <td>embeddedcluster.replicated.com/v1beta1</td> | ||
| <td>[Config](/reference/embedded-config)</td> | ||
| <td>Defines a Replicated Embedded Cluster distribution</td> | ||
| </tr> | ||
| <tr> | ||
| <td>cluster.kurl.sh/v1beta1</td> | ||
| <td>[Installer](https://kurl.sh/docs/create-installer/)</td> | ||
| <td>Defines a Replicated kURL distribution</td> | ||
| </tr> | ||
| <tr> | ||
| <td>kots.io/v1beta1</td> | ||
| <td>[Application](custom-resource-application)</td> | ||
| <td>Adds metadata (such as branding, release notes and more) to the Admin Console for installations with a Replicated installer</td> | ||
| </tr> | ||
| <tr> | ||
| <td>kots.io/v1beta1</td> | ||
| <td>[Config](custom-resource-config)</td> | ||
| <td>Defines a user-facing configuration screen in the Admin Console for installations with a Replicated installer</td> | ||
| </tr> | ||
| <tr> | ||
| <td>kots.io/v1beta2</td> | ||
| <td>[HelmChart](custom-resource-helmchart-v2)</td> | ||
| <td>Identifies an instantiation of a Helm Chart. Used for installations with a Replicated installer and for air gap installations with the Helm CLI</td> | ||
| </tr> | ||
| <tr> | ||
| <td>kots.io/v1beta1</td> | ||
| <td>[LintConfig](custom-resource-lintconfig)</td> | ||
| <td>Customizes the default rule levels for the release linter</td> | ||
| </tr> | ||
| <tr> | ||
| <td>troubleshoot.sh/v1beta2</td> | ||
| <td>[Preflight](custom-resource-preflight)</td> | ||
| <td>Defines collectors and analyzers for preflight checks</td> | ||
| </tr> | ||
| <tr> | ||
| <td>troubleshoot.sh/v1beta2</td> | ||
| <td>[Redactor](https://troubleshoot.sh/docs/redact/)</td> | ||
| <td>Defines custom redactors for support bundles and preflight checks. Supported for installations with a Replicated installer</td> | ||
| </tr> | ||
| <tr> | ||
| <td>troubleshoot.sh/v1beta2</td> | ||
| <td>[Support Bundle](custom-resource-preflight)</td> | ||
| <td>Defines collectors and analyzers for support bundles</td> | ||
| </tr> | ||
| <tr> | ||
| <td>velero.io/v1</td> | ||
| <td>[Backup](https://velero.io/docs/v1.17/api-types/backup/)</td> | ||
| <td>Defines a Velero backup request. Velero provides backup and restore functionality for installations with a Replicated installer. For more information about Velero, see the [Velero](https://velero.io/docs/v1.17/) documentation.</td> | ||
| </tr> | ||
| </table> | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Various content updates on this page to make it less kots-specific and simplify the organization of the tables/list of custom resources