Add working directory option
refs: #3266
Change-Id: Ifd953b242c99f75c68eb3c63ef5e51ef46195b8b
diff --git a/ndn/ndn_host.py b/ndn/ndn_host.py
index bc820c2..0bed247 100644
--- a/ndn/ndn_host.py
+++ b/ndn/ndn_host.py
@@ -93,6 +93,11 @@
if not NdnHost.inited:
NdnHostCommon.init()
+ # Create home directory for a node
+ self.homeFolder = "%s/%s" % (self.params['workdir'], self.name)
+ self.cmd("mkdir -p %s" % self.homeFolder)
+ self.cmd("cd %s" % self.homeFolder)
+
self.nfd = Nfd(self)
self.nfd.start()
@@ -123,6 +128,11 @@
if not NdnHost.inited:
NdnHostCommon.init()
+ # Create home directory for a node
+ self.homeFolder = "%s/%s" % (self.params['workdir'], self.name)
+ self.cmd("mkdir -p %s" % self.homeFolder)
+ self.cmd("cd %s" % self.homeFolder)
+
self.nfd = Nfd(self)
self.nfd.start()