Skip to content
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: 1 addition & 3 deletions score/test/component/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,7 @@ pkg_tar(

pkg_tar(
name = "_datarouter_conf_pkg",
srcs = ["//score/test/component/datarouter:datarouter_test_config_files"],
package_dir = "opt/datarouter",
strip_prefix = "/score/test/component/datarouter",
srcs = ["//score/test/component/datarouter:datarouter_docker_config_pkg"],
target_compatible_with = ["@platforms//os:linux"],
)

Expand Down
15 changes: 14 additions & 1 deletion score/test/component/datarouter/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# *******************************************************************************

load("@rules_cc//cc:cc_binary.bzl", "cc_binary")
load("@rules_pkg//pkg:mappings.bzl", "pkg_attributes", "pkg_filegroup", "pkg_files")
load("@rules_pkg//pkg:mappings.bzl", "pkg_attributes", "pkg_filegroup", "pkg_files", "strip_prefix")
load("@rules_pkg//pkg:tar.bzl", "pkg_tar")
load("//score/test/component:defs.bzl", "py_logging_itf_test")

Expand Down Expand Up @@ -95,6 +95,19 @@ pkg_files(
visibility = ["//score/test/component:__subpackages__"],
)

# Docker image config. Package-relative strip so the etc/ files resolve to
# opt/datarouter/etc/* whether score_logging is built as the root module or
# consumed as an external dependency (an absolute strip_prefix only matches
# when logging is root and silently leaves the external/score_logging+/ prefix
# otherwise).
pkg_files(
name = "datarouter_docker_config_pkg",
srcs = [":datarouter_test_config_files"],
prefix = "opt/datarouter",
strip_prefix = strip_prefix.from_pkg(),
visibility = ["//score/test/component:__subpackages__"],
)

py_logging_itf_test(
name = "test_datarouter_filters",
srcs = ["test_datarouter_filters.py"],
Expand Down
Loading