Add docker container with iptables

Used for dropping packets on a specific port.

Needs to be launched with the NET_ADMIN and NET_RAW capabilities to be
able to actually be able to interact with iptables, this is done in
docker-compose.

Change-Id: I5093d19fbc269f42fe3e314e9344866fa5b79999
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
This commit is contained in:
Mårten Nordheim
2019-02-12 17:08:12 +01:00
committed by Liang Qi
parent 03a0872a34
commit 5c9979a995
3 changed files with 10 additions and 2 deletions

View File

@@ -0,0 +1,4 @@
FROM ubuntu:16.04
ARG packages="iptables avahi-daemon"
RUN apt-get update && apt-get install -y $packages && dpkg -l $packages
EXPOSE 1357

View File

@@ -0,0 +1,4 @@
FROM ubuntu:18.04
ARG packages="iptables avahi-daemon"
RUN apt-get update && apt-get install -y $packages && dpkg -l $packages
EXPOSE 1357

View File

@@ -34,5 +34,5 @@
set -ex
# A list of test servers to be provisioned
testserver='apache2 squid vsftpd ftp-proxy danted echo cyrus'
testserver="$testserver apache2_18.04 squid_18.04 vsftpd_18.04 ftp-proxy_18.04 danted_18.04 echo_18.04 cyrus_18.04"
testserver='apache2 squid vsftpd ftp-proxy danted echo cyrus iptables'
testserver="$testserver apache2_18.04 squid_18.04 vsftpd_18.04 ftp-proxy_18.04 danted_18.04 echo_18.04 cyrus_18.04 iptables_18.04"