Commit aea579ce authored by Mark Schouten's avatar Mark Schouten
Browse files

Try to build debian packages

parent 60f720c5
PREFIX=$(CURDIR)/debian/
install: ypconfig
ypconfig: PKGNAME := ypconfig
ypconfig: PKGPREFIX := $(PREFIX)/$(PKGNAME)
ypconfig: SDIR := ypconfig
ypconfig:
python setup.py install --force --root=$(PKGPREFIX) --no-compile -O0 --install-layout=deb
mkdir -p $(PKGPREFIX)/etc/ypconfig/
mkdir -p $(PKGPREFIX)/usr/sbin/
mkdir -p $(PKGPREFIX)/usr/lib/ypconfig/
install -m 750 ./ypconfig $(PKGPREFIX)/usr/sbin/
install -m 755 ./playground/snmp-helper.py $(PKGPREFIX)/usr/lib/ypconfig
clean:
rm -rf $(PREFIX)/ypconfig
ypconfig (0.1) unstable; urgency=low
- Initial version.
-- Mark Schouten <mark@tuxis.nl> Thu, 23 Mar 2017 13:00:25 +0200
Source: ypconfig
Section: misc
Priority: extra
Maintainer: Mark Schouten <mark@tuxis.nl>
Build-Depends: debhelper (>= 5), python3
Standards-Version: 3.9.1
Package: ypconfig
Architecture: all
Pre-Depends: python-support python3-pip
Description: ypconfig, talk to Netlink from Python
ypconfig is able to configure your servers network interfaces from a Yaml file, and rollback if something goes wrong.
#!/usr/bin/make -f
#export DH_VERBOSE=1
%:
dh $@
#!/bin/sh
#
# see: dh_installdeb(1)
set -e
# summary of how this script can be called:
# * <postinst> `configure' <most-recently-configured-version>
# * <old-postinst> `abort-upgrade' <new version>
# * <conflictor's-postinst> `abort-remove' `in-favour' <package>
# <new-version>
# * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
# <failed-install-package> <version> `removing'
# <conflicting-package> <version>
# for details, see http://www.debian.org/doc/debian-policy/ or
# the debian-policy package
#
case "$1" in
configure)
# Install required pip packages
pip3 -r /etc/ypconfig/requirements.txt
;;
abort-upgrade|abort-remove|abort-deconfigure)
;;
*)
echo "postinst called with unknown argument \`$1'" >&2
exit 1
;;
esac
# dh_installdeb will replace this with shell code automatically
# generated by other debhelper scripts.
#DEBHELPER#
exit 0
#!/usr/bin/env python
from distutils.core import setup
setup(
name='ypconfig',
version='1.0',
description='Tools required for ypconfig',
author='Mark Schouten',
author_email='mark@tuxis.nl',
url='https://gitlab.tuxis.nl/mark/ypconfig',
license='Closed',
py_modules=['ypconfig.Config', 'ypconfig.Netlink'],
package_dir={'': 'lib'},
platforms=['linux'],
data_files=[
]
)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment