Skip to content

Commit 8dcf374

Browse files
committed
update docs
1 parent 225da76 commit 8dcf374

File tree

2 files changed

+66
-10
lines changed

2 files changed

+66
-10
lines changed

docs/basics/update-strategies.md

Lines changed: 60 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,13 @@ The following update strategies are currently supported:
1515

1616
* [semver](#strategy-semver) - Update to the latest version of an image
1717
considering semantic versioning constraints
18-
* [latest](#strategy-latest) - Update to the most recently built image found in a registry
18+
* [latest/newest-build](#strategy-latest) - Update to the most recently built image found in a registry
1919
* [digest](#strategy-digest) - Update to the latest version of a given version (tag), using the tag's SHA digest
20-
* [name](#strategy-name) - Sorts tags alphabetically and update to the one with the highest cardinality
20+
* [name/alphabetical](#strategy-name) - Sorts tags alphabetically and update to the one with the highest cardinality
21+
22+
!!!warning "Renamed image update strategies
23+
The `latest` strategy has been renamed to `newest-build`, and `name` strategy has been renamed to `alphabetical`.
24+
Please switch to the new convention as support for the old naming convention will be removed in future releases.
2125

2226
Some of the strategies will require additional configuration, or can be tweaked
2327
with additional parameters. Please have a look at the
@@ -97,30 +101,42 @@ Image Updater will pick the highest version number found in the registry.
97101
Argo CD Image Updater will omit any tags from your registry that do not match
98102
a semantic version when using the `semver` update strategy.
99103

100-
### <a name="strategy-latest"></a>latest - Update to the most recently built image
104+
### <a name="strategy-latest"></a>latest/newest-build - Update to the most recently built image
105+
106+
107+
!!!warning "Renamed image update strategies"
108+
The `latest` strategy has been renamed to `newest-build`.
109+
Please switch to the new convention as support for the old naming convention will be removed in future releases.
110+
Detected usage of `latest` will result in a warning message within the image-updater controller logs.
101111

102112
!!!warning
103113
As of November 2020, Docker Hub has introduced pull limits for accounts on
104-
the free plan and unauthenticated requests. The `latest` update strategy
114+
the free plan and unauthenticated requests. The `latest` or `newest-build` update strategy
105115
will perform manifest pulls for determining the most recently pushed tags,
106116
and these will count into your pull limits. So unless you are not affected
107-
by these pull limits, it is **not recommended** to use the `latest` update
117+
by these pull limits, it is **not recommended** to use the `latest` or `newest-build` update
108118
strategy with images hosted on Docker Hub.
109119

110120
!!!note
111121
If you are using *reproducible builds* for your container images (e.g. if
112122
your build pipeline always sets the creation date of the image to the same
113-
value), the `latest` strategy will not be able to determine which tag to
123+
value), the `latest` or `newest-build` strategy will not be able to determine which tag to
114124
update to.
115125

116-
Strategy name: `latest`
126+
Strategy name: `latest` or `newest-build`
117127

118128
Basic configuration:
119129

120130
```yaml
121131
argocd-image-updater.argoproj.io/image-list: <alias>=some/image
122132
argocd-image-updater.argoproj.io/<alias>.update-strategy: latest
123133
```
134+
or
135+
136+
```yaml
137+
argocd-image-updater.argoproj.io/image-list: <alias>=some/image
138+
argocd-image-updater.argoproj.io/<alias>.update-strategy: newest-build
139+
```
124140
125141
Argo CD Image Updater can update to the image that has the most recent build
126142
date, and is tagged with an arbitrary name (e.g. a Git commit SHA, or even a
@@ -147,6 +163,14 @@ argocd-image-updater.argoproj.io/myimage.update-strategy: latest
147163
argocd-image-updater.argoproj.io/myimage.allow-tags: regexp:^[0-9a-f]{7}$
148164
```
149165

166+
or
167+
168+
```yaml
169+
argocd-image-updater.argoproj.io/image-list: myimage=some/image
170+
argocd-image-updater.argoproj.io/myimage.update-strategy: newest-build
171+
argocd-image-updater.argoproj.io/myimage.allow-tags: regexp:^[0-9a-f]{7}$
172+
```
173+
150174
would only consider tags that match a given regular expression for update. In
151175
this case, the regular expression matches a 7-digit hexadecimal string that
152176
could represent the short version of a Git commit SHA, so it would match tags
@@ -160,6 +184,14 @@ argocd-image-updater.argoproj.io/myimage.update-strategy: latest
160184
argocd-image-updater.argoproj.io/myimage.ignore-tags: latest, master
161185
```
162186

187+
or
188+
189+
```yaml
190+
argocd-image-updater.argoproj.io/image-list: myimage=some/image
191+
argocd-image-updater.argoproj.io/myimage.update-strategy: newest-build
192+
argocd-image-updater.argoproj.io/myimage.ignore-tags: latest, master
193+
```
194+
163195
This would allow for considering all tags found but `latest` and `master`. You
164196
can read more about filtering tags
165197
[here](../../configuration/images/#filtering-tags).
@@ -206,14 +238,26 @@ argocd-image-updater.argoproj.io/myimage.update-strategy: digest
206238

207239
### <a name="strategy-name"></a>Update according to lexical sort
208240

209-
Strategy name: `name`
241+
!!!warning "Renamed image update strategies"
242+
The `name` strategy has been renamed to `alphabetical`.
243+
Please switch to the new convention as support for the old naming convention will be removed in future releases.
244+
Detected usage of `name` will result in a warning message within the image-updater controller logs.
245+
246+
247+
Strategy name: `name` or `alphabetical`
210248

211249
Basic configuration:
212250

213251
```yaml
214252
argocd-image-updater.argoproj.io/image-list: <alias>=some/image
215253
argocd-image-updater.argoproj.io/<alias>.update-strategy: name
216254
```
255+
or
256+
257+
```yaml
258+
argocd-image-updater.argoproj.io/image-list: <alias>=some/image
259+
argocd-image-updater.argoproj.io/<alias>.update-strategy: alphabetical
260+
```
217261

218262
This update strategy sorts the tags returned by the registry in a lexical way
219263
(by name, in descending order) and picks the last tag in the list for update.
@@ -231,6 +275,14 @@ argocd-image-updater.argoproj.io/myimage.update-strategy: name
231275
argocd-image-updater.argoproj.io/myimage.allow-tags: regexp:^[0-9]{4}-[0-9]{2}[0-9]{2}$
232276
```
233277

278+
or
279+
280+
```yaml
281+
argocd-image-updater.argoproj.io/image-list: myimage=some/image
282+
argocd-image-updater.argoproj.io/myimage.update-strategy: alphabetical
283+
argocd-image-updater.argoproj.io/myimage.allow-tags: regexp:^[0-9]{4}-[0-9]{2}[0-9]{2}$
284+
```
285+
234286
would only consider tags that match a given regular expression for update. In
235287
this case, only tags matching a date specification of `YYYY-MM-DD` would be
236288
considered for update.

docs/index.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,14 +42,18 @@ RBAC authorization on Application resources etc. are fully supported.
4242

4343
## Features
4444

45+
!!!warning "Renamed image update strategies"
46+
The `latest` strategy has been renamed to `newest-build`, and `name` strategy has been renamed to `alphabetical`.
47+
Please switch to the new convention as support for the old naming convention will be removed in future releases.
48+
4549
* Updates images of apps that are managed by Argo CD and are either generated
4650
from *Helm* or *Kustomize* tooling
4751
* Update app images according to different
4852
[update strategies](./basics/update-strategies.md)
4953
* `semver`: update to highest allowed version according to given image
5054
constraint,
51-
* `latest`: update to the most recently created image tag,
52-
* `name`: update to the last tag in an alphabetically sorted list
55+
* `latest/newest-build`: update to the most recently created image tag,
56+
* `name/alphabetical`: update to the last tag in an alphabetically sorted list
5357
* `digest`: update to the most recent pushed version of a mutable tag
5458
* Support for
5559
[widely used container registries](./configuration/registries.md#supported-registries)

0 commit comments

Comments
 (0)