Skip to content
This repository was archived by the owner on Feb 6, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions prelude-si/docker.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ docker_image = rule(
doc = """Mapping of sources files to the relative directory in a Dockerfile context..""",
),
"build_deps": attrs.list(
attrs.string(),
attrs.dep(),
default = [],
doc = """Buck2 targets that could be built in an image.""",
),
Expand Down Expand Up @@ -219,7 +219,7 @@ def docker_build_context(ctx: "context") -> DockerBuildContext.type:
cmd.add(cmd_args(src, format = "{}=" + rel_path))
for dep in ctx.attrs.build_deps or []:
cmd.add("--dep")
cmd.add(dep)
cmd.add(dep.label.raw_target())
cmd.add(context_tree.as_output())

ctx.actions.run(cmd, category = "docker_build_context")
Expand Down
4 changes: 3 additions & 1 deletion prelude-si/docker/docker_build_context_srcs_from_deps.bxl
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,9 @@ docker_build_context_srcs_from_deps = bxl(
)

def _normalize_target_str(dep: str.type) -> str.type:
if dep.startswith("//"):
if dep.startswith("root//"):
return dep
elif dep.startswith("//"):
return "root" + dep
else:
return "root//{}".format(dep)
Expand Down