From 1b3e6129f7b2f2aab91713049de2ecbc6c360fd2 Mon Sep 17 00:00:00 2001 From: Matthew Budd Date: Sat, 27 Oct 2018 00:30:46 +0100 Subject: system/rear: Added (disaster recovery and system migration tool). Signed-off-by: David Spencer --- system/rear/README | 10 +++++++ system/rear/rear.SlackBuild | 73 +++++++++++++++++++++++++++++++++++++++++++++ system/rear/rear.info | 10 +++++++ system/rear/rear.patch | 14 +++++++++ system/rear/slack-desc | 19 ++++++++++++ 5 files changed, 126 insertions(+) create mode 100644 system/rear/README create mode 100644 system/rear/rear.SlackBuild create mode 100644 system/rear/rear.info create mode 100644 system/rear/rear.patch create mode 100644 system/rear/slack-desc (limited to 'system/rear') diff --git a/system/rear/README b/system/rear/README new file mode 100644 index 000000000000..9aece9cde1ef --- /dev/null +++ b/system/rear/README @@ -0,0 +1,10 @@ +rear (bare metal disaster recovery and system migration tool) + +Relax-and-Recover is the leading Open Source bare metal disaster recovery +and system migration solution. It is a modular framework with many +ready-to-go workflows for common situations. + +Relax-and-Recover produces a bootable image. This image can repartition the +system. Once that is done it initiates a restore from backup. Restores to +different hardware are possible. Relax-and-Recover can therefore be used as a +migration tool as well. diff --git a/system/rear/rear.SlackBuild b/system/rear/rear.SlackBuild new file mode 100644 index 000000000000..4d12cf0835de --- /dev/null +++ b/system/rear/rear.SlackBuild @@ -0,0 +1,73 @@ +#!/bin/sh + +# Slackware build script for rear + +# Copyright 2018 Matthew Budd Tampa, FL USA +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +PRGNAM=rear +VERSION=${VERSION:-2.4} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +ARCH=noarch + +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf $PRGNAM-$VERSION +tar xvf $CWD/$PRGNAM-$VERSION.tar.gz +cd $PRGNAM-$VERSION +chown -R root:root . +find -L . \ + \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ + -o -perm 511 \) -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ + -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; + +# Apply simple patch to make rear recognize a slackware OS +patch -p0 < $CWD/rear.patch + +make install DESTDIR=$PKG + +make -C doc/user-guide &> /dev/null + +mv $PKG/usr/share/man $PKG/usr/man +find $PKG/usr/man -type f -exec gzip -9 {} \; +for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a \ + doc/user-guide/*.adoc doc/user-guide/*.html \ + $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc + +cd $PKG +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz} diff --git a/system/rear/rear.info b/system/rear/rear.info new file mode 100644 index 000000000000..2b42fc06ad83 --- /dev/null +++ b/system/rear/rear.info @@ -0,0 +1,10 @@ +PRGNAM="rear" +VERSION="2.4" +HOMEPAGE="http://relax-and-recover.org" +DOWNLOAD="https://sourceforge.net/projects/rear/files/rear/2.4/rear-2.4.tar.gz" +MD5SUM="fe176b2600eda63ffec9d950a6943cb9" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" +REQUIRES="" +MAINTAINER="Matthew Budd" +EMAIL="mjbudd77@yahoo.com" diff --git a/system/rear/rear.patch b/system/rear/rear.patch new file mode 100644 index 000000000000..aa8cb2fbce4a --- /dev/null +++ b/system/rear/rear.patch @@ -0,0 +1,14 @@ +--- ./usr/share/rear/lib/config-functions.sh.orig 2018-10-25 22:23:17.744613686 -0400 ++++ ./usr/share/rear/lib/config-functions.sh 2018-10-25 22:23:26.675613303 -0400 +@@ -57,6 +57,11 @@ + minornr=$( grep -o -E '[0-9]+' /etc/system-release | head -2 | tail -1 ) + OS_VERSION="$majornr.$minornr" + fi ++ ++ if [[ -f /etc/slackware-version ]] ; then ++ OS_VENDOR=Slackware ++ OS_VERSION=$(cat /etc/slackware-version | sed -r -e 's/slackware\s*//i') ++ fi + fi + + # If OS_VENDOR is still generic then use as last resource 'lsb_release' to find out diff --git a/system/rear/slack-desc b/system/rear/slack-desc new file mode 100644 index 000000000000..f546a0d1e6e0 --- /dev/null +++ b/system/rear/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. +# Line up the first '|' above the ':' following the base package name, and +# the '|' on the right side marks the last column you can put a character in. +# You must make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':' except on otherwise blank lines. + + |-----handy-ruler------------------------------------------------------| +rear: rear (bare metal disaster recovery and system migration tool) +rear: +rear: Relax-and-Recover is a Open Source, setup-and-forget, Linux bare +rear: metal disaster recovery solution. It utilizes a modular framework +rear: with many ready-to-go workflows for common situations. +rear: +rear: +rear: +rear: +rear: +rear: -- cgit v1.2.3