From 96df285e85adf386ea7c11be64aca648941c4bd8 Mon Sep 17 00:00:00 2001 From: Kiall Mac Innes Date: Fri, 27 Sep 2013 12:18:53 +0100 Subject: [PATCH] Add packaging --- .gitignore | 7 +++++++ debian/beaver.conf.sample | 2 ++ debian/beaver.dirs | 3 +++ debian/beaver.install | 2 ++ debian/beaver.ucf | 1 + debian/beaver.upstart | 8 ++++++++ debian/changelog | 24 ++++++++++++++++++++++ debian/compat | 1 + debian/control | 40 ++++++++++++++++++++++++++++++++++++ debian/copyright | 40 ++++++++++++++++++++++++++++++++++++ debian/gbp.conf | 3 +++ debian/pydist-overrides | 0 debian/python-beaver.install | 1 + debian/rules | 21 +++++++++++++++++++ debian/source/format | 1 + debian/watch | 2 ++ 16 files changed, 156 insertions(+) create mode 100644 .gitignore create mode 100644 debian/beaver.conf.sample create mode 100644 debian/beaver.dirs create mode 100644 debian/beaver.install create mode 100644 debian/beaver.ucf create mode 100644 debian/beaver.upstart create mode 100644 debian/changelog create mode 100644 debian/compat create mode 100644 debian/control create mode 100644 debian/copyright create mode 100644 debian/gbp.conf create mode 100644 debian/pydist-overrides create mode 100644 debian/python-beaver.install create mode 100755 debian/rules create mode 100644 debian/source/format create mode 100644 debian/watch diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..576c544 --- /dev/null +++ b/.gitignore @@ -0,0 +1,7 @@ +*.pyc +*.egg +*.egg-info +*.swp +build +dist +pkg diff --git a/debian/beaver.conf.sample b/debian/beaver.conf.sample new file mode 100644 index 0000000..e63f536 --- /dev/null +++ b/debian/beaver.conf.sample @@ -0,0 +1,2 @@ +[beaver] +files: /var/log/syslog,/var/log/*.log \ No newline at end of file diff --git a/debian/beaver.dirs b/debian/beaver.dirs new file mode 100644 index 0000000..22683e3 --- /dev/null +++ b/debian/beaver.dirs @@ -0,0 +1,3 @@ +etc +usr/share/beaver +var/lib/beaver \ No newline at end of file diff --git a/debian/beaver.install b/debian/beaver.install new file mode 100644 index 0000000..1608e52 --- /dev/null +++ b/debian/beaver.install @@ -0,0 +1,2 @@ +usr/bin/beaver +debian/beaver.conf.sample usr/share/beaver \ No newline at end of file diff --git a/debian/beaver.ucf b/debian/beaver.ucf new file mode 100644 index 0000000..888a3ff --- /dev/null +++ b/debian/beaver.ucf @@ -0,0 +1 @@ +/usr/share/beaver/beaver.conf.sample /etc/beaver.conf \ No newline at end of file diff --git a/debian/beaver.upstart b/debian/beaver.upstart new file mode 100644 index 0000000..7fe3bcc --- /dev/null +++ b/debian/beaver.upstart @@ -0,0 +1,8 @@ +description "Beaver" + +start on runlevel [2345] +stop on runlevel [!2345] + +respawn + +exec /usr/bin/beaver -c /etc/beaver.conf diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000..da4e750 --- /dev/null +++ b/debian/changelog @@ -0,0 +1,24 @@ +beaver (30-1) precise; urgency=high + + * New upstream release + + -- Kiall Mac Innes Fri, 27 Sep 2013 12:17:34 +0100 + +beaver (28-3) precise; urgency=low + + * Include /var/log/syslog in the sample config file + + -- Kiall Mac Innes Mon, 01 Apr 2013 21:14:27 +0100 + +beaver (28-2) precise; urgency=low + + * Update sample config file + * Fixup upstart script + + -- Kiall Mac Innes Mon, 01 Apr 2013 20:31:26 +0100 + +beaver (28-1) precise; urgency=low + + * Initial Packaging + + -- Kiall Mac Innes Mon, 01 Apr 2013 19:10:32 +0100 diff --git a/debian/compat b/debian/compat new file mode 100644 index 0000000..45a4fb7 --- /dev/null +++ b/debian/compat @@ -0,0 +1 @@ +8 diff --git a/debian/control b/debian/control new file mode 100644 index 0000000..26ee07c --- /dev/null +++ b/debian/control @@ -0,0 +1,40 @@ +Source: beaver +Section: python +Priority: extra +Maintainer: Kiall Mac Innes +Build-Depends: + debhelper (>= 8.0.0), + python | python-all | python-dev | python-all-dev +Build-Depends-Indep: + python-setuptools +Standards-Version: 3.9.4 +Homepage: https://github.com/josegonzalez/beaver + +Package: beaver +Architecture: all +Depends: + python-beaver (= ${binary:Version}), + ${misc:Depends} +Description: Beaver + Beaver is a python daemon that munches on logs and sends their contents + to logstash + +Package: python-beaver +Architecture: all +Depends: + python | python-all, + python-simplejson, + python-daemon, + python-glob2, + python-argparse, + python-conf-d, + ${misc:Depends} +Suggests: + python-pika, + python-redis, + python-zmq +Provides: + ${python:Provides} +Description: Beaver Python Libraries + Beaver is a python daemon that munches on logs and sends their contents + to logstash diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 0000000..653f32b --- /dev/null +++ b/debian/copyright @@ -0,0 +1,40 @@ +Format: http://dep.debian.net/deps/dep5 +Upstream-Name: beaver +Source: https://github.com/josegonzalez/beaver + +Files: * +Copyright: (c) 2012-2013 Jose Diaz-Gonzalez +License: MIT + Permission is hereby granted, free of charge, to any person obtaining + a copy of this software and associated documentation files (the + "Software"), to deal in the Software without restriction, including + without limitation the rights to use, copy, modify, merge, publish, + distribute, sublicense, and/or sell copies of the Software, and to + permit persons to whom the Software is furnished to do so, subject to + the following conditions: + . + The above copyright notice and this permission notice shall be + included in all copies or substantial portions of the Software. + . + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE + LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION + OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION + WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +Files: debian/* +Copyright: (c) 2013 Hewlett-Packard Development Company, L.P. +License: Apache 2.0 + Licensed under the Apache License, Version 2.0 (the "License"); you may + not use this file except in compliance with the License. You may obtain + a copy of the License at + . + http://www.apache.org/licenses/LICENSE-2.0 + . + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + License for the specific language governing permissions and limitations + under the License. diff --git a/debian/gbp.conf b/debian/gbp.conf new file mode 100644 index 0000000..620dfe9 --- /dev/null +++ b/debian/gbp.conf @@ -0,0 +1,3 @@ +[DEFAULT] +pristine-tar = false +export-dir = ../build-area/ diff --git a/debian/pydist-overrides b/debian/pydist-overrides new file mode 100644 index 0000000..e69de29 diff --git a/debian/python-beaver.install b/debian/python-beaver.install new file mode 100644 index 0000000..036c6b9 --- /dev/null +++ b/debian/python-beaver.install @@ -0,0 +1 @@ +usr/lib/python*/dist-packages/* diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..607c494 --- /dev/null +++ b/debian/rules @@ -0,0 +1,21 @@ +#!/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. +# +# Modified to make a template file for a multi-binary package with separated +# build-arch and build-indep targets by Bill Allombert 2001 + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +# This has to be exported to make some magic below work. +export DH_OPTIONS + + +%: + dh $@ --with python2 diff --git a/debian/source/format b/debian/source/format new file mode 100644 index 0000000..163aaf8 --- /dev/null +++ b/debian/source/format @@ -0,0 +1 @@ +3.0 (quilt) diff --git a/debian/watch b/debian/watch new file mode 100644 index 0000000..d318d10 --- /dev/null +++ b/debian/watch @@ -0,0 +1,2 @@ +version=3 +https://pypi.python.org/packages/source/B/Beaver/Beaver-(.*)\.tar\.gz \ No newline at end of file