Commit 7f527ab
committed
Add optional built-in substitution of last attempted revision
The purpose of this new feature (which is CLI-conditional, and defaults
to false in order to preserve compatibility) is to allow to refer to
the revision that is currently being applied in the resource manifests,
via the standard substitutions mechanism.
By enabling the feature, the controller will always add the
FLUX_ARTIFACT_REVISION key to the substitutions map, with the value of
the artifact revision as provided by the source controller.
If, however, the artifact revision matches the following pattern:
([^@]+)@sha1:(.+)
then it will also add the following two keys:
- FLUX_ARTIFACT_REF: the 1st group in the pattern, representing the
branch or ref part for source-control based revisions (e.g. Git)
- FLUX_ARTIFACT_SHA: the 2nd group in the pattern, representing the SHA
usually in source-control based revisions (e.g. Git).
Signed-off-by: arikkfir <[email protected]>1 parent 968df5e commit 7f527ab
2 files changed
+28
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
| 25 | + | |
25 | 26 | | |
26 | 27 | | |
27 | 28 | | |
| |||
95 | 96 | | |
96 | 97 | | |
97 | 98 | | |
| 99 | + | |
98 | 100 | | |
99 | 101 | | |
100 | 102 | | |
| |||
104 | 106 | | |
105 | 107 | | |
106 | 108 | | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
107 | 113 | | |
108 | 114 | | |
109 | 115 | | |
| |||
380 | 386 | | |
381 | 387 | | |
382 | 388 | | |
383 | | - | |
| 389 | + | |
384 | 390 | | |
385 | 391 | | |
386 | 392 | | |
| |||
573 | 579 | | |
574 | 580 | | |
575 | 581 | | |
576 | | - | |
| 582 | + | |
577 | 583 | | |
578 | 584 | | |
579 | 585 | | |
| |||
617 | 623 | | |
618 | 624 | | |
619 | 625 | | |
| 626 | + | |
| 627 | + | |
| 628 | + | |
| 629 | + | |
| 630 | + | |
| 631 | + | |
| 632 | + | |
| 633 | + | |
| 634 | + | |
| 635 | + | |
| 636 | + | |
| 637 | + | |
| 638 | + | |
| 639 | + | |
| 640 | + | |
| 641 | + | |
620 | 642 | | |
621 | 643 | | |
622 | 644 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
75 | 75 | | |
76 | 76 | | |
77 | 77 | | |
| 78 | + | |
78 | 79 | | |
79 | 80 | | |
80 | 81 | | |
| |||
101 | 102 | | |
102 | 103 | | |
103 | 104 | | |
| 105 | + | |
| 106 | + | |
104 | 107 | | |
105 | 108 | | |
106 | 109 | | |
| |||
223 | 226 | | |
224 | 227 | | |
225 | 228 | | |
| 229 | + | |
226 | 230 | | |
227 | 231 | | |
228 | 232 | | |
| |||
0 commit comments