diff options
author | rhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58> | 2007-02-11 14:29:54 +0000 |
---|---|---|
committer | rhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58> | 2007-02-11 14:29:54 +0000 |
commit | f9a8dfcd51e481a49355d94a3e74f2762519378f (patch) | |
tree | 948f0382081bd2eb8b1b5458a9661b67a090e795 /templates/vserver-legacy/vserver-legacy.s/vserver-legacy.sh | |
parent | fef31cbc9988ead081aaec587222b44ed524b6fd (diff) | |
download | simplepkg-f9a8dfcd51e481a49355d94a3e74f2762519378f.tar.gz simplepkg-f9a8dfcd51e481a49355d94a3e74f2762519378f.tar.bz2 |
changed repository layout to trunk/, tags/ and branches/ scheme
git-svn-id: svn+slack://slack.fluxo.info/var/svn/simplepkg@181 04377dda-e619-0410-9926-eae83683ac58
Diffstat (limited to 'templates/vserver-legacy/vserver-legacy.s/vserver-legacy.sh')
-rw-r--r-- | templates/vserver-legacy/vserver-legacy.s/vserver-legacy.sh | 49 |
1 files changed, 0 insertions, 49 deletions
diff --git a/templates/vserver-legacy/vserver-legacy.s/vserver-legacy.sh b/templates/vserver-legacy/vserver-legacy.s/vserver-legacy.sh deleted file mode 100644 index 4ce8a4b..0000000 --- a/templates/vserver-legacy/vserver-legacy.s/vserver-legacy.sh +++ /dev/null @@ -1,49 +0,0 @@ -#!/bin/bash -# -# legacy vserver template -# - -BASE="/etc/simplepkg/templates/vserver-legacy/vserver-legacy.s/" -DEVICES="$BASE/devices.tar.gz" -GPGKEY="$BASE/GPG-KEY" -SKEL="$BASE/skel.conf" - -if [ -z "$2" ]; then - echo "usage: `basename $0` <jail-root> <jail-name>" - exit 1 -elif [ ! -d "$1/$2" ]; then - echo "folder $1/$2 does not exist" - exit 1 -fi - -cp /etc/resolv.conf $1/$2/etc/ -cp /etc/localtime $1/$2/etc/ -echo /dev/hdv1 / ext2 defaults 1 1 > $1/$2/etc/fstab -echo /dev/hdv1 / ext2 rw 0 0 > $1/$2/etc/mtab - -echo "creating devices and dependencies" -if [ -f "$DEVICES" ]; then - cd $1/$2/ - tar zxvf $DEVICES - chroot $1/$2/ sbin/ldconfig -else - echo error: device template $DEVICES not found -fi - -if [ -f "$SKEL" ]; then - echo "creating /etc/vservers/$2.conf" - mkdir -p /etc/vservers - cp $SKEL /etc/vservers/$2.conf -else - echo error: config file template $SKEL not found -fi - -if [ -f "$GPGKEY" ]; then - echo "importing slack gpg pubkey" - mkdir $1/$2/root/.gnupg - gpg --homedir $1/$2/root/.gnupg --import $GPGKEY -fi - -echo "done; now edit /etc/vservers/$2.conf" -echo "then, set all desired iptables rules and start $server vserver" -echo "dont forget to change root's password with the command "vserver $2 exec passwd"" |