diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2012-04-27 14:20:58 +0200 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2012-04-27 14:22:59 +0200 |
commit | 3bf62c8723ba2fbe3cceb0879e52be545c196f11 (patch) | |
tree | db408bf817bfbfa617ec295087fd55bdc2a8e4be /setup-cryptswap.in | |
parent | d7de48e0b4936d0b9af32f0087b88a96dcb569a3 (diff) | |
download | alpine-conf-3bf62c8723ba2fbe3cceb0879e52be545c196f11.zip |
remove setup-ads, setup-alpine-web and setup-cryptswap
Diffstat (limited to 'setup-cryptswap.in')
-rwxr-xr-x | setup-cryptswap.in | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/setup-cryptswap.in b/setup-cryptswap.in deleted file mode 100755 index 7c9af32..0000000 --- a/setup-cryptswap.in +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/sh - -PREFIX= -. "$PREFIX/lib/libalpine.sh" - - -list_partitions() { - awk '$1 ~ /[0-9]/ {print " " $4}' /proc/partitions -} - - -if [ -z "$1" ] ; then - while [ "x$verify" != "xy" ] ; do - echo "Available partitions: " $(list_partitions) - echon "Use what partition for encrypted swap? [none] " - default_read part "none" - - # check if user requested to abort - if [ "x$part" = "xabort" ] || [ "x$part" = "xnone" ] ; then - exit - fi - # check if device exist - [ -e /dev/$part ] || continue - - # let the user verify - echon "Warning! you will lose all data on $part. Continue? (y/n) [n] " - default_read verify "n" - done -else - part=$1 -fi - - -apk add cryptsetup-luks - -# set the device in /etc/conf.f/cryptswap -if grep ^DEVICE= /etc/conf.d/cryptswap >/dev/null ; then - sed -i 's:^DEVICE=.*:DEVICE=/dev/'$part':' /etc/conf.d/cryptswap -else - echo "DEVICE=/dev/$part" >> /etc/conf.d/cryptswap -fi - -rc_add -k -s 05 cryptswap -rc_add -k -s 06 swap - -/etc/init.d/cryptswap start -/etc/init.d/swap start - |