浏览代码

add: read.me for netns

micha 3 年之前
父节点
当前提交
ce03ab24e1
共有 1 个文件被更改,包括 12 次插入0 次删除
  1. 12 0
      read.me

+ 12 - 0
read.me

@@ -0,0 +1,12 @@
+#copy this dir ASP/netns to /opt/ as root 
+cp netns /opt/
+chown -R root:root /opt/netns
+
+# add with sudo visudo
+user      ALL=(ALL) NOPASSWD:/opt/netns/_exec, /opt/netns/create
+
+# now "user" can create "ip netns" with
+sudo /opt/netns/create 14
+
+# and attache as "user" any cmd to it with
+/opt/netns/exec --id=14 --cmd=bash