download aplinfo inh postinst script

This commit is contained in:
Dietmar Maurer 2012-02-21 12:15:10 +01:00
parent c452ded323
commit 75a6a7f545
2 changed files with 7 additions and 7 deletions

View File

@ -291,13 +291,7 @@ sub update {
sub load_data {
my $filename = "$aplinfodir/download.proxmox.com";
if (! -f $filename) {
mkdir $aplinfodir;
system("cp /usr/share/doc/pve-manager/aplinfo.dat $filename");
}
my $urls = get_apl_sources();
my $urls = get_apl_sources();
my $list = {};

6
debian/postinst vendored
View File

@ -40,6 +40,12 @@ case "$1" in
# remove old APL dir
rm -rf /var/lib/pve-manager/apl-available
if test ! -e /var/lib/pve-manager/apl-info/download.proxmox.com; then
mkdir -p /var/lib/pve-manager/apl-info
cp /usr/share/doc/pve-manager/aplinfo.dat /var/lib/pve-manager/apl-info/download.proxmox.com
pveam update || true
fi
if test -f /root/.forward; then
if ! grep -q '|/usr/bin/pvemailforward' /root/.forward; then
echo -e "|/usr/bin/pvemailforward\n$(cat /root/.forward)" >/root/.forward.tmp