]> git.proxmox.com Git - pve-installer.git/commitdiff
use files from ../pve-cd-builder for testing
authorDietmar Maurer <dietmar@proxmox.com>
Mon, 20 Nov 2017 09:28:22 +0000 (10:28 +0100)
committerDietmar Maurer <dietmar@proxmox.com>
Mon, 20 Nov 2017 09:28:22 +0000 (10:28 +0100)
Makefile
proxinstall

index 0ab6eeb026f757f827de138970d9134426b58b1d..4045ac4192834908b09d66b112a2af36b743eaa3 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -49,16 +49,13 @@ install: ${INSTALLER_SOURCES} ${HTML_COMMON_SOURCES} ${HTML_SOURCES}
 upload: ${DEB}
        tar cf - ${DEB} | ssh repoman@repo.proxmox.com -- upload --product pve --dist stretch
 
-packages: /pve/${RELEASE}/install/pve.files
-       rm -rf packages packages.tmp; mkdir packages.tmp
-       for i in `cat $<`; do install -m 644 $$i  packages.tmp/; done
-       mv packages.tmp packages
-
 test.img:
        dd if=/dev/zero of=test.img bs=2048 count=1M
 
-check: packages test.img
-       G_SLICE=always-malloc ./proxinstall -t test.img
+check: ${DEB} test.img
+       rm -rf testdir
+       dpkg -X ${DEB} testdir
+       G_SLICE=always-malloc perl -I testdir/usr/share/perl5 testdir/usr/bin/proxinstall -t test.img
 
 .phony: clean
 clean:
index 785ddfc479b506bf1f9414354c1718416a5235b3..814721254540933e205a96bfab2e3e6650fe79fd 100755 (executable)
@@ -1265,9 +1265,9 @@ sub extract_data {
 
        my $files;
        if ($opt_testmode) {
-           $files = file_read_firstline("/pve/$release/install/pve-base.cnt");
+           $files = file_read_firstline("../pve-cd-builder/base.cnt");
        } else {
-           $files = file_read_firstline("/cdrom/proxmox/pve-base.cnt");
+           $files = file_read_firstline("/cdrom/proxmox/$setup->{product}-base.cnt");
        }
 
        my $per = 0;
@@ -1431,7 +1431,7 @@ d-i debian-installer/locale select en_US.UTF-8
 grub-pc grub-pc/install_devices select $grub_install_devices_txt
 _EOD
 
-       my $pkgdir = $opt_testmode ? "packages" : "/cdrom/proxmox/packages";
+        my $pkgdir = $opt_testmode ? "../pve-cd-builder/tmp/data-gz/proxmox/packages/" : "/cdrom/proxmox/packages";
        my $pkg_count = 0;
        while (<$pkgdir/*.deb>) { $pkg_count++ };
 
@@ -2958,7 +2958,7 @@ sub create_extract_view {
 
     my $tdir = $opt_testmode ? "target" : "/target";
     mkdir $tdir;
-    my $base = $opt_testmode ? "/pve/$release/install/pve-base.squashfs" : "/cdrom/pve-base.squashfs";
+    my $base = $opt_testmode ? "../pve-cd-builder/base.squashfs" : "/cdrom/$setup->{product}-base.squashfs";
 
     eval  { extract_data ($base, $tdir); };
     my $err = $@;