repo-ng: New package
diff --git a/repo-ng/Makefile b/repo-ng/Makefile
new file mode 100644
index 0000000..dbd6a7a
--- /dev/null
+++ b/repo-ng/Makefile
@@ -0,0 +1,16 @@
+# URL for git clone
+GIT_URL=https://github.com/named-data/repo-ng
+
+# Tag name or commit hash for checkout
+GIT_VERSION=91fb4f2e5067d2fd6a591d885353a449bc65b399
+
+# Package name
+NAME=repo-ng
+
+# Package version
+VERSION=0.0.0
+
+# PPA version
+PPA_VERSION=1
+
+include ../packaging.mk
diff --git a/repo-ng/debian/changelog b/repo-ng/debian/changelog
new file mode 100644
index 0000000..4e1e15f
--- /dev/null
+++ b/repo-ng/debian/changelog
@@ -0,0 +1,5 @@
+repo-ng (0.0.0~ppa0~DISTRO) DISTRO; urgency=low
+
+ * Initial release
+
+ -- Alexander Afanasyev <alexander.afanasyev@ucla.edu> Sat, 24 May 2014 16:58:30 -0800
diff --git a/repo-ng/debian/compat b/repo-ng/debian/compat
new file mode 100644
index 0000000..45a4fb7
--- /dev/null
+++ b/repo-ng/debian/compat
@@ -0,0 +1 @@
+8
diff --git a/repo-ng/debian/control b/repo-ng/debian/control
new file mode 100644
index 0000000..649ac67
--- /dev/null
+++ b/repo-ng/debian/control
@@ -0,0 +1,19 @@
+Source: ndn-tlv-ping
+Priority: extra
+Maintainer: Alexander Afanasyev <alexander.afanasyev@ucla.edu>
+Build-Depends: debhelper (>= 8.0.0),
+ python (>= 2.7.0),
+ pkg-config (>= 0.26),
+ ndn-cxx-dev (>= 0.1.0~rc1)
+Standards-Version: 3.9.2
+Section: net
+Homepage: http://github.com/named-data/repo-ng
+Vcs-Git: git://github.com/named-data/repo-ng.git
+Vcs-Browser: http://github.com/named-data/repo-ng
+
+Package: repo-ng
+Architecture: i386 amd64
+Depends: ${shlibs:Depends}, ${misc:Depends}, ndn-cxx
+Description: Next generation of NDN repository
+ repo-ng is an implementation of a Named Data Networking data repository with the protocol
+ defined on NDN wiki: http://redmine.named-data.net/projects/repo-ng/wiki
diff --git a/repo-ng/debian/copyright b/repo-ng/debian/copyright
new file mode 100644
index 0000000..75455e7
--- /dev/null
+++ b/repo-ng/debian/copyright
@@ -0,0 +1,33 @@
+Format: http://dep.debian.net/deps/dep5
+Upstream-Name: repo-ng
+Source: http://github.com/named-data/repo-ng
+
+Files: *
+Copyright: Copyright (c) 2014, Regents of the University of California.
+License: GPL-3+
+
+Files: debian/*
+Copyright: Copyright (c) 2013-2014, Alexander Afanasyev <alexander.afanasyev@ucla.edu>
+License: BSD
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+ * Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+ * Neither the name of the Regents of the University of California nor
+ the names of its contributors may be used to endorse or promote
+ products derived from this software without specific prior written
+ permission.
+ .
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ ARE DISCLAIMED. IN NO EVENT SHALL REGENTS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
+ OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+ EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/repo-ng/debian/repo-ng.conf b/repo-ng/debian/repo-ng.conf
new file mode 100644
index 0000000..babd882
--- /dev/null
+++ b/repo-ng/debian/repo-ng.conf
@@ -0,0 +1,37 @@
+repo
+{
+ ; Section defining list of Data prefixes to register
+ ; Only 'prefix' option is allowed here, which can be repeated multiple times
+ data
+ {
+ prefix "ndn:/localhost/repo-ng"
+ }
+
+ ; Section defining list of command prefixes (to insert or delete Data) to register.
+ ; Only 'prefix' option is allowed here, which can be repeated multiple times
+ command
+ {
+ prefix "ndn:/localhost/repo-ng"
+ }
+
+ ; Section to specify where data should be stored
+ ; Right now only a single 'sqlite' option is allowed:
+ storage
+ {
+ method "sqlite" ; Currently, only sqlite storage engine is supported
+ path "/var/lib/ndn/repo-ng" ; path to repo-ng storage folder
+ }
+
+ ; Section to enable TCP bulk insert capability
+ ; If section is present, then TCP bulk insert is enabled (empty section enables
+ ; TCP bulk insert to listen on "localhost:7376")
+ tcp_bulk_insert {
+ ; host "localhost" ; Set to listen on different IP address or hostname
+ ; port 7376 ; Set to listen on different port number
+ }
+
+ validator
+ {
+ policy "not implemented yet"
+ }
+}
diff --git a/repo-ng/debian/repo-ng.dirs b/repo-ng/debian/repo-ng.dirs
new file mode 100644
index 0000000..b7e4468
--- /dev/null
+++ b/repo-ng/debian/repo-ng.dirs
@@ -0,0 +1,2 @@
+etc/ndn
+usr/bin
diff --git a/repo-ng/debian/repo-ng.install b/repo-ng/debian/repo-ng.install
new file mode 100644
index 0000000..2e5745a
--- /dev/null
+++ b/repo-ng/debian/repo-ng.install
@@ -0,0 +1,3 @@
+etc/ndn/*
+debian/repo-ng.conf etc/ndn/
+usr/bin/*
diff --git a/repo-ng/debian/repo-ng.postinst b/repo-ng/debian/repo-ng.postinst
new file mode 100644
index 0000000..d64684a
--- /dev/null
+++ b/repo-ng/debian/repo-ng.postinst
@@ -0,0 +1,19 @@
+#!/bin/sh -e
+
+if [ "$1" != "configure" ]; then
+ exit 0
+fi
+
+APP=repo-ng
+
+if [ ! -f /var/lib/ndn/$APP/.ndn/ndnsec-public-info.db ]; then
+ # Create HOME and generate self-signed NDN certificate
+ sudo mkdir -p /var/lib/ndn/$APP/.ndn
+ sudo chown -R ndn:ndn /var/lib/ndn/$APP
+ sudo -u ndn -g ndn HOME=/var/lib/ndn/$APP ndnsec-keygen /localhost/daemons/$APP | \
+ sudo -u ndn -g ndn HOME=/var/lib/ndn/$APP ndnsec-install-cert -
+fi
+
+#DEBHELPER#
+
+exit 0
diff --git a/repo-ng/debian/repo-ng.upstart b/repo-ng/debian/repo-ng.upstart
new file mode 100644
index 0000000..96940f9
--- /dev/null
+++ b/repo-ng/debian/repo-ng.upstart
@@ -0,0 +1,16 @@
+description "New generation of NDN repo"
+author "Alexander Afanasyev <alexander.afanasyev@ucla.edu>"
+
+start on started nrd
+stop on stopping nrd
+
+respawn
+respawn limit unlimited
+
+setuid ndn
+setgid ndn
+
+script
+ export HOME=/var/lib/ndn/repo-ng
+ exec /usr/bin/ndn-repo-ng -c /etc/ndn/repo-ng.conf
+end script
diff --git a/repo-ng/debian/rules b/repo-ng/debian/rules
new file mode 100755
index 0000000..dfbc583
--- /dev/null
+++ b/repo-ng/debian/rules
@@ -0,0 +1,36 @@
+#!/usr/bin/make -f
+# -*- makefile -*-
+# Sample debian/rules that uses debhelper.
+# This file was originally written by Joey Hess and Craig Small.
+# As a special exception, when this file is copied by dh-make into a
+# dh-make output file, you may use that output file without restriction.
+# This special exception was added by Craig Small in version 0.37 of dh-make.
+
+# Uncomment this to turn on verbose mode.
+# export DH_VERBOSE=1
+
+LDFLAGS := $(shell dpkg-buildflags --get LDFLAGS)
+
+%:
+ dh $@ --parallel
+
+override_dh_auto_configure:
+ ./waf --nocache configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
+
+override_dh_auto_build:
+ ./waf --nocache build
+
+override_dh_auto_install:
+ ./waf install --destdir=debian/tmp
+
+override_dh_auto_clean:
+ ./waf distclean
+
+override_dh_clean:
+ dh_clean
+ ./waf distclean
+ rm -rf .waf-1*
+ rm -rf .waf3-1*
+ rm -f .waf-tools/*.pyc
+
+override_dh_auto_test:
diff --git a/repo-ng/debian/source/format b/repo-ng/debian/source/format
new file mode 100644
index 0000000..163aaf8
--- /dev/null
+++ b/repo-ng/debian/source/format
@@ -0,0 +1 @@
+3.0 (quilt)