1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
|
licenses(["notice"]) # Apache 2.0
TEST_TARGETS = [
"base_with_entrypoint",
"base_with_volume",
"derivative_with_cmd",
"derivative_with_shadowed_cmd",
"derivative_with_volume",
"files_base",
"files_with_files_base",
"files_with_tar_base",
"tar_base",
"tar_with_files_base",
"tar_with_tar_base",
"generated_tarball",
"with_env",
"with_double_env",
"link_with_files_base",
]
TEST_DATA = [
"//tools/build_defs/docker/testdata:" + t
for t in TEST_TARGETS
] + [
"//tools/build_defs/docker/testdata:notop_" + t
for t in TEST_TARGETS
] + [
"//tools/build_defs/docker/testdata:gen_image",
]
sh_test(
name = "build_test",
size = "medium",
srcs = [
"build_test.sh",
],
data = TEST_DATA + ["testenv.sh"],
deps = [
"//src/test/shell:bashunit",
],
)
# Used by docker_build and friends
py_library(
name = "archive",
srcs = ["archive.py"],
visibility = ["//tools/build_defs/docker:__subpackages__"],
)
py_test(
name = "archive_test",
srcs = [
"archive_test.py",
"testenv.py",
],
data = ["//tools/build_defs/docker/testdata:archive_testdata"],
deps = [":archive"],
)
py_binary(
name = "rewrite_json",
srcs = ["rewrite_json.py"],
visibility = ["//visibility:public"],
deps = ["//third_party/py/gflags"],
)
py_test(
name = "rewrite_json_test",
srcs = ["rewrite_json_test.py"],
deps = [
":rewrite_json",
],
)
py_binary(
name = "build_layer",
srcs = ["build_layer.py"],
visibility = ["//visibility:public"],
deps = [
":archive",
"//third_party/py/gflags",
],
)
py_binary(
name = "sha256",
srcs = ["sha256.py"],
visibility = ["//visibility:public"],
)
py_binary(
name = "create_image",
srcs = ["create_image.py"],
visibility = ["//visibility:public"],
deps = [
":archive",
"//third_party/py/gflags",
],
)
|