mirror of https://github.com/CIRCL/Circlean
Merge branch 'dev'
* add support of root FS mounted RO * append txt to the log filespull/10/head
commit
c61883d1c1
|
@ -0,0 +1,5 @@
|
|||
proc /proc proc defaults 0 0
|
||||
/dev/mmcblk0p1 /boot vfat ro,defaults 0 2
|
||||
/dev/mmcblk0p2 / ext4 ro,defaults,noatime 0 1
|
||||
tmpfs /tmp tmpfs rw,size=64M,noexec,nodev,nosuid,mode=1777 0 0
|
||||
# a swapfile is not a swap partition, so no using swapon|off from here on, use dphys-swapfile swap[on|off] for that
|
|
@ -4,10 +4,12 @@ DEV_DST='/dev/sdb1'
|
|||
USERNAME='kitten'
|
||||
HOME="/home/${USERNAME}"
|
||||
|
||||
# Paths used in multiple scripts
|
||||
SRC="${HOME}/src"
|
||||
TMP="/tmp/"
|
||||
|
||||
DST="${HOME}/dst"
|
||||
# Paths used in multiple scripts
|
||||
SRC="${TMP}/src"
|
||||
|
||||
DST="${TMP}/dst"
|
||||
TEMP="${DST}/temp"
|
||||
ZIPTEMP="${DST}/ziptemp"
|
||||
LOGS="${DST}/logs"
|
||||
|
|
|
@ -9,7 +9,7 @@ source ./constraint_conv.sh
|
|||
RECURSIVE_ARCHIVE_MAX=3
|
||||
RECURSIVE_ARCHIVE_CURRENT=0
|
||||
ARCHIVE_BOMB=0
|
||||
LOGFILE="${LOGS}/processing"
|
||||
LOGFILE="${LOGS}/processing.txt"
|
||||
|
||||
# Something went wrong.
|
||||
error_handler(){
|
||||
|
|
|
@ -97,13 +97,13 @@ do
|
|||
echo "${partition} mounted at ${SRC}"
|
||||
|
||||
# Print the filenames on the current partition in a logfile
|
||||
find "${SRC}" -fls "${LOGS}/Content_partition_${PARTCOUNT}"
|
||||
find "${SRC}" -fls "${LOGS}/Content_partition_${PARTCOUNT}.txt"
|
||||
|
||||
# create a directory on ${DST} named PARTION_$PARTCOUNT
|
||||
target_dir="${DST}/FROM_PARTITION_${PARTCOUNT}"
|
||||
echo "copying to: ${target_dir}"
|
||||
mkdir -p "${target_dir}"
|
||||
LOGFILE="${LOGS}/processing"
|
||||
LOGFILE="${LOGS}/processing.txt"
|
||||
|
||||
echo "==== Starting processing of ${SRC} to ${target_dir}. ====" >> ${LOGFILE}
|
||||
main ${target_dir}
|
||||
|
|
|
@ -12,17 +12,11 @@ fi
|
|||
|
||||
clean(){
|
||||
echo Done, cleaning.
|
||||
#mount -o remount,rw /
|
||||
${SYNC}
|
||||
}
|
||||
|
||||
trap clean EXIT TERM INT
|
||||
|
||||
# Remount the root filesystem in RO mode
|
||||
#mount -o remount,ro /
|
||||
|
||||
chown -R ${USERNAME}:${USERNAME} /home/${USERNAME}/
|
||||
|
||||
su ${USERNAME} -c ./groomer.sh
|
||||
|
||||
|
||||
|
|
|
@ -10,3 +10,4 @@ apt-get autoremove
|
|||
apt-get install libreoffice p7zip-full libfontforge1
|
||||
dpkg -i libpoppler28*.deb pdf2htmlex*.deb
|
||||
|
||||
chown -R kitten:kitten /home/kitten
|
||||
|
|
Loading…
Reference in New Issue