summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLukc <lukc@upyum.com>2010-12-12 04:42:57 +0100
committerLukc <lukc@upyum.com>2010-12-12 04:42:57 +0100
commit71e521c65d470f82051c5d39f7f298c3103c2c18 (patch)
treeae0cd3a2b590738e1fd706ecdd51171808d3fe29
parent8549ec3c24835c9951dd0b4becae692799460446 (diff)
downloadbase-71e521c65d470f82051c5d39f7f298c3103c2c18.tar.gz
base-71e521c65d470f82051c5d39f7f298c3103c2c18.tar.bz2
base-71e521c65d470f82051c5d39f7f298c3103c2c18.tar.xz
base-71e521c65d470f82051c5d39f7f298c3103c2c18.zip
Recette de rsync retirée.
-rw-r--r--rsync/.footprint18
-rw-r--r--rsync/.md5sum4
-rw-r--r--rsync/Pkgfile22
-rw-r--r--rsync/Pkgfile.old28
-rw-r--r--rsync/rsync.driver143
-rw-r--r--rsync/rsyncd23
-rw-r--r--rsync/rsyncd.conf15
7 files changed, 0 insertions, 253 deletions
diff --git a/rsync/.footprint b/rsync/.footprint
deleted file mode 100644
index dbb4683..0000000
--- a/rsync/.footprint
+++ /dev/null
@@ -1,18 +0,0 @@
-drwxr-xr-x root/root etc/
-drwxr-xr-x root/root etc/ports/
-drwxr-xr-x root/root etc/ports/drivers/
--rwxr-xr-x root/root etc/ports/drivers/rsync
-drwxr-xr-x root/root etc/rc.d/
--rwxr-xr-x root/root etc/rc.d/rsyncd
--rw-r--r-- root/root etc/rsyncd.conf
-drwxr-xr-x root/root usr/
-drwxr-xr-x root/root usr/bin/
--rwxr-xr-x root/root usr/bin/rsync
-drwxr-xr-x root/root usr/man/
-drwxr-xr-x root/root usr/man/man1/
--rw-r--r-- root/root usr/man/man1/rsync.1.gz
-drwxr-xr-x root/root usr/man/man5/
--rw-r--r-- root/root usr/man/man5/rsyncd.conf.5.gz
-drwxr-xr-x root/root var/
-drwxr-xr-x root/root var/log/
--rw-r--r-- root/root var/log/rsyncd.log (EMPTY)
diff --git a/rsync/.md5sum b/rsync/.md5sum
deleted file mode 100644
index 25d5822..0000000
--- a/rsync/.md5sum
+++ /dev/null
@@ -1,4 +0,0 @@
-b53525900817cf1ba7ad3a516ab5bfe9 rsync-3.0.7.tar.gz
-f8dcfe5cf2afef1ea90107a6ff4540cd rsync.driver
-a71995f22768c931c5649a1336d25ffb rsyncd
-b4e95fa8c8f3ae13cfdf616abd6a3960 rsyncd.conf
diff --git a/rsync/Pkgfile b/rsync/Pkgfile
deleted file mode 100644
index 1272713..0000000
--- a/rsync/Pkgfile
+++ /dev/null
@@ -1,22 +0,0 @@
-description="Utility for incremental file transfers over networks"
-packager=""
-maintainer="CRUX System Team, core-ports at crux dot nu"
-url="http://rsync.samba.org"
-depends=(openssh acl)
-
-name=rsync
-version=3.0.7
-release=1
-source=(http://rsync.samba.org/ftp/rsync/src/rsync-3.0.7.tar.gz rsyncd.conf rsyncd rsync.driver)
-build ()
-{
- cd $name-$version;
- ./configure --prefix=/usr --mandir=/usr/man --with-rsh=ssh --with-included-popt;
- make;
- make DESTDIR=$PKG install;
- install -d $PKG/etc/{rc.d,ports/drivers} $PKG/var/log;
- install -m 755 $SRC/rsyncd $PKG/etc/rc.d;
- install -m 644 $SRC/rsyncd.conf $PKG/etc;
- install -m 755 $SRC/rsync.driver $PKG/etc/ports/drivers/rsync;
- touch $PKG/var/log/rsyncd.log
-}
diff --git a/rsync/Pkgfile.old b/rsync/Pkgfile.old
deleted file mode 100644
index 6435b97..0000000
--- a/rsync/Pkgfile.old
+++ /dev/null
@@ -1,28 +0,0 @@
-# Description: Utility for incremental file transfers over networks
-# URL: http://rsync.samba.org
-# Maintainer: CRUX System Team, core-ports at crux dot nu
-# Depends on: openssh acl
-
-name=rsync
-version=3.0.7
-release=1
-source=(http://rsync.samba.org/ftp/$name/src/$name-$version.tar.gz \
- rsyncd.conf rsyncd rsync.driver)
-
-build () {
- cd $name-$version
-
- ./configure --prefix=/usr \
- --mandir=/usr/man \
- --with-rsh=ssh \
- --with-included-popt
-
- make
- make DESTDIR=$PKG install
-
- install -d $PKG/etc/{rc.d,ports/drivers} $PKG/var/log
- install -m 755 $SRC/rsyncd $PKG/etc/rc.d
- install -m 644 $SRC/rsyncd.conf $PKG/etc
- install -m 755 $SRC/rsync.driver $PKG/etc/ports/drivers/rsync
- touch $PKG/var/log/rsyncd.log
-}
diff --git a/rsync/rsync.driver b/rsync/rsync.driver
deleted file mode 100644
index 31bb14a..0000000
--- a/rsync/rsync.driver
+++ /dev/null
@@ -1,143 +0,0 @@
-#!/usr/bin/perl
-#
-# /etc/ports/drivers/rsync: rsync(1) driver script for ports(8)
-#
-
-use warnings;
-use strict;
-use File::Basename;
-
-my $host = '';
-my $collection = '';
-my $destination = '';
-my %new_checkouts;
-my %old_checkouts;
-
-sub error
-{
- my $message = shift;
- print "Error: $message ($!)\nUpdating failed\n";
- exit 1;
-}
-
-sub warning
-{
- my $message = shift;
- print "Warning: $message ($!)\n";
-}
-
-if ($#ARGV < 0)
-{
- print "Usage: $0 <file>\n";
- exit 1;
-}
-
-open(FILE, $ARGV[0]) or error("Couldn't open $ARGV[0]");
-while (<FILE>)
-{
- chomp;
- if (/^host=(.*)/) { $host = $1; }
- elsif (/^collection=(.*)/) { $collection = $1; }
- elsif (/^destination=(.*)/) { $destination = $1; }
-}
-close(FILE);
-
-if ($host eq '') { error("Host field not set in $ARGV[0]"); }
-if ($collection eq '') { error("Collection field not set in $ARGV[0]"); }
-if ($destination eq '') { error("Destination field not set in $ARGV[0]"); }
-
-if (-e "$destination/.checkouts")
-{
- # read the old .checkouts file into memory
- open(FILE, "$destination/.checkouts") or error("Couldn't read checkouts from $destination/.checkouts");
- while (<FILE>)
- {
- chomp;
- $old_checkouts{$_} = 1;
- }
- close(FILE);
-}
-
-print "Updating file list from " . $host . "::$collection\n";
-
-# get the remote file list (new .checkouts)
-open(PIPE, 'rsync -crz ' . $host . '::' . $collection . '|') or error("Couldn't open pipe to rsync");
-while (<PIPE>)
-{
- chomp;
-
- next if /^MOTD:/; # ignore MOTD lines
- s/^(.{43})//; # ignore the first 43 characters (mode, date etc...)
- next if /^.$/; # ignore the . directory
-
- $new_checkouts{$_} = 1;
-}
-close(PIPE);
-error("Running rsync failed") unless $? == 0;
-
-print "Updating collection " . basename($destination) . "\n";
-
-# now really run rsync
-open(PIPE, 'rsync -crz --log-format "%o %n" ' . $host . "::$collection $destination|") or error("Couldn't open pipe to rsync");
-while (<PIPE>)
-{
- chomp;
-
- if (/^recv (.*)/)
- {
- if ($old_checkouts{$1})
- {
- s/^recv/ Edit/;
- }
- else
- {
- s/^recv/ Checkout/;
- }
- }
-
- print $_ . "\n";
-}
-close(PIPE);
-error("Running rsync failed") unless $? == 0;
-
-# save new checkouts into .checkouts
-open(FILE, ">$destination/.checkouts") or error("Couldn't save checkouts to $destination/.checkouts");
-foreach my $checkout (sort keys %new_checkouts)
-{
- print FILE "$checkout\n";
-}
-close(FILE);
-
-# use chroot as an additional safety measure when removing files
-chroot($destination) or error("Couldn't chroot into $destination");
-chdir('/');
-
-# iterate through old checkouts, remove obsolete files
-foreach my $checkout (sort keys %old_checkouts)
-{
- if (!$new_checkouts{$checkout})
- {
- if (-f $checkout)
- {
- print " Delete $checkout\n";
- unlink($checkout) or warning("Couldn't delete $checkout");
- }
- }
-}
-
-# iterate through old checkouts, remove obsolete directories
-foreach my $checkout (sort keys %old_checkouts)
-{
- if (!$new_checkouts{$checkout})
- {
- if (-d $checkout)
- {
- print " Delete $checkout\n";
- rmdir($checkout) or warning("Couldn't delete $checkout");
- }
- }
-}
-
-print "Finished successfully\n";
-
-# End of file
diff --git a/rsync/rsyncd b/rsync/rsyncd
deleted file mode 100644
index 8507211..0000000
--- a/rsync/rsyncd
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/bin/sh
-#
-# /etc/rc.d/rsyncd: start/stop rsyncd daemon
-#
-
-case $1 in
-start)
- /usr/bin/rsync --daemon
- ;;
-stop)
- kill `cat /var/run/rsyncd.pid`
- ;;
-restart)
- $0 stop
- sleep 2
- $0 start
- ;;
-*)
- echo "usage: $0 [start|stop|restart]"
- ;;
-esac
-
-# End of file
diff --git a/rsync/rsyncd.conf b/rsync/rsyncd.conf
deleted file mode 100644
index 02bbdc6..0000000
--- a/rsync/rsyncd.conf
+++ /dev/null
@@ -1,15 +0,0 @@
-#
-# /etc/rsyncd.conf
-#
-
-pid file = /var/run/rsyncd.pid
-log file = /var/log/rsyncd.log
-
-[test]
- path = /tmp
- comment = test share for rsyncd
- hosts allow = 192.168.0.0/24
- read only = true
- use chroot = true
-
-# End of file