mirror of https://github.com/google/oss-fuzz.git
Tag all base images with :v1. (#6436)
To guard against major/breaking image migrations in the future. Part of #6324.
This commit is contained in:
parent
c66a9d2b53
commit
273882068e
|
@ -34,6 +34,7 @@ BASE_IMAGES = [
|
||||||
]
|
]
|
||||||
BASE_PROJECT = 'oss-fuzz-base'
|
BASE_PROJECT = 'oss-fuzz-base'
|
||||||
TAG_PREFIX = f'gcr.io/{BASE_PROJECT}/'
|
TAG_PREFIX = f'gcr.io/{BASE_PROJECT}/'
|
||||||
|
MAJOR_VERSION = 'v1'
|
||||||
|
|
||||||
|
|
||||||
def _get_base_image_steps(images, tag_prefix=TAG_PREFIX):
|
def _get_base_image_steps(images, tag_prefix=TAG_PREFIX):
|
||||||
|
@ -47,11 +48,14 @@ def _get_base_image_steps(images, tag_prefix=TAG_PREFIX):
|
||||||
}]
|
}]
|
||||||
|
|
||||||
for base_image in images:
|
for base_image in images:
|
||||||
|
image = tag_prefix + base_image
|
||||||
steps.append({
|
steps.append({
|
||||||
'args': [
|
'args': [
|
||||||
'build',
|
'build',
|
||||||
'-t',
|
'-t',
|
||||||
tag_prefix + base_image,
|
image,
|
||||||
|
'-t',
|
||||||
|
f'{image}:{MAJOR_VERSION}',
|
||||||
'.',
|
'.',
|
||||||
],
|
],
|
||||||
'dir': 'oss-fuzz/infra/base-images/' + base_image,
|
'dir': 'oss-fuzz/infra/base-images/' + base_image,
|
||||||
|
@ -77,7 +81,7 @@ def run_build(steps, images):
|
||||||
'options': {
|
'options': {
|
||||||
'machineType': 'N1_HIGHCPU_32'
|
'machineType': 'N1_HIGHCPU_32'
|
||||||
},
|
},
|
||||||
'images': images
|
'images': images + [f'{image}:{MAJOR_VERSION}' for image in images]
|
||||||
}
|
}
|
||||||
cloudbuild = build('cloudbuild',
|
cloudbuild = build('cloudbuild',
|
||||||
'v1',
|
'v1',
|
||||||
|
|
Loading…
Reference in New Issue