@@ -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
2226Some of the strategies will require additional configuration, or can be tweaked
2327with additional parameters. Please have a look at the
@@ -97,30 +101,42 @@ Image Updater will pick the highest version number found in the registry.
97101Argo CD Image Updater will omit any tags from your registry that do not match
98102a 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
118128Basic configuration:
119129
120130``` yaml
121131argocd-image-updater.argoproj.io/image-list : <alias>=some/image
122132argocd-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
125141Argo CD Image Updater can update to the image that has the most recent build
126142date, 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
147163argocd-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+
150174would only consider tags that match a given regular expression for update. In
151175this case, the regular expression matches a 7-digit hexadecimal string that
152176could 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
160184argocd-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+
163195This would allow for considering all tags found but `latest` and `master`. You
164196can 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
211249Basic configuration :
212250
213251` ` ` yaml
214252argocd-image-updater.argoproj.io/image-list: <alias>=some/image
215253argocd-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
218262This 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
231275argocd-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+
234286would only consider tags that match a given regular expression for update. In
235287this case, only tags matching a date specification of `YYYY-MM-DD` would be
236288considered for update.
0 commit comments