[Pkg-ganeti-devel] [PATCH] ganeti-instance-debian-etch initial packaging

Iustin Pop iusty at k1024.org
Tue Feb 19 20:46:13 UTC 2008


Hi all,

Finally (based on Henning & Guido's mails on ganeti at googlegroups.com), I
completed the work on the debian-etch instance.

Here is the patch, with the following notes:
  - it patches upstream to use cache files in
    /var/cache/ganeti-instance-debian-etch, instead of using cache files
    near the other scripts (which is /usr/share/ganeti/os/debian-etch),
    which would not be nice
  - the svn commit will also delete the no-longer needed
    instance-debian-etch from trunk

Otherwise, things look good. I did some testing with the current
unstable ganeti package and it works (uml nodes, fake hypervisor, but
the install and cache creation are ok).


Property changes on: ganeti-instance-debian-etch/debian
___________________________________________________________________
Name: mergeWithUpstream
   + 1

Index: ganeti-instance-debian-etch/debian/control
===================================================================
--- ganeti-instance-debian-etch/debian/control	(revision 0)
+++ ganeti-instance-debian-etch/debian/control	(revision 0)
@@ -0,0 +1,20 @@
+Source: ganeti-instance-debian-etch
+Section: admin
+Priority: extra
+Maintainer: Debian Ganeti Team <pkg-ganeti-devel at lists.alioth.debian.org>
+Uploaders: Guido Trotter <ultrotter at debian.org>, Iustin Pop <iusty at k1024.org>, Leonardo Rodrigues de Mello <l at lmello.eu.org>
+Build-Depends: cdbs, debhelper (>= 5)
+Standards-Version: 3.7.3
+
+Package: ganeti-instance-debian-etch
+Architecture: all
+Depends: ${misc:Depends}, debootstrap, dump
+Enhances: ganeti
+Description: etch instance OS definition for ganeti
+ Ganeti is a virtual server cluster management software tool built on top
+ of the Xen virtual machine monitor and other Open Source software. After
+ setting it up it will provide you with an automated environment to
+ manage highly available virtual machine instances.
+ .
+ This package provides an OS definition for ganeti that will allow
+ installation of Debin Etch instances via debootstrap.
Index: ganeti-instance-debian-etch/debian/compat
===================================================================
--- ganeti-instance-debian-etch/debian/compat	(revision 0)
+++ ganeti-instance-debian-etch/debian/compat	(revision 0)
@@ -0,0 +1 @@
+5
Index: ganeti-instance-debian-etch/debian/changelog
===================================================================
--- ganeti-instance-debian-etch/debian/changelog	(revision 0)
+++ ganeti-instance-debian-etch/debian/changelog	(revision 0)
@@ -0,0 +1,5 @@
+ganeti-instance-debian-etch (0.4-1) unstable; urgency=low
+
+  * Initial release. (Closes: #466583)
+
+ -- Iustin Pop <iusty at k1024.org>  Tue, 19 Feb 2008 20:19:22 +0100
Index: ganeti-instance-debian-etch/debian/patches/cache_in_var_cache.patch
===================================================================
--- ganeti-instance-debian-etch/debian/patches/cache_in_var_cache.patch	(revision 0)
+++ ganeti-instance-debian-etch/debian/patches/cache_in_var_cache.patch	(revision 0)
@@ -0,0 +1,26 @@
+diff -urN ganeti-instance-debian-etch-0.4.orig/create ganeti-instance-debian-etch-0.4/create
+--- ganeti-instance-debian-etch-0.4.orig/create	2007-11-28 08:48:24.000000000 +0100
++++ ganeti-instance-debian-etch-0.4/create	2008-02-19 20:27:05.335127422 +0100
+@@ -23,7 +23,9 @@
+ # node's sources.list
+ MIRROR="http://ftp.debian.org/debian"
+ DPKG_ARCH="`dpkg --print-architecture`"
+-CACHE_FILE="cache-${DPKG_ARCH}.tar"
++CACHE_DIR="/var/cache/ganeti-instance-debian-etch"
++CACHE_FILE="$CACHE_DIR/cache-${DPKG_ARCH}.tar"
++NOCACHE_FILE="$CACHE_DIR/no-cache"
+ 
+ TEMP=`getopt -o i:b:s: -n '$0' -- "$@"`
+ 
+@@ -80,7 +82,10 @@
+ 
+ 	rm -f "$TMPDIR/etc/udev/rules.d/z25_persistent-net.rules"
+ 
+-	if [ ! -e no_cache ]; then
++	if [ ! -e "$NOCACHE_FILE" ]; then
++		if [ ! -d "$CACHE_DIR" ]; then
++			mkdir -p "$CACHE_DIR"
++		fi
+ 		TMP_CACHE=`mktemp "${CACHE_FILE}.XXXXXX"`
+ 		tar cf "$TMP_CACHE" -C $TMPDIR .
+ 		mv "$TMP_CACHE" "$CACHE_FILE"
Index: ganeti-instance-debian-etch/debian/copyright
===================================================================
--- ganeti-instance-debian-etch/debian/copyright	(revision 0)
+++ ganeti-instance-debian-etch/debian/copyright	(revision 0)
@@ -0,0 +1,29 @@
+This package was debianized by Iustin Pop <iusty at k1024.org> on
+Tue, 19 Feb 2008 19:53:48 +0100.
+
+It was then taken over for official Debian maintenance by the Debian Ganeti Team.
+
+It was downloaded from http://code.google.com/p/ganeti/
+
+Upstream Author:	iustinp, ultrotter, schreiberal, amishchenko, roman.marxer, imsnah, vylavera
+
+Copyright:  Copyright (C) 2006, 2007 Google Inc.
+
+License: GPL
+This  program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+ This program is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ 02110-1301, USA.
+
+The Debian packaging is (C) 2007, Debian Ganeti Team
+<pkg-ganeti at lists.alioth.debian.org> and is licensed under the GPL, see
+`/usr/share/common-licenses/GPL'.
Index: ganeti-instance-debian-etch/debian/docs
===================================================================
--- ganeti-instance-debian-etch/debian/docs	(revision 0)
+++ ganeti-instance-debian-etch/debian/docs	(revision 0)
@@ -0,0 +1,2 @@
+README
+NEWS
Index: ganeti-instance-debian-etch/debian/rules
===================================================================
--- ganeti-instance-debian-etch/debian/rules	(revision 0)
+++ ganeti-instance-debian-etch/debian/rules	(revision 0)
@@ -0,0 +1,13 @@
+#!/usr/bin/make -f
+include /usr/share/cdbs/1/rules/debhelper.mk
+include /usr/share/cdbs/1/rules/simple-patchsys.mk
+
+# Add here any variable or target overrides you need.
+
+binary-install/ganeti-instance-debian-etch::
+	install -d --mode 0755 $(CURDIR)/debian/ganeti-instance-debian-etch/usr/share/ganeti/os/debian-etch
+	install --mode 0755 $(CURDIR)/create $(CURDIR)/debian/ganeti-instance-debian-etch/usr/share/ganeti/os/debian-etch/create
+	install --mode 0755 $(CURDIR)/export $(CURDIR)/debian/ganeti-instance-debian-etch/usr/share/ganeti/os/debian-etch/export
+	install --mode 0755 $(CURDIR)/import $(CURDIR)/debian/ganeti-instance-debian-etch/usr/share/ganeti/os/debian-etch/import
+	install --mode 0755 $(CURDIR)/rename $(CURDIR)/debian/ganeti-instance-debian-etch/usr/share/ganeti/os/debian-etch/rename
+	install --mode 0644 $(CURDIR)/ganeti_api_version $(CURDIR)/debian/ganeti-instance-debian-etch/usr/share/ganeti/os/debian-etch/ganeti_api_version

Property changes on: ganeti-instance-debian-etch/debian/rules
___________________________________________________________________
Name: svn:executable
   + *

Index: ganeti-instance-debian-etch/debian/ganeti-instance-debian-etch.dirs
===================================================================
--- ganeti-instance-debian-etch/debian/ganeti-instance-debian-etch.dirs	(revision 0)
+++ ganeti-instance-debian-etch/debian/ganeti-instance-debian-etch.dirs	(revision 0)
@@ -0,0 +1 @@
+var/cache/ganeti-instance-debian-etch
Index: ganeti-instance-debian-etch/debian/README.Debian
===================================================================
--- ganeti-instance-debian-etch/debian/README.Debian	(revision 0)
+++ ganeti-instance-debian-etch/debian/README.Debian	(revision 0)
@@ -0,0 +1,6 @@
+The debian version of this package differs from upstream in the fact
+that the cache is not stored together with the OS scripts (under
+/usr/share/ganeti/os/debian-etch), but under
+/var/cache/ganeti-instance-debian-etch.
+
+The no-cache file also should be manually added under that directory.



More information about the Pkg-ganeti-devel mailing list