blob: 08070d0443514a05d3b7552fe57014cb1d4c7a7b [file] [log] [blame] [view]
Davide Pesavento4a160042020-04-13 16:50:02 -04001# Installing repo-ng
Shuo Chen050fcad2014-03-12 15:45:54 -07002
Davide Pesavento4a160042020-04-13 16:50:02 -04003## Prerequisites
Shuo Chen050fcad2014-03-12 15:45:54 -07004
Davide Pesaventoe9b09b82023-01-19 13:30:07 -05005* [ndn-cxx and its dependencies](https://docs.named-data.net/ndn-cxx/current/INSTALL.html)
Shuo Chen478204c2014-03-18 18:27:04 -07006* sqlite3
Shuo Chen050fcad2014-03-12 15:45:54 -07007
Davide Pesavento4a160042020-04-13 16:50:02 -04008## Build
Shuo Chen050fcad2014-03-12 15:45:54 -07009
Davide Pesavento4a160042020-04-13 16:50:02 -040010To build in a terminal, change to the directory containing the repo-ng repository.
11Then enter:
Shuo Chen050fcad2014-03-12 15:45:54 -070012
Davide Pesaventocf9feb42024-04-22 23:08:25 -040013```shell
14./waf configure
15./waf
16sudo ./waf install
17```
Shuo Chen050fcad2014-03-12 15:45:54 -070018
Junxiao Shi434fa492017-06-15 00:37:54 +000019This builds and installs `ndn-repo-ng` and related tools.
Shuo Chen050fcad2014-03-12 15:45:54 -070020
Davide Pesaventoe9b09b82023-01-19 13:30:07 -050021If configured with tests (`./waf configure --with-tests`), the above commands
22will also generate unit tests that can be run with `./build/unit-tests`.
Weiqi Shibd469da2014-08-21 10:08:51 -070023
Davide Pesavento4a160042020-04-13 16:50:02 -040024## Configuration
Weiqi Shibd469da2014-08-21 10:08:51 -070025
Junxiao Shi434fa492017-06-15 00:37:54 +000026The default configuration file path is `/usr/local/etc/ndn/repo-ng.conf`.
Davide Pesaventoe9b09b82023-01-19 13:30:07 -050027Users may copy the [`repo-ng.conf.sample`](repo-ng.conf.sample) example config
28to that path.
Weiqi Shibd469da2014-08-21 10:08:51 -070029
Davide Pesavento4a160042020-04-13 16:50:02 -040030## Database
Weiqi Shibd469da2014-08-21 10:08:51 -070031
Davide Pesavento4a160042020-04-13 16:50:02 -040032The database path is set in the `storage.path` key of the configuration file.
Davide Pesavento4162cc52019-01-25 01:32:30 -050033The default database path is `/var/lib/ndn/repo-ng`.
Weiqi Shibd469da2014-08-21 10:08:51 -070034
Davide Pesavento4a160042020-04-13 16:50:02 -040035repo-ng will automatically create a database if one does not exist.
Weiqi Shibd469da2014-08-21 10:08:51 -070036
Davide Pesavento4a160042020-04-13 16:50:02 -040037Users should make sure that the `ndn-repo-ng` process has write access to the
38database directory.
Weiqi Shibd469da2014-08-21 10:08:51 -070039
Davide Pesavento4a160042020-04-13 16:50:02 -040040## Tools
Weiqi Shibd469da2014-08-21 10:08:51 -070041
Davide Pesaventoe9b09b82023-01-19 13:30:07 -050042Currently, three tools are included: `ndngetfile`, `ndnputfile`, and `repo-ng-ls`.
Davide Pesavento4a160042020-04-13 16:50:02 -040043Users can find detailed information about these tools on the
44[repo-ng wiki](https://redmine.named-data.net/projects/repo-ng/wiki/Tools).