ntopng/doc/src
2020-01-21 16:05:38 +01:00
..
_static/css Initial flow api documentation 2019-10-10 17:16:39 +02:00
advanced_features Plugins documentation: flow plugin example and explanation 2020-01-17 16:16:23 +01:00
api Replace anomalous with misbehaving to avoid inconsistencies (fix #2866) 2020-01-14 15:49:19 +01:00
basic_concepts typo and minor grammar fixes like a/an (#2735) 2019-07-22 09:10:57 +02:00
doxygen Fix documentation errors in .lua.cpp files 2019-07-01 18:40:14 +02:00
how_to_start Updates the documentation to run multiple ntopng instances 2019-08-16 14:34:51 +02:00
img Doc update: data encryption over ZMQ 2019-11-21 17:50:22 +01:00
plugins Moves plugin description to manifest.lua 2020-01-21 16:05:38 +01:00
web_gui User management doc update 2020-01-14 10:42:19 +01:00
cli_options.rst Sticky hosts doc update 2019-10-14 18:52:49 +02:00
conf.py Minor doc update with callback_utils.foreachFlow example 2019-06-25 16:21:09 +02:00
example.rst Add Device Protocols and Policy test page docs 2018-10-08 18:16:43 +02:00
example_api.lua Initial flow api documentation 2019-10-10 17:16:39 +02:00
faq.rst Describe how to reset ntopng preferences 2019-07-02 17:49:26 +02:00
historical_flows.rst Add historical flows documentation 2018-12-19 13:26:35 +01:00
index.rst Plugins documentation: skeleton and introduction 2020-01-17 13:23:48 +01:00
Makefile lua doxygen documentation skeleton and integration with read the docs 2018-05-31 01:46:42 +02:00
operating_ntopng_on_large_networks.rst Documents best practices to optimize ntopng 2018-11-08 18:25:41 +01:00
README.md Fix documentation errors in .lua.cpp files 2019-07-01 18:40:14 +02:00
remote_assistance.rst Improve remote assistance doc 2018-12-17 18:10:09 +01:00
traffic_recording.rst Moved section 2019-02-19 12:15:30 +01:00
using_with_nprobe.rst Doc update: data encryption over ZMQ 2019-11-21 17:50:22 +01:00
using_with_nprobe_agent.rst Docs improvements 2019-06-18 18:02:07 +02:00
what_is_ntopng.rst Removes licenses generation link 2019-02-11 11:47:48 +01:00

Documentation

Ntopng documentation uses read the docs and .rst file format.

Requirements

On ubuntu:

apt-get install doxygen
pip install breathe sphinx==1.7.9

Note: newer sphinx versions (e.g. 1.8.0) have a bug with search: https://github.com/sphinx-doc/sphinx/issues/5460

Generate

The ntopng documentation can be generated by executing make release.

It can be easily tested locally by running a python webserver:

  pushd _build/html; python -m SimpleHTTPServer 8080; popd

Lua C API

The Lua C API documentation can be found inside the api/lua_c directory.

The functions documentation is written in .lua file (e.g. api/lua_c/ntop/ntop_users.lua). These are the files to modify to update the api documentation.

Functions are organized in a directory structure in the form api/lua_c/{object}/{api_group}.lua, where {object} is a C API reg (eg. interface) and {api_group} is a group of api functions relevant to the same topic (e.g. interface_hosts is for api functions that work with hosts).

Only a subset of the functions defined in src/LuaEngine.cpp are documented as API. They are marked with the // ***API*** comment. Whenever an API function is modified, the corresponding documentation file should be updated.

Here is how to perform some recurrent operations on the documentation:

  • Add/modify a function documentation: e.g. to update the ntop.setCache documentation, the file api/lua_c/ntop/ntop_cache.lua should be modified.

  • Add a new group of api functions for an existing C API reg: e.g. to group together all the host pools functions, the following modifications should be performed:

    • create api/lua_c/interface/interface_host_pools.lua.
    • create api/lua_c/interface/interface_host_pools.rst. Adapt this from an existing .rst.
    • edit api/lua_c/interface/index.rst and add interface_host_pools to the toctree section.
  • Add a new C API reg: e.g. to add a new db reg so that we can call db.some_function functions, it's necessary to:

    • create api/lua_c/db/index.rst. Adapt this from an existing .rst.
    • edit api/lua_c/index.rst and add db/index to the toctree section.