neraath

Member
May 25, 2004
15
0
151
Aggieland, TX
What's the proper format of putting files in /etc/cpanelsync.exclude so that when /scripts/updatenow is processed, scripts that I have modified don't get overwritten?

Basically I'm running FreeBSD 4.11, but using RELEASE to get the RELEASE branch of cPanel and any packages therein. However, when the installport.pl file gets updated, anytime a new port tries to get downloaded, it's looking in the wrong location on the mirrors.

Here's a snippet of the script, unmodified:
Code:
    my $pkgdir = "packages-${release}-release";
    my $fallbackpkgdir = "packages-${majorrelease}-stable";

    my ($ver,$bsdver);
    (undef,$ver,undef) = split(/-/, $pkgdir);
    ($bsdver,undef) = split(/\./, $ver);

    #when using stable
    #$pkgdir = "packages-${bsdver}-stable";
Basically, 4.11 is no longer considered release for FreeBSD, as the 5 and 6 branches still have their release branches. So, when FreeBSD is trying to update, it's looking for the folder packages-4.11-release in the ports subfolder, which doesn't exist on any mirrors anymore. Only 'packages-4-stable' does. I would think the $fallbackpkgdir variable should fix that problem, but when I watch the output from /scripts/upcp, it never attempts that after attempting $pkgdir. Here's what I'm trying to change to:

Code:
    my $pkgdir = "packages-${release}-release";
    my $fallbackpkgdir = "packages-${majorrelease}-stable";

    my ($ver,$bsdver);
    (undef,$ver,undef) = split(/-/, $pkgdir);
    ($bsdver,undef) = split(/\./, $ver);

    #when using stable
    $pkgdir = "packages-${bsdver}-stable";
This way, $pkgdir is reset to the appropriate value and will download updates appropriately. Nevertheless, it gets overwritten during the updates, no matter what I try to put in the /etc/cpanelsync.excludes file.

Thanks in advance!