]> git.proxmox.com Git - mirror_iproute2.git/commit
Allow to configure /var/run/netns directory
authorPavel Maltsev <pavelm@google.com>
Fri, 18 May 2018 22:44:00 +0000 (15:44 -0700)
committerStephen Hemminger <stephen@networkplumber.org>
Wed, 23 May 2018 22:16:53 +0000 (15:16 -0700)
commite2f5ceccdab52d667873c84a744d8ba2c091fbac
treee1d5ffc7589c96a119a02a02d416d50113362078
parent405e0c4ffe7a410b09201db42955089fb0033776
Allow to configure /var/run/netns directory

Currently NETNS_RUN_DIR is hardcoded and refers to /var/run/netns.
However, some systems (e.g. Android) doesn't have /var
which results in error attempts to create network namespaces on these
systems.  This change makes NETNS_RUN_DIR configurable at build time
by allowing to pass environment variable to make command.
Also, this change makes /etc/netns directory configurable through
NETNS_ETC_DIR environment variable.

For example: ./configure && NETNS_RUN_DIR=/mnt/vendor/netns make

Tested: verified that iproute2 with configuration mentioned above
creates namespaces in /mnt/vendor/netns

Signed-off-by: Pavel Maltsev <pavelm@google.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Makefile
include/namespace.h