diff options
author | Jonathan Bauer | 2019-05-23 14:15:18 +0200 |
---|---|---|
committer | Jonathan Bauer | 2019-05-23 14:15:18 +0200 |
commit | 0594681640a253a564a917c3226c342b24aeda0a (patch) | |
tree | 4842168afbb50c5d1d95269ab3ae4242a8089686 | |
parent | [networkd-dispatcher] retry reverse lookup (diff) | |
download | mltk-0594681640a253a564a917c3226c342b24aeda0a.tar.gz mltk-0594681640a253a564a917c3226c342b24aeda0a.tar.xz mltk-0594681640a253a564a917c3226c342b24aeda0a.zip |
[iptables] move iptables to its own module
-rw-r--r-- | core/modules/iptables-helper/module.conf | 4 | ||||
-rw-r--r-- | core/modules/iptables/module.build | 20 | ||||
-rw-r--r-- | core/modules/iptables/module.conf | 7 | ||||
-rw-r--r-- | core/modules/iptables/module.conf.ubuntu | 3 | ||||
-rw-r--r-- | core/modules/run-virt/module.conf | 3 | ||||
-rw-r--r-- | core/rootfs/rootfs-stage32/module.conf | 2 | ||||
-rw-r--r-- | core/rootfs/rootfs-stage32/module.conf.ubuntu | 3 | ||||
l--------- | core/targets/stage32-bwlp/iptables | 1 |
8 files changed, 37 insertions, 6 deletions
diff --git a/core/modules/iptables-helper/module.conf b/core/modules/iptables-helper/module.conf index c72d5f27..46eb4e93 100644 --- a/core/modules/iptables-helper/module.conf +++ b/core/modules/iptables-helper/module.conf @@ -1,2 +1,4 @@ #!/bin/bash -# requires some rootfs that provies iptables +REQUIRED_MODULES=" + iptables +" diff --git a/core/modules/iptables/module.build b/core/modules/iptables/module.build new file mode 100644 index 00000000..4012ec43 --- /dev/null +++ b/core/modules/iptables/module.build @@ -0,0 +1,20 @@ +#!/bin/bash +fetch_source() { + : +} + +build() { + local BIN_LOCATION + for BIN in $REQUIRED_BINARIES; do + BIN_LOCATION="$(which ${BIN})" + pinfo "$BIN_LOCATION" + if [ -z "$BIN_LOCATION" ]; then + perror "'$BIN' not found on the system. Install it." + fi + tarcopy "$(get_link_chain ${BIN_LOCATION})" "${MODULE_BUILD_DIR}" + done +} + +post_copy() { + : +} diff --git a/core/modules/iptables/module.conf b/core/modules/iptables/module.conf new file mode 100644 index 00000000..353859e6 --- /dev/null +++ b/core/modules/iptables/module.conf @@ -0,0 +1,7 @@ +REQUIRED_BINARIES=" + iptables + ip6tables +" +REQUIRED_SYSTEM_FILES+=" + /usr/lib/x86_64-linux-gnu/xtables +" diff --git a/core/modules/iptables/module.conf.ubuntu b/core/modules/iptables/module.conf.ubuntu new file mode 100644 index 00000000..01b6d246 --- /dev/null +++ b/core/modules/iptables/module.conf.ubuntu @@ -0,0 +1,3 @@ +REQUIRED_INSTALLED_PACKAGES=" + iptables +" diff --git a/core/modules/run-virt/module.conf b/core/modules/run-virt/module.conf index 2c8c505a..b6de1789 100644 --- a/core/modules/run-virt/module.conf +++ b/core/modules/run-virt/module.conf @@ -1,4 +1,7 @@ #!/bin/bash +REQUIRED_MODULES=" + iptables +" REQUIRED_BINARIES=" lsusb mcopy diff --git a/core/rootfs/rootfs-stage32/module.conf b/core/rootfs/rootfs-stage32/module.conf index 1e5ad0ad..70e068ff 100644 --- a/core/rootfs/rootfs-stage32/module.conf +++ b/core/rootfs/rootfs-stage32/module.conf @@ -38,8 +38,6 @@ REQUIRED_BINARIES=" bc dirname mkdosfs - iptables - ip6tables rdns find rpcbind diff --git a/core/rootfs/rootfs-stage32/module.conf.ubuntu b/core/rootfs/rootfs-stage32/module.conf.ubuntu index 7a66387a..b4598fe5 100644 --- a/core/rootfs/rootfs-stage32/module.conf.ubuntu +++ b/core/rootfs/rootfs-stage32/module.conf.ubuntu @@ -18,9 +18,6 @@ REQUIRED_CONTENT_PACKAGES=" REQUIRED_BINARIES+=" openssl " -REQUIRED_SYSTEM_FILES+=" - /usr/lib/x86_64-linux-gnu/xtables -" REQUIRED_FILES+=" /etc/X11/app-defaults/Xvidtune /usr/lib/ssl/openssl.cnf diff --git a/core/targets/stage32-bwlp/iptables b/core/targets/stage32-bwlp/iptables new file mode 120000 index 00000000..1f5e94e4 --- /dev/null +++ b/core/targets/stage32-bwlp/iptables @@ -0,0 +1 @@ +../../modules/iptables
\ No newline at end of file |