WG-NETNS(1)

NAME
wg-netns - create network namespace with wireguard tunnel

SYNOPSIS
wg-netns up profile{.json|.yaml|.yml}
wg-netns down [-f] profile{.json|.yaml|.yml}
wg-netns list
wg-netns switch netns
wg-netns exec netns program [argument]…

DESCRIPTION
wg-netns up reads $WG_PROFILE_DIR/profile and creates the network namespaces specified therein.

wg-netns down destroys the same. -f|--force ignores any errors.

wg-netns list provides functionality equivalent to ip netns.

wg-netns exec executes program argument… in the specified netns.

wg-netns switch is equivalent to wg-netns exec $SHELL -i in netns.

ENVIRONMENT
WG_PROFILE_DIR
    Directory to search for profiles in Defaults to /etc/wireguard.
WG_NETNS_DIR
    Directory to keep netns configuration files (resolv.conf) in. Defaults to /etc/netns.
WG_VERBOSE
    If set and non-zero, log every command executed to the standard error stream.
SHELL
    Shell to use in switch.
WG_SHELL
    Shell to use for shell hooks. Defaults to /bin/sh.

FILES
See /usr/share/doc/wg-netns/minimal.json and /usr/share/doc/wg-netns/full.yaml for example profiles.

SEE ALSO
wg(1), wg-quick(1), ip-netns(8), wg-netns@.service