Skip to content
Merged
2 changes: 1 addition & 1 deletion docs/enterprise/image-registry-kurl.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,4 +68,4 @@ The kURL registry image garbage collection feature has following limitations:

* **Customer-Supplied Registries**: Image garbage collection is supported only when used with the built-in kURL registry. If the KOTS instance is configured to use a different registry, disable garbage collection to prevent image loss. For more information about configuring an image registry in the Admin Console, see [Configure Local Image Registries](/enterprise/image-registry-settings).

* **Application Rollbacks**: Image garbage collection has no effect when the `allowRollback` field in the KOTS Application custom resource is set to `true`. For more information, see [Application](/reference/custom-resource-application) in _KOTS Custom Resources_.
* **Application Rollbacks**: Image garbage collection has no effect when the `allowRollback` field in the Replicated Application custom resource is set to `true`. For more information, see [Application](/reference/custom-resource-application).
2 changes: 1 addition & 1 deletion docs/partials/config/_property-when.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ It can be useful to conditionally show or hide fields so that your users are onl
* The number of users that the license permits
* If the user chooses to bring their own external database, rather than using an embedded database offered with the application

You can construct conditional statements in the `when` property using KOTS template functions. KOTS template functions are a set of custom template functions based on the Go text/template library. For more information, see [About Template Functions](/reference/template-functions-about).
You can construct conditional statements in the `when` property using Replicated template functions. Replicated template functions are a set of custom template functions based on the Go text/template library. For more information, see [About Replicated Template Functions](/reference/template-functions-about).
2 changes: 1 addition & 1 deletion docs/partials/config/_when-requirements.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
* Booleans
* Strings that match "true", "True", "false", or "False"

[KOTS template functions](/reference/template-functions-about) can be used to render these supported value types.
[Replicated template functions](/reference/template-functions-about) can be used to render these supported value types.
* For the `when` property to evaluate to true, the values compared in the conditional statement must match exactly without quotes
4 changes: 2 additions & 2 deletions docs/partials/helm/_helm-cr-optional-values-when.mdx
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).
2 changes: 1 addition & 1 deletion docs/partials/helm/_helm-cr-optional-values.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ The `optionalValues` key can be used to set values in the Helm chart `values.yam

`optionalValues` includes the following properties:

* `optionalValues.when`: Defines a conditional statement using KOTS template functions. If `optionalValues.when` evaluates to true, then the values specified in `optionalValues` are set.
* `optionalValues.when`: Defines a conditional statement using Replicated template functions. If `optionalValues.when` evaluates to true, then the values specified in `optionalValues` are set.

* `optionalValues.recursiveMerge`: Defines how `optionalValues` is merged with `values`.

Expand Down
2 changes: 1 addition & 1 deletion docs/partials/helm/_set-values-config-example.mdx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Using KOTS template functions in the [Config](/reference/template-functions-config-context) context allows you to set Helm values based on user-supplied values from the KOTS Admin Console configuration page.
Using Replicated template functions in the [Config](/reference/template-functions-config-context) context allows you to set Helm values based on user-supplied values from the KOTS Admin Console configuration page.

For example, the following Helm chart `values.yaml` file contains `postgresql.enabled`, which is set to `false`:

Expand Down
2 changes: 1 addition & 1 deletion docs/partials/helm/_set-values-license-example.mdx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Using KOTS template functions in the [License](/reference/template-functions-license-context) context allows you to set Helm values based on the unique license file used for installation or upgrade.
Using Replicated template functions in the [License](/reference/template-functions-license-context) context allows you to set Helm values based on the unique license file used for installation or upgrade.

For example, the following HelmChart custom resource uses the Replicated [LiencseFieldValue](/reference/template-functions-license-context#licensefieldvalue) template function to evaluate if the license has the boolean `newFeatureEntitlement` field set to `true`:

Expand Down
4 changes: 2 additions & 2 deletions docs/partials/template-functions/_go-sprig.mdx
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/).
4 changes: 2 additions & 2 deletions docs/partials/template-functions/_use-cases.mdx
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.
2 changes: 1 addition & 1 deletion docs/reference/cron-expressions.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Cron Expressions

This topic describes the supported cron expressions that you can use to schedule automatic application update checks and automatic backups in the KOTS Admin Console.
This topic describes the supported cron expressions that you can use to schedule automatic application update checks and automatic backups in the Replicated Admin Console. The information in this topic applies to applications installed with a Replicated installer (Embedded Cluster, KOTS, kURL).

For more information, see [Configure Automatic Updates](/enterprise/updating-apps) and [Schedule Automatic Backups](/enterprise/snapshots-creating#schedule-automatic-backups) in _Creating and Scheduling Backups_.

Expand Down
91 changes: 66 additions & 25 deletions docs/reference/custom-resource-about.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,72 @@
# About Custom Resources
Copy link
Contributor Author

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


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>
4 changes: 2 additions & 2 deletions docs/reference/custom-resource-config.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ Items have a `name`, `title`, `type`, and other optional properties.
<table>
<tr>
<th>Description</th>
<td><p>A unique identifier for the config item. Item names must be unique both within the group and across all groups. The item <code>name</code> is not displayed in the Admin Console.</p><p> The item <code>name</code> can be used with KOTS template functions in the Config context (such as ConfigOption or ConfigOptionEquals) to return the value of the item. For more information, see <a href="/reference/template-functions-config-context">Config Context</a>.</p></td>
<td><p>A unique identifier for the config item. Item names must be unique both within the group and across all groups. The item <code>name</code> is not displayed in the Admin Console.</p><p> The item <code>name</code> can be used with Replicated template functions in the Config context (such as ConfigOption or ConfigOptionEquals) to return the value of the item. For more information, see <a href="/reference/template-functions-config-context">Config Context</a>.</p></td>
</tr>
<tr>
<th>Required?</th>
Expand Down Expand Up @@ -655,7 +655,7 @@ The `select_one` item type is deprecated and is replaced by [`radio`](#radio).

`select_one` items must contain nested items. The nested items are displayed as radio buttons in the Admin Console.

You can use the `name` field of a `select_one` item with KOTS template functions in the Config context (such as ConfigOption or ConfigOptionEquals) to return the option selected by the user.
You can use the `name` field of a `select_one` item with Replicated template functions in the Config context (such as ConfigOption or ConfigOptionEquals) to return the option selected by the user.

For example, if the user selects the **Password** option for the `select_one` item shown below, then the template function `'{{repl ConfigOption "authentication_type"}}'` is rendered as `authentication_type_password`. For more information about working with template functions in the Config context, see [Config Context](/reference/template-functions-config-context).

Expand Down
4 changes: 2 additions & 2 deletions docs/reference/custom-resource-configvalues.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ As shown in the image above, the `values` key in the ConfigValues resource lists

Replicated template functions are not supported in the ConfigValues resource. To set an application configuration item to a value rendered by a template function, you can use a template function in the `default` or `value` property for the item in the [Config](custom-resource-config) resource.

For more information about working with Replicated template functions, see [About Template Functions](/reference/template-functions-about).
For more information about working with Replicated template functions, see [About Replicated Template Functions](/reference/template-functions-about).

## Spec

Expand Down Expand Up @@ -89,7 +89,7 @@ spec:

:::note
In the ConfigValues resource that is automatically generated by the Admin Console as part of installation, the `value` property might also be set to one of the following:
* A value rendered by a Replicated template function. For example, a [`hidden`](/reference/custom-resource-config#hidden) item defined in the Config resource could use the Replicated [RandomString](/reference/template-functions-static-context#randomstring) template function to set the value with `value: repl{{ RandomString 40}}`. In this case, the value for the item in the ConfigValues would be generated by the template function and not user-supplied. For more information about using Replicated template functions, see [About Template Functions](/reference/template-functions-about).
* A value rendered by a Replicated template function. For example, a [`hidden`](/reference/custom-resource-config#hidden) item defined in the Config resource could use the Replicated [RandomString](/reference/template-functions-static-context#randomstring) template function to set the value with `value: repl{{ RandomString 40}}`. In this case, the value for the item in the ConfigValues would be generated by the template function and not user-supplied. For more information about using Replicated template functions, see [About Replicated Template Functions](/reference/template-functions-about).
* An encrypted empty string. For any `password` configuration items without a user-supplied value, the Admin Console sets the value to an empty string. In the ConfigValues generated for the installation, this empty string is automatically encrypted.
* An empty mapping (`{}`). For configuration items without a user-supplied `value` or a `default` set, the value is set to `{}`.
:::
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/embedded-config.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The Embedded Cluster Config lets you define several aspects of the Kubernetes cl

### Limitations

* The Embedded Cluster Config does not support the use of Go template functions, including [KOTS template functions](/reference/template-functions-about).
* The Embedded Cluster Config does not support the use of Go template functions, including [Replicated template functions](/reference/template-functions-about).

* There are additional, property-specific limitations. For more information, see the sections below.

Expand Down
Loading