From 443dd1f1638cf962bf914083a827d7fbb697ea9a Mon Sep 17 00:00:00 2001 From: frisco <> Date: Thu, 19 Jun 2008 07:35:37 +0000 Subject: [PATCH] Did some cleanup. Builds and (unlike revision 1110) boots. See "README.devel" for some additional notes. --- Makefile | 33 ------------------- README.devel | 16 +++++++++ config/binary | 4 +-- config/chroot | 22 ------------- .../init-bottom/80-cn-run-config-script.sh | 32 ------------------ config/cnas-active-settings | 21 ++++++++++++ config/cnas-default-settings | 20 +++++++++++ rm-tmps.sh | 10 ++++++ 8 files changed, 69 insertions(+), 89 deletions(-) delete mode 100644 Makefile create mode 100644 README.devel delete mode 100755 config/chroot_local-includes/etc/initramfs-tools/scripts/init-bottom/80-cn-run-config-script.sh create mode 100644 config/cnas-active-settings create mode 100644 config/cnas-default-settings create mode 100755 rm-tmps.sh diff --git a/Makefile b/Makefile deleted file mode 100644 index e2c545f..0000000 --- a/Makefile +++ /dev/null @@ -1,33 +0,0 @@ - - - -# make-mode emacs thingamajig -*- makefile -*- - - -#manually configured directories -config_dirs := config binary_local-hooks chroot_local-hooks \ -chroot_local-includes chroot_local-packageslists \ -binary_syslinux - -emacs_files := $(wildcard *~ config/*~ config/*/*~ config/*/*/*~) - -#This is just a helper file, since emacs "foo~" files can sometimes break a -#build (files ending in ~ are considered valid shell scripts). -#If you want to build the disk image, use "lh_build" as documented at -# http://devel.cryptobox.org/wiki/DebianLiveBuild - -#Using a makefile for this is a bit of a drawback, since live-helper -#doesn't really require `make'. - - -# this makefile could eventually call the live-helper build system - -clean-config : - -rm -f $(emacs_files) -# -rm -f $(addsuffix /*~, $(config_dirs)) - -clean-all : - lh_clean --purge - -.PHONY : clean-all clean-config - diff --git a/README.devel b/README.devel new file mode 100644 index 0000000..f48fba8 --- /dev/null +++ b/README.devel @@ -0,0 +1,16 @@ +This is an EXPERIMENTAL version of CryptoNAS for Debian Live! + +## To get an NAS "good enough to play with", run the following commands once +#you get to the root prompt (use "sudo -s" to get to the root prompt). + +#It is recommended that you run "./rm-tmps.sh" after making configuration +#changes using an editor but before starting a new build. + + +/usr/lib/cryptobox-cd/configure-cryptobox.sh normal + +## optionally call it again with argument "secure" (again, EXPERIMENTAL) + +/sbin/telinit 3 +/etc/init.d/cryptobox-server restart +/etc/init.d/samba restart diff --git a/config/binary b/config/binary index 1de46e3..8bd6c21 100644 --- a/config/binary +++ b/config/binary @@ -120,8 +120,8 @@ LH_SYSLINUX_SPLASH="" # $LH_SYSLINUX_TIMEOUT: set custom syslinux timeout in seconds # (Default: 0) -# "0" does NOT appear to boot immediately -LH_SYSLINUX_TIMEOUT="3" +# "0" apparently means "wait forever" +LH_SYSLINUX_TIMEOUT="5" # $LH_SYSLINUX_CFG: set custom syslinux configuration file # (Default: empty) diff --git a/config/chroot b/config/chroot index d1f59fe..88e8148 100644 --- a/config/chroot +++ b/config/chroot @@ -64,25 +64,3 @@ LH_SYMLINKS="disabled" # (Default: disabled) LH_SYSVINIT="disabled" - -#FIXME: Note: Everything below represents brainstorming on the part of developer -#"frisco" and is not official. -############################################################### -# This is the CryptoNAS-specific part of the file. Default -# values are defined below. Since this config file is included -# as part of various shell scripts, any definitions present -# in the files we include below will override those defined -# in the present file. -# -# It is recommended that CryptoNAS-specific variable -# definitions follow the CN_FOO or _CN_FOO conventions to -# avoid polluting the shared live-helper namespace. -############################################################### - -#CN_DELETEFILES="/etc/rcS.d/*discover \ -#/etc/rcS.d/*lvm \ -#/var/log/dpkg.log \ -#/var/log/bootstrap.log" - -#CN_MAKEDIRS="" - diff --git a/config/chroot_local-includes/etc/initramfs-tools/scripts/init-bottom/80-cn-run-config-script.sh b/config/chroot_local-includes/etc/initramfs-tools/scripts/init-bottom/80-cn-run-config-script.sh deleted file mode 100755 index f2ff47a..0000000 --- a/config/chroot_local-includes/etc/initramfs-tools/scripts/init-bottom/80-cn-run-config-script.sh +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh - -##run /usr/lib/cryptobox-cd/configure-cryptobox.sh - - -##The contents of this script are commented out because this part -##isn't yet working. Running the script AFTER startup is complete -## seems to result in a working CryptoNAS, but I haven't yet -## made the changes necessary to get "configure-cryptobox.sh" -## to run in the initramfs context. -## -## To get an NAS "good enough to play with", uncomment everything with -## a single '#' after this point and run it once you get to the root -## prompt (use "sudo -s" to get to the root prompt). -## -echo "Boot-time configuration not implemented; run" -echo "/usr/lib/cryptobox-cd/configure-cryptobox.sh as root" -#echo "Configuring the CryptoNAS live system..." -##if we're doing a release version, call it with "normal, then secure" -##disable for now to isolate smbd/nmbd other problems - -#/usr/lib/cryptobox-cd/configure-cryptobox.sh normal - - -## call it again with argument "secure" if we're building a release - - -#/sbin/telinit 3 - - -#/etc/init.d/cryptobox-server restart -#/etc/init.d/samba restart diff --git a/config/cnas-active-settings b/config/cnas-active-settings new file mode 100644 index 0000000..3f174fb --- /dev/null +++ b/config/cnas-active-settings @@ -0,0 +1,21 @@ +#CryptoNAS Live include file +#$BUILD_DIR/config/cnas-active-settings +# -*- bash -*- #configure Emacs for bash mode +#This file includes the config files in the correct order. +#It can be included by scripts both in the bootstrap and +#chroot environments. Variable assignments in later +#includes override earlier ones. + + +. ./cnas-default-settings + +#May be necessary to include this file in the below files instead... +#. ./common +#. ./bootstrap +#. ./chroot +#. ./binary +#. ./source + +#Include cnas-custom-settings IFF this file exists +#. ./cnas-custom-settings +[ -f ./cnas-custom-settings ] && . ./cnas-custom-settings diff --git a/config/cnas-default-settings b/config/cnas-default-settings new file mode 100644 index 0000000..57ab8cf --- /dev/null +++ b/config/cnas-default-settings @@ -0,0 +1,20 @@ + +#include file for CryptoNAS Live + + +#FIXME: move this somewhere else, such as "default settings" +#Set this to "devel" or "normal" for development, or +#set it to "hard" or "secure" for releases. +CNAS_HARDNESS="devel" + +# It is recommended that CryptoNAS-specific variable +# definitions follow the CNAS_FOO or _CNAS_FOO conventions to +# avoid polluting the shared live-helper namespace. +############################################################### + +#CNAS_DELETEFILES="/etc/rcS.d/*discover \ +#/etc/rcS.d/*lvm \ +#/var/log/dpkg.log \ +#/var/log/bootstrap.log" + +#CNAS_MAKEDIRS="" diff --git a/rm-tmps.sh b/rm-tmps.sh new file mode 100755 index 0000000..7c75f25 --- /dev/null +++ b/rm-tmps.sh @@ -0,0 +1,10 @@ +#!/bin/sh +#rm-tmps.sh +#remove "foo~" temporary files left by Emacs and other editors + +#This is just a helper file, since Emacs-style "foo~" files can sometimes break a +#build (files ending in ~ are considered valid shell scripts). +#If you want to build the disk image, use "lh_build" as documented at +# http://devel.cryptobox.org/wiki/DebianLiveBuild + +rm --verbose -f `find config -name "*~"`