Skip to content

Commit d250127

Browse files
committed
Add critest as step to buildkite pipeline.
Signed-off-by: Gavin Inglis <[email protected]>
1 parent ff3394f commit d250127

File tree

7 files changed

+22
-45
lines changed

7 files changed

+22
-45
lines changed

.buildkite/pipeline.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,3 +108,15 @@ steps:
108108
- make -C examples integ-test TEST_POOL=build_${BUILDKITE_BUILD_NUMBER}_example
109109
timeout_in_minutes: 10
110110

111+
- label: ":rotating_light: cri conformance tests"
112+
agents:
113+
queue: "${BUILDKITE_AGENT_META_DATA_QUEUE:-default}"
114+
distro: "${BUILDKITE_AGENT_META_DATA_DISTRO}"
115+
hostname: "${BUILDKITE_AGENT_META_DATA_HOSTNAME}"
116+
env:
117+
DOCKER_IMAGE_TAG: "$BUILDKITE_BUILD_NUMBER"
118+
FICD_DM_VOLUME_GROUP: fcci-vg
119+
command:
120+
- make -C runtime critest FICD_DM_POOL=build_${BUILDKITE_BUILD_NUMBER}_critest
121+
timeout_in_minutes: 10
122+

runtime/Makefile

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,14 +150,18 @@ critest:
150150
--volume /dev:/dev \
151151
--volume /run/udev/control:/run/udev/control \
152152
--volume $(CURDIR)/..:/src \
153+
--volume $(CURDIR)/../examples/etc/containerd/firecracker-runtime.json:/etc/containerd/firecracker-runtime.json \
154+
--volume $(CURDIR)/../tools/demo/fc-br0.interface:/etc/network/interfaces.d/fc-br0 \
155+
--volume $(CURDIR)/logs:/var/log/firecracker-containerd-test \
153156
--volume $(GO_CACHE_VOLUME_NAME):/go \
154157
--env FICD_DM_VOLUME_GROUP=$(FICD_DM_VOLUME_GROUP) \
155158
--env FICD_DM_POOL=$(FICD_DM_POOL) \
156159
--env GOPROXY=direct \
157160
--env GOSUMDB=off \
161+
--env ACK_GINKGO_DEPRECATIONS=1.16.5 \
158162
--workdir="/src/runtime" \
159163
$(FIRECRACKER_CONTAINERD_TEST_IMAGE):$(DOCKER_IMAGE_TAG) \
160-
"critest -runtime-endpoint unix:///run/firecracker-containerd/containerd.sock"
164+
"make -C ../examples testtap && critest -runtime-endpoint unix:///run/firecracker-containerd/containerd.sock"
161165

162166
clean:
163167
- rm -f containerd-shim-aws-firecracker

tools/demo/fcnet.conflist

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"cniVersion": "0.4.0",
2+
"cniVersion": "1.0.0",
33
"name": "fcnet",
44
"plugins": [
55
{
@@ -21,6 +21,9 @@
2121
},
2222
{
2323
"type": "tc-redirect-tap"
24+
},
25+
{
26+
"type": "loopback"
2427
}
2528
]
2629
}

tools/docker/Dockerfile.integ-test

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,7 @@ RUN mkdir -p \
3434
# installs so we can minimize re-runs of the time-expensive downloading of images.
3535
COPY tools/docker/config.toml /etc/containerd/config.toml
3636
COPY tools/docker/do_not_edit_for_firecracker-control.config.json /etc/containerd/firecracker-runtime.json
37-
COPY tools/docker/critest/10-mynet.conf /etc/cni/net.d
38-
COPY tools/docker/critest/99-loopback.conf /etc/cni/net.d
37+
COPY tools/demo/fcnet.conflist /etc/cni/net.d/10-fcnet.conflist
3938

4039
RUN --mount=type=bind,source=firecracker-control/cmd/containerd,target=/src \
4140
make -C /src install && \

tools/docker/critest/10-mynet.conf

Lines changed: 0 additions & 15 deletions
This file was deleted.

tools/docker/critest/99-loopback.conf

Lines changed: 0 additions & 5 deletions
This file was deleted.

tools/docker/entrypoint.sh

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -23,38 +23,17 @@ EOF
2323
cat > /etc/containerd/cri/criconfig.toml <<EOF
2424
version = 2
2525
[plugins]
26-
# The 'plugins."io.containerd.grpc.v1.cri"' table contains all of the server options.
2726
[plugins."io.containerd.grpc.v1.cri"]
28-
29-
# 'plugins."io.containerd.grpc.v1.cri".containerd' contains config related to containerd
3027
[plugins."io.containerd.grpc.v1.cri".containerd]
31-
32-
# snapshotter is the snapshotter used by containerd.
3328
snapshotter = "devmapper"
34-
35-
# default_runtime_name is the default runtime name to use.
3629
default_runtime_name = "containerd-shim-aws-firecracker"
3730
38-
# 'plugins."io.containerd.grpc.v1.cri".containerd.runtimes' is a map from CRI RuntimeHandler strings, which specify types
39-
# of runtime configurations, to the matching configurations.
40-
# In this example, 'runc' is the RuntimeHandler string to match.
4131
[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.containerd-shim-aws-firecracker]
42-
# runtime_type is the runtime type to use in containerd.
43-
# The default value is "io.containerd.runc.v2" since containerd 1.4.
44-
# The default value was "io.containerd.runc.v1" in containerd 1.3, "io.containerd.runtime.v1.linux" in prior releases.
4532
runtime_type = "aws.firecracker"
46-
47-
48-
# conf_dir is the directory in which the admin places a CNI conf.
49-
# this allows a different CNI conf for the network stack when a different runtime is being used.
5033
cni_conf_dir = "/etc/cni/net.d"
5134
52-
# 'plugins."io.containerd.grpc.v1.cri".cni' contains config related to cni
5335
[plugins."io.containerd.grpc.v1.cri".cni]
54-
# bin_dir is the directory in which the binaries for the plugin is kept.
5536
bin_dir = "/opt/cni/bin"
56-
57-
# conf_dir is the directory in which the admin places a CNI conf.
5837
conf_dir = "/etc/cni/net.d"
5938
6039
[debug]

0 commit comments

Comments
 (0)