Skip to content

Commit

Permalink
Remove tuning and firewall CNI plugins
Browse files Browse the repository at this point in the history
  • Loading branch information
mgoltzsche committed Sep 24, 2020
1 parent 5c23f21 commit dc8ec32
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ ARG CNI_PLUGIN_VERSION=v0.8.5
RUN git clone --branch=${CNI_PLUGIN_VERSION} https://github.com/containernetworking/plugins /go/src/github.com/containernetworking/plugins
WORKDIR /go/src/github.com/containernetworking/plugins
RUN set -ex; \
for PLUGINDIR in plugins/ipam/host-local plugins/main/loopback plugins/main/bridge plugins/meta/portmap plugins/meta/firewall plugins/meta/tuning; do \
for PLUGINDIR in plugins/ipam/host-local plugins/main/loopback plugins/main/bridge plugins/meta/portmap; do \
PLUGINBIN=/usr/libexec/cni/$(basename $PLUGINDIR); \
CGO_ENABLED=0 go build -o $PLUGINBIN -ldflags "-s -w -extldflags '-static'" ./$PLUGINDIR; \
[ "$(ldd $PLUGINBIN | grep -Ev '^\s+ldd \(0x[0-9a-f]+\)$' | wc -l)" -eq 0 ] || (ldd $PLUGINBIN; false); \
Expand Down Expand Up @@ -131,10 +131,10 @@ COPY --from=cniplugins /usr/libexec/cni /usr/libexec/cni
COPY --from=fuse-overlayfs /usr/bin/fuse-overlayfs /usr/local/bin/fuse-overlayfs
COPY --from=fuse-overlayfs /usr/bin/fusermount3 /usr/local/bin/fusermount3
COPY --from=slirp4netns /slirp4netns/slirp4netns /usr/local/bin/slirp4netns
COPY --from=podman /go/src/github.com/containers/podman/cni/87-podman-bridge.conflist /etc/cni/net.d/
COPY --from=podman /usr/local/bin/podman /usr/local/bin/podman
COPY --from=downloads /usr/local/bin/gosu /usr/local/bin/gosu
COPY --from=runc /usr/local/bin/runc /usr/local/bin/runc
COPY cni /etc/cni
COPY containers.conf storage.conf /etc/containers/
RUN set -eux; \
adduser -D podman -h /podman -u 100000; \
Expand Down
31 changes: 31 additions & 0 deletions cni/net.d/87-podman-bridge.conflist
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{
"cniVersion": "0.4.0",
"name": "podman",
"plugins": [
{
"type": "bridge",
"bridge": "cni-podman0",
"isGateway": true,
"ipMasq": true,
"hairpinMode": true,
"ipam": {
"type": "host-local",
"routes": [{ "dst": "0.0.0.0/0" }],
"ranges": [
[
{
"subnet": "10.88.0.0/16",
"gateway": "10.88.0.1"
}
]
]
}
},
{
"type": "portmap",
"capabilities": {
"portMappings": true
}
}
]
}

0 comments on commit dc8ec32

Please sign in to comment.