diff options
| author | Michael Neves | 2013-02-15 17:09:04 +0100 |
|---|---|---|
| committer | Michael Neves | 2013-02-15 17:09:04 +0100 |
| commit | 3de31c7d1005a97ce539df96b3926efa224f65e1 (patch) | |
| tree | 4b808cf35fe213ff02ef291f92a5a57f73bb9481 /remote/tools/base | |
| parent | ldm (diff) | |
| parent | debug output cleaned a bit (diff) | |
| download | tm-scripts-3de31c7d1005a97ce539df96b3926efa224f65e1.tar.gz tm-scripts-3de31c7d1005a97ce539df96b3926efa224f65e1.tar.xz tm-scripts-3de31c7d1005a97ce539df96b3926efa224f65e1.zip | |
Merge branch 'master' of git.openslx.org:openslx-ng/tm-scripts
Diffstat (limited to 'remote/tools/base')
| -rw-r--r-- | remote/tools/base/base.build | 26 | ||||
| -rw-r--r-- | remote/tools/base/base.conf | 23 | ||||
| -rw-r--r-- | remote/tools/base/data/etc/keymaps/de_DE | bin | 0 -> 2823 bytes |
3 files changed, 38 insertions, 11 deletions
diff --git a/remote/tools/base/base.build b/remote/tools/base/base.build index 91cbfa3f..95b9de65 100644 --- a/remote/tools/base/base.build +++ b/remote/tools/base/base.build @@ -17,8 +17,16 @@ build() { for BIN in ${REQUIRED_BINARIES} do BIN_LOCATION=$(which ${BIN}) - [ -e ${BIN_LOCATION} ] && echo ${BIN_LOCATION} >> ${FILELIST} - [ -L ${BIN_LOCATION} ] && echo $(readlink ${BIN_LOCATION}) >> ${FILELIST} + if [ ! -z ${BIN_LOCATION} -a -e ${BIN_LOCATION} ]; + then + echo "[$TOOL] Processing $BIN at $BIN_LOCATION ..." + echo ${BIN_LOCATION} >> ${FILELIST} + [ -L ${BIN_LOCATION} ] \ + && echo "[$TOOL] ${BIN_LOCATION} is a symbolic link, copying $(readlink -f ${BIN_LOCATION})" \ + && echo $(readlink -f ${BIN_LOCATION}) >> ${FILELIST} + else + echo "[$TOOL] ${BIN} not found on the system!" + fi done for LIB in ${REQUIRED_LIBRARIES} @@ -38,13 +46,15 @@ build() { [ ! -d ${FILE} ] && echo ${FILE} >> ${FILELIST} done - tar -cpv $(cat ${FILELIST}) | tar -xpv -C ${BUILDDIR} &>/dev/null + echo "[$TOOL] File list generated as ${BUILDDIR}/${FILELIST}." + echo "--------------------------------------------------------------------" + (tar -cpv $(cat ${FILELIST}) | tar -xpv -C ${BUILDDIR}) &>/dev/null } post_copy() { # make basic directory structure - mkdir -p ${INIT_DIR}/{bin,dev,proc,lib,etc,mnt,sys,var/run,var/lock,var/log,run/lock,run/shm} + mkdir -p ${INIT_DIR}/{bin,dev,proc,lib,etc,mnt,sys,var/run,var/lock,var/log,run/lock,run/shm,openslx/mnt} # copy devices from running system cp -a /dev/{console,kmsg,mem,null,shm,tty,tty0,tty1,tty9,fb0,urandom,zero} \ @@ -57,14 +67,15 @@ post_copy() { # copy static files cp -r ${TOOL_DIR}/${TOOL}/data/* ${INIT_DIR} + # better: dirname $(ldd $SHELL|grep libc | awk -F " " '{print $3}') # copy pam modules, TODO: better way to find arch-dependant interfix... - tar -cpv $(dirname $(locate pam_unix.so|grep ^/lib/)) | tar -xpv -C ${INIT_DIR} &>/dev/null + (tar -cpv $(dirname $(locate pam_unix.so|grep ^/lib/)) | tar -xpv -C ${INIT_DIR}) &>/dev/null # quick fix for /etc/fstab echo "# no configuration" >> ${INIT_DIR}/etc/fstab # link /etc/mtab, needed for systemd - ln -s /proc/self/mounts ${INIT_DIR}/etc/mtab + [ ! -e ${INIT_DIR}/etc/mtab ] && ln -s /proc/self/mounts ${INIT_DIR}/etc/mtab # quick fix for missing group in /etc/group echo "lock:x:128:" >> ${INIT_DIR}/etc/group @@ -80,5 +91,6 @@ post_copy() { #cp -r /lib/modules/$(uname -r) ${INIT_DIR}/lib/modules/$(uname -r) #quick fix xterm symlink - ln -s /usr/lib/libXaw7.so.7.0.0 ${INIT_DIR}/usr/lib/libXaw7.so.7 + [ -e /usr/lib/libXaw7.so.7.0.0 ] && \ + ln -s /usr/lib/libXaw7.so.7.0.0 ${INIT_DIR}/usr/lib/libXaw7.so.7 } diff --git a/remote/tools/base/base.conf b/remote/tools/base/base.conf index 5e97fe51..8b5fe899 100644 --- a/remote/tools/base/base.conf +++ b/remote/tools/base/base.conf @@ -8,6 +8,9 @@ REQUIRED_BINARIES=" bash sulogin mount umount + mount.nfs + mount.aufs + umount.aufs rm ldd strace @@ -15,7 +18,10 @@ REQUIRED_BINARIES=" bash modprobe xterm rsyslogd - ps" + ps + sshd + scp + ssh" REQUIRED_LIBRARIES=" libcap libcidn libcom_err @@ -31,18 +37,27 @@ REQUIRED_LIBRARIES=" libcap libpam libutil libtinfo - libresolv" + libresolv + libau" REQUIRED_DIRECTORIES=" /etc/pam.d /etc/security" -REQUIRED_FILES=" /etc/passwd +REQUIRED_FILES=" /sbin/mount.nfs4 + /sbin/umount.nfs4 + /etc/passwd /etc/shadow /etc/group /etc/hostname /etc/environment /etc/pam.conf /etc/issue + /etc/inputrc /etc/localtime /etc/login.defs /etc/nsswitch.conf /etc/securetty - /etc/default/locale" + /etc/default/locale + /etc/default/aufs + /etc/protocols + /etc/services + /etc/networks + /etc/netconfig" diff --git a/remote/tools/base/data/etc/keymaps/de_DE b/remote/tools/base/data/etc/keymaps/de_DE Binary files differnew file mode 100644 index 00000000..375c2012 --- /dev/null +++ b/remote/tools/base/data/etc/keymaps/de_DE |
