Skip to content
4 changes: 2 additions & 2 deletions docs/partials/proxy-service/_step-inject-pull-secret.mdx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
In the HelmChart v2 custom resource, configure the `values` key to inject the Replicated image pull secret into your Helm values. This provides authentication for the proxy registry. Use the KOTS [ImagePullSecretName](/reference/template-functions-config-context#imagepullsecretname) template function to get the pull secret name.
In the HelmChart v2 custom resource, configure the `values` key to inject the Replicated image pull secret into your Helm values. This provides authentication for the proxy registry. Use the [ImagePullSecretName](/reference/template-functions-config-context#imagepullsecretname) template function to get the pull secret name.

<details>
<summary>What is the Replicated image pull secret?</summary>
Expand Down Expand Up @@ -34,7 +34,7 @@ In the HelmChart v2 custom resource, configure the `values` key to inject the Re
containers:
- name: nginx
image: {{ .Values.image.registry }}/{{ .Values.image.repository }}
# Access the value to provide the KOTS pull secret
# Access the value to provide the pull secret
{{- with .Values.image.pullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 2 }}
Expand Down
12 changes: 6 additions & 6 deletions docs/partials/proxy-service/_step-rewrite-helm-values.mdx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
For each image reference in your Helm chart values file, set the image repository URL to the location of the image in the proxy registry.
For each Helm chart used by your application, in the Helm chart's `values.yaml` file, update all references to private or third-party images to use the Replicated proxy registry domain.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📝 [vale] reported by reviewdog 🐶
[Replicated.SentenceLength] Try to keep your sentence length to 26 words or fewer.


The proxy registry URL has the following format: `DOMAIN/proxy/APP_SLUG/UPSTREAM_REGISTRY/IMAGE_PATH`

The proxy registry URL has the following format: `DOMAIN/proxy/APP_SLUG/EXTERNAL_REGISTRY_IMAGE_URL`

Where:
* `DOMAIN` is either `proxy.replicated.com` or your custom domain.
* `APP_SLUG` is the unique slug of your application.
* `EXTERNAL_REGISTRY_IMAGE_URL` is the path to the private image on your external registry.
- `DOMAIN` is either `proxy.replicated.com` or your custom domain
- `APP_SLUG` is the unique slug of your application
- `UPSTREAM_REGISTRY/IMAGE_PATH` is the full upstream image path. For example, `ghcr.io/my-org/my-image` or `docker.io/bitnami/postgresql`.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated this guidance to use "upstream" terminology instead of "external" based on Salah's language in embedded-image-template-functions.mdx


**Example:**

Expand Down
29 changes: 18 additions & 11 deletions docs/reference/template-functions-about.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ This topic describes Replicated template functions, including information about

## Overview

For Kubernetes manifest files for applications deployed by a Replicated installer (Embedded Cluster, KOTS, kURL), Replicated provides a set of custom template functions based on the Go text/template library.
Replicated provides a set of custom template functions based on the Go text/template library. You can use the Replicated template functions in Kubernetes manifest files for applications deployed by a Replicated installer (Embedded Cluster, KOTS, kURL).

<UseCases/>

Expand All @@ -26,16 +26,6 @@ You can use Replicated template functions in Kubernetes manifest files for appli
* Kubernetes objects like Deployments, Services, Secrets, or ConfigMaps
* Kubernetes Operators

### Limitations

* Not all fields in the Config and Application custom resources support templating. For more information, see [Application](/reference/custom-resource-application) and [Item Properties](/reference/custom-resource-config#item-properties) in _Config_.

* Templating is not supported in the [Embedded Cluster Config](/embedded-cluster/v3/embedded-config) resource.

* Replicated template functions are not directly supported in Helm charts. For more information, see [Helm Charts](#helm-charts) below.

### Helm charts

Replicated template functions are _not_ directly supported in Helm charts. However, the HelmChart custom resource provides a way to map values rendered by Replicated template functions to Helm chart values. This allows you to use Replicated template functions with Helm charts without making changes to those Helm charts.

For information about how to map values from the HelmChart custom resource to Helm chart `values.yaml` files, see [Setting Helm Chart Values with KOTS](/vendor/helm-optional-value-keys).
Expand All @@ -46,6 +36,23 @@ During application installation and upgrade, KOTS templates all Kubernetes manif

For the [Config](/reference/custom-resource-config) custom resource, KOTS templates each item separately so that config items can be used in templates for other items. For examples of this, see [Using Conditional Statements in Configuration Fields](/vendor/config-screen-conditional) and [Template Function Examples](/reference/template-functions-examples).

### Limitations

* Not all fields in the Config and Application custom resources support templating. For more information, see [Application](/reference/custom-resource-application) and [Item Properties](/reference/custom-resource-config#item-properties) in _Config_.

* Templating is not supported in the [Embedded Cluster Config](/embedded-cluster/v3/embedded-config) resource.

* Replicated template functions are not directly supported in Helm charts. For more information, see [Helm Charts](#helm-charts) on this page.

* Embedded Cluster v3 does not support the following template functions:
* HasLocalRegistry
* LocalRegistryAddress
* LocalRegistryHost
* LocalRegistryNamespace
* LocalImageName

These template functions are typically used to conditionally rewrite image references in air gap installations to reference the local image registry. For Embedded Cluster v3 installations, use the ReplicatedImageName, ReplicatedImageName, and ReplicatedImageName template functions instead. For more information, see [Template Functions for Embedded Cluster (Beta)](/embedded-cluster/v3/template-functions).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

^ Added this limitation to call out that the image temp funcs are not supported in ec v3 installations

## Syntax {#syntax}

The Replicated template function syntax supports the following functionally equivalent delimiters:
Expand Down
20 changes: 20 additions & 0 deletions docs/reference/template-functions-config-context.md
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,10 @@ Returns true if the configuration option value is not equal to the supplied valu

## LocalRegistryAddress

:::note
The LocalRegistryAddress template function is not supported for installations with Embedded Cluster v3. See [Template Functions for Embedded Cluster (Beta)](/embedded-cluster/v3/template-functions).
:::
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added these notes to each of the unsupported image templates functions


```go
func LocalRegistryAddress() string
```
Expand All @@ -203,6 +207,10 @@ This will always return everything before the image name and tag.

## LocalRegistryHost

:::note
The LocalRegistryHost template function is not supported for installations with Embedded Cluster v3. See [Template Functions for Embedded Cluster (Beta)](/embedded-cluster/v3/template-functions).
:::

```go
func LocalRegistryHost() string
```
Expand Down Expand Up @@ -236,6 +244,10 @@ For more information, see [Set Helm Values with KOTS](/vendor/helm-optional-valu

## LocalRegistryNamespace

:::note
The LocalRegistryNamespace template function is not supported for installations with Embedded Cluster v3. See [Template Functions for Embedded Cluster (Beta)](/embedded-cluster/v3/template-functions).
:::

```go
func LocalRegistryNamespace() string
```
Expand Down Expand Up @@ -267,6 +279,10 @@ For more information, see [Set Helm Values with KOTS](/vendor/helm-optional-valu

## LocalImageName

:::note
The LocalImageName template function is not supported for installations with Embedded Cluster v3. See [Template Functions for Embedded Cluster (Beta)](/embedded-cluster/v3/template-functions).
:::

```go
func LocalImageName(remoteImageName string) string
```
Expand Down Expand Up @@ -346,6 +362,10 @@ spec:

## HasLocalRegistry

:::note
The HasLocalRegistry template function is not supported for installations with Embedded Cluster v3. See [Template Functions for Embedded Cluster (Beta)](/embedded-cluster/v3/template-functions).
:::

```go
func HasLocalRegistry() bool
```
Expand Down
24 changes: 22 additions & 2 deletions docs/vendor/private-images-kots.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,29 @@ This topic describes how to use the Replicated proxy registry for applications d

## Configure your application to use the proxy registry

These steps assume that you package your application with Helm and that you install with the KOTS [HelmChart v2](/reference/custom-resource-helmchart-v2) custom resource.
These steps assume that you package your application with Helm and that you install with the [HelmChart v2](/reference/custom-resource-helmchart-v2) custom resource.

If you are installing with the HelmChart v1 custom resource, or if your application is not packaged with Helm, there are different steps for configuring your application to use the proxy registry. See [Configure Other Application Types](#other) below.
If you are installing with the HelmChart v1 custom resource, or if your application is not packaged with Helm, there are different steps for configuring your application to use the proxy registry. See [Configure other application types](#other) below.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📝 [vale] reported by reviewdog 🐶
[Replicated.SentenceLength] Try to keep your sentence length to 26 words or fewer.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [vale] reported by reviewdog 🐶
[Replicated.PositionalLanguage] Avoid spacial and directional language like 'below'. Instead, use 'on this page', 'the following', or link to the section.


### Embedded Cluster v3 (Beta) {#configure-v3}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [vale] reported by reviewdog 🐶
[Replicated.Headings] 'Embedded Cluster v3 (Beta) ***************' should use sentence case.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added these new steps for ECv3. The main difference is that you don't need to inject the image pull secret anymore since EC v3 automatically configures the cluster to authenticate to the proxy registry for all pods


Follow these steps to use the proxy registry with applications installed with [Embedded Cluster v3 (Beta)](/embedded-cluster/v3/embedded-overview).

Embedded Cluster v3 configures the cluster to automatically authenticate to the Replicated proxy registry for all pods.

For installations Embedded Cluster v3,

1. <StepCreds/>

1. <StepCustomDomain/>

1. <RewriteHelmValues/>

1. Create a new release with your changes. Promote the release to a development channel. See [Managing Releases with Vendor Portal](releases-creating-releases).

1. Install in a development environment to test your changes. See [Online installation with Embedded Cluster](/embedded-cluster/v3/installing-embedded).

### Embedded Cluster v2, KOTS, or kURL

To configure your application to use the proxy registry for installations with a Replicated installer:

Expand Down
Loading
Loading