@@ -9,7 +9,7 @@ load("//bazel:defs.bzl", "gzip_compress", "sha256sum2url", "zstd_compress")
9
9
load ("//bazel:output_files.bzl" , "output_files" )
10
10
load ("@bazel_skylib//rules:copy_file.bzl" , "copy_file" )
11
11
12
- def icos_build (name , upload_prefix , image_deps , mode = None , malicious = False , upgrades = True , vuln_scan = True , visibility = None ):
12
+ def icos_build (name , upload_prefix , image_deps , mode = None , malicious = False , upgrades = True , vuln_scan = True , visibility = None , ic_version = "//bazel:version.txt" ):
13
13
"""
14
14
Generic ICOS build tooling.
15
15
@@ -22,6 +22,7 @@ def icos_build(name, upload_prefix, image_deps, mode = None, malicious = False,
22
22
upgrades: if True, build upgrade images as well
23
23
vuln_scan: if True, create targets for vulnerability scanning
24
24
visibility: See Bazel documentation
25
+ ic_version: the label pointing to the target that returns IC version
25
26
"""
26
27
27
28
if mode == None :
@@ -40,7 +41,7 @@ def icos_build(name, upload_prefix, image_deps, mode = None, malicious = False,
40
41
41
42
copy_file (
42
43
name = "copy_version_txt" ,
43
- src = "//bazel:version.txt" ,
44
+ src = ic_version ,
44
45
out = "version.txt" ,
45
46
allow_symlink = True ,
46
47
visibility = visibility ,
0 commit comments