You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: _docs/promotions/yaml/promotion-template-crd.md
+5-1Lines changed: 5 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -25,6 +25,10 @@ kind: PromotionTemplate
25
25
metadata:
26
26
name: base-helm # any valid k8s name
27
27
spec:
28
+
applicationSourceSelector:
29
+
matchLabels:
30
+
codefresh.io/product: loans
31
+
priority: 1
28
32
versionSource: # get release version from this file
29
33
file: Chart.yaml
30
34
jsonPath: $appVersion
@@ -52,7 +56,7 @@ spec:
52
56
| `spec.applicationSourceSelector` | The label used to match the application to which to apply the Promotion Template. Application selectors conform to Kubernetes _label selectors_, defined as `matchLabels` with `key-value` pairs, `matchExpressions` with `key-operator-value` arrays, or a combination of both. The values identify all the Promotion Template manifests that match the specific application or applications within the target environment.| - | Required|
53
57
| `spec.applicationSourceSelector.matchLabels` | One or more `key-value` pairs, where each pair is equivalent to a condition in `matchExpressions`. If there are multiple `key-value` pairs, the AND operator is used. <br>For example:{::nomarkdown}<ul><li><code class="highlighter-rouge">codefresh.io/environment: production</code> applies the Promotion Template to all applications within the Production Environment.</li><li><code class="highlighter-rouge">codefresh.io/product: loans</code> applies the Promotion Template only to applications belonging to the Loans product.</li></ul>{:/}| object | Optional |
54
58
| `spec.applicationSourceSelector.matchExpressions` | List of expressions, each with a `key`, an `operator`, and a set of `values`. <br>The `operator` defines the relationship between the `key` and its `values`, and can be one of the following: {::nomarkdown}<ul><li><code class="highlighter-rouge">In</code>: The value _must match_ one of those specified in the <code class="highlighter-rouge">values</code> array.</li> <li><code class="highlighter-rouge">NotIn</code>: The value _must NOT match_ any of those in the <code class="highlighter-rouge">values</code> array.</li><li><code class="highlighter-rouge">Exists</code>: Only the <code class="highlighter-rouge">key</code> must exist regardless of its values.<br>The <code class="highlighter-rouge">values</code> array must be empty. </li><li><code class="highlighter-rouge">DoesNotExist</code>: The <code class="highlighter-rouge">key</code> must not exist.<br>The <code class="highlighter-rouge">values</code> array must be empty.</li></ul>{:/}For example:<br>`key: codefresh.io/product` and `operator: Exists` applies the Promotion Template to any application containing the label `codefresh.io/product`.| string | Optional |
55
-
| `spec.priority` | The priority of the Promotion Template, determining the order in which Promotion Templates are applied when multiple Promotion Templates match the same application. The priority is ranked in ascending order, ranging from 0 or a negative number to higher values. |integer |Optional|
59
+
| `spec.priority` | The priority of the Promotion Template, determining the order in which Promotion Templates are applied when multiple Promotion Templates match the same application. The priority is ranked in ascending order, ranging from 0 or a negative number to higher values. |integer | Required |
56
60
| `spec.versionSource` | The location of the file and the attribute in the file from which to extract the product's application release version. This is the version displayed in the Product, Environment, and GitOps Apps dashboards.| - |Required |
57
61
| `spec.versionSource.file` | The file path relative to the application's file path from which to extract the application's release version. For example, `chart.yaml` indicates that the release version should be extracted from this file.| string | Required |
58
62
| `spec.versionSource.jsonPath` | The JSON path expression pointing to the location of the attribute containing the application version within the specified `file`.<br>For example, `$.appVersion` indicates the value should be extracted from the field `appVersion` in `chart.yaml`.| string| Required |
0 commit comments