diff --git a/cc/image.bzl b/cc/image.bzl index f7cd60080..e2be84c59 100644 --- a/cc/image.bzl +++ b/cc/image.bzl @@ -63,13 +63,14 @@ DEFAULT_BASE = select({ "//conditions:default": "@cc_image_base//image", }) -def cc_image(name, base = None, deps = [], layers = [], binary = None, **kwargs): +def cc_image(name, base = None, deps = [], layers = [], env = {}, binary = None, **kwargs): """Constructs a container image wrapping a cc_binary target. Args: name: Name of the cc_image target. base: Base image to use for the cc_image. deps: Dependencies of the cc_image. + env: Environment variables for the cc_image. binary: An alternative binary target to use instead of generating one. layers: Augments "deps" with dependencies that should be put into their own layers. @@ -97,6 +98,7 @@ def cc_image(name, base = None, deps = [], layers = [], binary = None, **kwargs) binary = binary, visibility = visibility, tags = tags, + env = env, args = kwargs.get("args"), data = kwargs.get("data"), testonly = kwargs.get("testonly"),