+ for val in obj:
+ self._vpp_config += '{}{}\n'.format((level + 1) * indent, val)
+ if level >= 0:
+ self._vpp_config += '{}}}\n'.format(level * indent)
+
+ def add_unix_log(self, value=None):
+ """Add UNIX log configuration.
+
+ :param value: Log file.
+ :type value: str
+ """
+ path = ['unix', 'log']
+ if value is None:
+ value = self._vpp_logfile
+ self.add_config_item(self._nodeconfig, value, path)
+
+ def add_unix_cli_listen(self, value='localhost:5002'):
+ """Add UNIX cli-listen configuration.
+
+ :param value: CLI listen address and port or path to CLI socket.
+ :type value: str
+ """
+ path = ['unix', 'cli-listen']
+ self.add_config_item(self._nodeconfig, value, path)
+
+ def add_unix_gid(self, value='vpp'):
+ """Add UNIX gid configuration.
+
+ :param value: Gid.
+ :type value: str
+ """
+ path = ['unix', 'gid']
+ self.add_config_item(self._nodeconfig, value, path)
+
+ def add_unix_nodaemon(self):
+ """Add UNIX nodaemon configuration."""
+ path = ['unix', 'nodaemon']
+ self.add_config_item(self._nodeconfig, '', path)
+
+ def add_unix_coredump(self):
+ """Add UNIX full-coredump configuration."""
+ path = ['unix', 'full-coredump']
+ self.add_config_item(self._nodeconfig, '', path)
+
+ def add_unix_exec(self, value):
+ """Add UNIX exec configuration."""
+ path = ['unix', 'exec']
+ self.add_config_item(self._nodeconfig, value, path)
+
+ def add_api_segment_gid(self, value='vpp'):
+ """Add API-SEGMENT gid configuration.
+
+ :param value: Gid.
+ :type value: str
+ """
+ path = ['api-segment', 'gid']
+ self.add_config_item(self._nodeconfig, value, path)
+
+ def add_api_segment_global_size(self, value):
+ """Add API-SEGMENT global-size configuration.
+
+ :param value: Global size.
+ :type value: str
+ """
+ path = ['api-segment', 'global-size']
+ self.add_config_item(self._nodeconfig, value, path)
+
+ def add_api_segment_api_size(self, value):
+ """Add API-SEGMENT api-size configuration.
+
+ :param value: API size.
+ :type value: str
+ """
+ path = ['api-segment', 'api-size']
+ self.add_config_item(self._nodeconfig, value, path)